ConfigurationPacket assumes that the payload data is owned by someone
else. For frame data, that is generally true. For initialization and
finalization sequences, those payloads need to be created and managed.
Instead, dynamically allocate packets which allows for using subclasses
of ConfigurationPacket that store the payload with the packet.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Applies a .frm file (lines of frame address: frame words) to a bitstream
and writes the result as a new bitstream. Note that the new bitstream
will not include the initialization and finalization sequences required
for programming.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
ConfigurationFrameAddress row-half and row fields translate directly to
the clock region structure used in 7-series parts. Break these concepts
out into separate classes and encode them as such in Part YAML.
Columns within a row are more complicated. Column indices are relative
to a BlockType. Think of each BlockType as a data bus that terminates at
some particular tile type (e.g. CLB_IO_CLK maps to INT_{L,R} tiles).
Column indices act as addresses of endpoints on the associated BlockType
bus. As the bus is 1 frame (101 words, 404 bytes) wide, each endpoint
feeds frames into multiple tiles simultaneously.
Minor addresses are frame addresses within a BlockType bus endpoint.
These can refer to frames either stored within the endpoint tiles
or in tiles chained behind them.
Note that a given tile can be connected on multiple BlockType buses.
For example, block RAMs appear to be attached both by being chained
behind an INT_{L,R} on the CLB_IO_CLK bus as well as being a direct
endpoint on the BLOCK_RAM bus. Due to this, tiles conceptually belong
to the row rather than a single column.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
_address suffix on accessors is unnecessary and somewhat inaccurate.
The returned values are indices rather than frame addresses.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Frame addresses are only used in the context of configuration frames.
Remove the prefix to reduce typing that does not improve clarity.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
MemoryMappedFile's data() method returns a void* as it has no idea what
type the contents are. Viewing it as bytes is a very common operation
so add a convience method that wraps the pointer in a Span<uint8_t>.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Does not work as intended. Removing to avoid confusion.
This reverts commit caeba1b49af17bdceb35803b2c3bc55ef0e3cf62.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Signed-off-by: Tim 'mithro' Ansell <mithro@mithis.com>
Does not work as intended. Remove to avoid confusion.
This reverts commit 80d8d6d8d3bc5e7ad5c72c9998777b5e0590ec30.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Signed-off-by: Tim 'mithro' Ansell <mithro@mithis.com>
Action is a required option with no reasonable default. Making it a
flag just requires the user to type extra for no benefit.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Signed-off-by: Tim 'mithro' Ansell <mithro@mithis.com>
Class names were getting unwieldy. Use a namespace to group all the
7series classes and allow for shorter class names.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Signed-off-by: Tim 'mithro' Ansell <mithro@mithis.com>
Initial version support dumping configuration packets from a bitstream.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Signed-off-by: Tim 'mithro' Ansell <mithro@mithis.com>
Skip tags and bits if they are _found_ in the excluded sets.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Signed-off-by: Tim 'mithro' Ansell <mithro@mithis.com>
--exclude_known will omit any tags and bits that are already saved in
the database specified with --database_path.
Signed-off-by: Rick Altherr <kc8apf@kc8apf.net>
Signed-off-by: Tim 'mithro' Ansell <mithro@mithis.com>