Unfortunately I don’t have a logic analyzer around.
It sounds like you have been communicating successfully with various rs485 devices, are you able to confirm that?
The reason I’m asking, is that when I use Legato to set the rs_mode, based on your unsandboxed example code, I’m not able to observe the change from the file system (also after removing the .adef file requirement, which seem to be for sandboxed mode). The rs_mode file still read “RS232” after the app confirms that it has written 1 to it.
If, on the other hand, I set RS485 mode from a shell script uploaded as unsandboxed Legato app, rs_mode does read “RS485” after the script has run.
Furthermore, if I set rs485 mode like this, or manually, the Legato C app stops being able to read my commands back - it only works if rs_mode is set to RS232 mode initially.
This leads me towards the conclusion, that my C Legato App is actually communicating in RS232 mode despite having tried to set the rs_mode to RS485. And that, for whatever reason, the serial port is still silent when in rs485 mode.
Thanks for all your help.