Git Product home page Git Product logo

regfmt's People

Contributors

kickingvegas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

regfmt's Issues

YAML width with float type is processed

Apparently a float value put into the width field is not flagged by the JSON validator. This is a bug.

# regfmt https://github.com/kickingvegas/regfmt
# ARM Coretex-M3 Program Status Register
# https://developer.arm.com/documentation/dui0552/a/the-cortex-m3-processor/programmers-model/core-registers

width: 32
endian: bigBit
layout:
  field-name-align: stair-left
registers:
- name: "APSR: Application Program Status Register"
  fields:
    - name: "N: Negative flag"
      width: 1.0
    - name: "Z: Zero flag"
      width: 1
    - name: "C: Carry or borrow flag"
      width: 1
    - name: "V: Overflow flag"
      width: 1
    - name: "Q: Saturation flag"
      width: 1
    - name: Reserved
      width: 27

Resulting output has float values in the field indexes.

floatWidthBug

Reimplement border SVG

Current implementation uses adjacent rects which is problematic for borders between adjacent fields. Reimplement using line segment for border.

Stair left layout bug

"Interrupt Mask" is truncated.

##
# Example YAML file for regfmt

width: 8
endian: bigBit

registers:
  - name: R1
    fields:
      - width: 1
        name: Coprocessor Usable

      - width: 1
        name: Boostrap Exception Vectors

      - width: 2
        name: Parity Errors

      - width: 4
        name: Interrupt Mask
layout:
  field-name-align: stair-left

Strange escape sequence when width is not specified in YAML

When width is left unspecified, the error message has a strange escape sequence appended to it.

# regfmt https://github.com/kickingvegas/regfmt
# ARM Coretex-M3 Program Status Register
# https://developer.arm.com/documentation/dui0552/a/the-cortex-m3-processor/programmers-model/core-registers

width: 32
endian: bigBit
layout:
  field-name-align: stair-left
registers:
- name: "APSR: Application Program Status Register"
  fields:
    - name: "N: Negative flag"
      width: 1
    - name: "Z: Zero flag"
      width: 
    - name: "C: Carry or borrow flag"
      width: 1
    - name: "V: Overflow flag"
      width: 1
    - name: "Q: Saturation flag"
      width: 1
    - name: Reserved
      width: 27

Fix readme

Fix readme to support both github and pypi.

Support sub/super scripting in names

Support sub/super scripting in names. Apparently this is possible with <tspan> via the dy attribute.

example:

  <text x="202.0" y="28.5" font-size="12pt" font-family="Futura,Helvetica,Arial,sans-serif" font-style="normal" font-weight="normal" text-anchor="start" fill="black">Control Register<tspan dy='-5' style='font-size: 8pt'>1</tspan></text>

Fix SVG generation

Fix numerous SVG generation bugs:

  • top level x, y, width, height measurement
  • cleaner layout code

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.