0.1.10 - 2025-11-24
- encode uses shared ref, update default trait derives (#11)
0.1.9 - 2025-11-23
- Update to can-dbc v8
- Adds the ability to specify one or more trait derivations to the generated code. This is useful for
Debug,defmt::Format, etc. - Minor refactors and cleanups
- Move repo to OxiBUS GitHub organization
- License change to MIT or Apache 2.0
- Fixes compile error on older
rustcversions (e.g. 1.84.x) where the doc-string formatting would hiterror[E0716]: temporary value dropped while borrowed, so a let-binding is used to work around this (the latest compilers know that this was a valid use-case).
- Generates doc-comments for messages and signals. Messages show their CAN ID and cycle-time (when applicable); signals show their start bit, width, endianness and scale-factor (when applicable).
- Generates
consts for signals with value-table definitions. - Minor refactoring, clean-up and commenting
- Declare message struct
constvalues aspub - Fix small (sub-byte) signal masking
- Include scoping and newtype notes in usage docs
- Adds support for
try_into(&[u8])on generated types. - Only require 2021 edition, as we don't yet use 2024 edition features.
- Allow partial parsing of DBC files to generate what code it can; the can_dbc crate does not support all token types (e.g.
BA_DEF_REL_andBA_DEF_DEF_REL_) but if those are later in the file it's still possible to get at the messages and signals of interest - Add more tests of signed values for LE/BE aligned cases
- Adds support for arrays of messages, so that the same type can be used for all instances. There is no enforcement that the signals within the messages match, and the client is responsible for deciding which IDs should decode into which array elements. Typically this would be done for some
idandmessage_array: MessageName[COUNT]viamessage_array[id - MessageName::ID]after a range check thatidis withinMessageName::ID..message_array.len()(shown here asCOUNT, but can be declared as appropriate for the application). The IDs do not need to be in a contiguous range, as long as the client maps them to the appropriate array indices.
- Adds support for unaligned signals (except big-endian, still a TODO)
- Adds
CYCLE_TIMEconstant for messages whose DBC declares them
- Initial release with support for encoding and decoding (aligned signals only)