Race condition for GPIO sharing between net core and app core

Hello,

How race conditions are handled for GPIO forwarding  when done dynamically like this empty code sample , instead of using DTS entry  ?

Listed some scenarios, please clarify expected behavior.

1. Net core configures GPIO as output, then App core forwards that GPIO, expected behavior ?

2. App core sets as input, Net core sets as output, then App core forwards that GPIO, expected behavior ?

3. Net core configures GPIO as input, Tries to read value, then App core forwards that GPIO, expected behavior ?

4. Net core configure two GPIOs as UART, then App core forwards those GPIOs, expected behavior, can other side exchange UART TX and RX now ?

Is there a documentation regarding this race condition handling / best practices ?

Thanks,

Darshan

Parents Reply
  • Hi,

    If you were to start the network core in the application core bootloader, I agree this could be an issue. But that should not be the case. As mentionned, the network core is forced off by default, and started by the application core (by writing to NETWORK.FORCEOFF), and this is not normally done in the bootloader. For instance, in a Bluetooth application, the host implementation running on the applicatino core will start the network core when initializing Bluetooth.

Children
No Data
Related