firmware
IEM Firmware Documentation
|
Data Structures | |
class | BusContext |
class | MessageContext |
class | PaddingContext |
class | SignalContext |
Functions | |
generate (str|os.PathLike|list[str|os.PathLike] dbc_path, str|os.PathLike out_path=Path("")) | |
get_type_width (int length) |
Variables | |
str | INC_DIR = "inc" |
str | DBC_GLOB = "*.dbc" |
str | SOURCE_TEMPLATE = "can.c.j2" |
str | HEADER_TEMPLATE = "can.h.j2" |
str | CMAKELISTS_TEMPLATE = "CMakeLists.txt.j2" |
str | STATIC_CHECKS_TEMPLATE = "codec_static_checks.h.j2" |
float | VERSION = 0.1 |
parser = ArgumentParser() | |
type | |
help | |
nargs | |
out_path | |
dbc_path | |
args = parser.parse_args() |
Generates C code and CMake configuration files to pack and unpack signals in CAN messages from a DBC file.
codegen.generate | ( | str | os.PathLike | list[str | os.PathLike] | dbc_path, |
str | os.PathLike | out_path = Path("") ) |
Generates C code and CMake configuration files :param dbc_path: Path or list of paths to input DBC files (or directories containing input DBC files) :type dbc_path: str | os.PathLike | list[str | os.PathLike] :param out_path: Path to the output directory for generated code :type out_path: str | os.PathLike
codegen.get_type_width | ( | int | length | ) |
Given a signal length, returns the smallest C integer type width (in bits) needed to contain it
codegen.args = parser.parse_args() |
str codegen.CMAKELISTS_TEMPLATE = "CMakeLists.txt.j2" |
str codegen.DBC_GLOB = "*.dbc" |
codegen.dbc_path |
str codegen.HEADER_TEMPLATE = "can.h.j2" |
codegen.help |
str codegen.INC_DIR = "inc" |
codegen.nargs |
codegen.out_path |
codegen.parser = ArgumentParser() |
str codegen.SOURCE_TEMPLATE = "can.c.j2" |
str codegen.STATIC_CHECKS_TEMPLATE = "codec_static_checks.h.j2" |
codegen.type |
float codegen.VERSION = 0.1 |