I would welcome a pointer to some clearer documentation for the c28x SPI Master Transfer block in provided by TI for use in Simulink.
The description implies that after a WREN has been transmitted, an opcode byte of WRITE can then be followed by a 3 byte address and then as much data as is to be written. The data in bytes, but communicated as an array of 16 bit blocks in Simulink.
The documentation states "
Register address — SPI register address
0 (default) | positive integer scalar | positive integer vector
The slave register address from which the block reads data.
Note
The positive integer vector is specified as, [2 0 32] for Write Data to Memory and [3 0 32] for Read Data from Memory. For more information, refer to the example Using SPI to Read and Write Data to SPI EEPROM.
"
I can deduce that the "2" equates to the WRITE command, but as to the 0 and 32 there is no extra information given in the example mentioned.
The fairly trivial task is to write a variable "n" bytes to an chosen address "x" on an NVRAM chip and then read "n" bytes back at a later stage, but hooking up the block in Simulink is not proving simple.
