Tool/software:
Hello;
In motor control example I've seen some part;
struct pdo_tx_data {
uint16_t controlWord;
int8_t modeOfOperation;
int32_t targetPosition;
int32_t targetVelocity;
int16_t targetTorque;
};
struct pdo_rx_data {
uint16_t statusWord;
int8_t modeOfOperationDisplay;
int32_t actualPosition;
int32_t actualVelocity;
int16_t actualTorque;
};
/* Target data from the PLC */
__attribute__((section(".gTxDataSection"))) struct pdo_tx_data gTxData;
/* Actual data to send to the PLC */
__attribute__((section(".gRxDataSection"))) struct pdo_rx_data gRxData;
This means we can access some memory blocks form different cores and cast them into the structs. Therefore we can share data between different cores. Am I wrong?
I have 114 byte data need to share between cores ( r5 00-rf 10-r5 01-rf 11 and m4). I mean r5 00 sends 114 byte of data and receives different 114 byte in an order from all the others. When I use RPMessage for this it creates some latency that is I do not intent.
Can I all of this data into memory regions and read them from different cores? What are advantage/disadvantage of this approach while compared with RPMessage? Should I take care about race conditions between cores with this approach? Is it possible to share data between r5 cores and m4 core?
Regards
Kadir