send to serial from a different cog (PASM), or not
iammegatron
Posts: 40
I have "FullDuplexSerial" object loaded/started in the "Main" spin code. I can call "serial.tx(a_byte)" to send to serial port.
In the "Main", I also "cognew(@a_different_cog,0)" running assembly code in another cog.
What is the best way for "a_different_cog" to call "serial.tx()" (indirectly) to send its data to serial port?
Some ways I can think of, for example:
1. to signal between two cogs, is to toggle GIO lines.
2. to write to a common HUB RAM address, setting flags etc.
3. ...
In the "Main", I also "cognew(@a_different_cog,0)" running assembly code in another cog.
What is the best way for "a_different_cog" to call "serial.tx()" (indirectly) to send its data to serial port?
Some ways I can think of, for example:
1. to signal between two cogs, is to toggle GIO lines.
2. to write to a common HUB RAM address, setting flags etc.
3. ...
Comments