SLVUAW9C September 2016 – February 2020 UCD90320
This Read/Write Block common command is used to configure the parameters used by the PARM_VALUE command.
PARM_INFO and PARM_VALUE are combined to provide a method for reading or writing to any RAM address, hardware register, etc. A map file specific to the firmware release may be required to determine the offset for a particular RAM variable, because variables may be in different locations for each release.
| Parm_index – Index for base address | ||
| 0 = RAM | ||
| 1 = Hardware Peripherals | ||
| 2 = Constants in Data Flash (Read Only, unless unlocked) | ||
| 3 = Constants in Program Flash (Read Only) | ||
| 4 = Data Flash Control Registers | ||
| 5 = EEPROM (Read only, with Parm_size = 4 only) | ||
| Parm_offset – offset from the base address selected by parm_base. | ||
| Parm_count – number of elements to read or write | ||
| Parm_size – the size of each element in bytes. (Valid values are 1, 2, or 4). | ||
The PARM_INFO command updates four variables that are needed to issue a generic read/write of RAM, hardware registers, etc. The four variables are parm_index, parm_offset, parm_count, and parm_size and their description follows.
| Byte Number
(Write) |
Byte Number
(Read) |
Payload
Index |
Description |
|---|---|---|---|
| 0 | CMD = E2 | ||
| 1 | 0 | BYTE_COUNT = 6 | |
| 2 | 1 | 0 | Index |
| 3 | 2 | 1 | Offset (low byte) |
| 4 | 3 | 2 | Offset (middle byte) |
| 5 | 4 | 3 | Offset (high byte) |
| 6 | 5 | 4 | Count |
| 7 | 6 | 5 | Size |