Group x430_model¶
Types of the generated Control Table (one model per build). More...
Classes¶
| Type | Name |
|---|---|
| struct | x430_indirect_block Indirect Address block: count addresses of 2 bytes and count data bytes. |
| struct | x430_model Control Table and capabilities of one model. |
| struct | x430_reg One Control Table item (16 bytes of flash). |
| struct | x430_segment Segment of the compact Control Table image of a device: Control Table addresses address . |
Public Types¶
| Type | Name |
|---|---|
| enum | x430_check Write check of a register (upper four bits of x430_reg::flags ). |
Public Attributes¶
| Type | Name |
|---|---|
| const struct x430_model | x430_model_active The model selected at build time (x430_model_table.c). |
Macros¶
| Type | Name |
|---|---|
| define | X430_REG_CHECK (check) ((uint32\_t)(check) << [**X430\_REG\_CHECK\_SHIFT**](group__x430__model.md#define-x430_reg_check_shift))Write check check asx430_reg::flags bits. |
| define | X430_REG_CHECK_SHIFT 4UShift of the write check (enum x430_check) in the upper four bits of x430_reg::flags . |
| define | X430_REG_EEPROM 0x02UEEPROM area: persistent, locked while Torque Enable is 1. |
| define | X430_REG_GOAL 0x08UGoal value: read-only while a Bus Watchdog error is active. |
| define | X430_REG_SIGNED 0x04UTwo's complement value. |
| define | X430_REG_WRITABLE 0x01UWritable by an instruction (RW); without it the register is read-only. |
Detailed Description¶
tools/x430_gen_model.py writes x430_model_table.c with the constant x430_model_active from the YAML description in models/. The library reads the descriptor only; it never changes it.
Public Types Documentation¶
enum x430_check¶
Write check of a register (upper four bits of x430_reg::flags ).
enum x430_check {
X430_CHECK_NONE = 0,
X430_CHECK_RANGE,
X430_CHECK_MASK,
X430_CHECK_OPMODE,
X430_CHECK_SYMMETRIC,
X430_CHECK_GOAL_POSITION,
X430_CHECK_INDIRECT
};
Public Attributes Documentation¶
variable x430_model_active¶
The model selected at build time (x430_model_table.c).
Macro Definition Documentation¶
define X430_REG_CHECK¶
Write check check asx430_reg::flags bits.
define X430_REG_CHECK_SHIFT¶
Shift of the write check (enum x430_check) in the upper four bits of x430_reg::flags .
define X430_REG_EEPROM¶
EEPROM area: persistent, locked while Torque Enable is 1.
define X430_REG_GOAL¶
Goal value: read-only while a Bus Watchdog error is active.
define X430_REG_SIGNED¶
Two's complement value.
define X430_REG_WRITABLE¶
Writable by an instruction (RW); without it the register is read-only.