I have noticed, that while running on WIndows, sp_get_config_parity nearly always returns some concrete parity for a serial port, e.g. SP_PARITY_NONE - but on Linux, even if I call with my libserialport application with sudo, having used these lines from examples:
result = check_sp(sp_get_config_parity(initial_config, &parity));
if (result != SP_OK) { return result; }
... and then, whever I print parity_name_sp(parity) I get "(Invalid)" that is SP_PARITY_INVALID. This is on Raspbian 9, Raspberry Pi 3B+.
I would inspected the matter more, unfortunately parity_name_sp() is a macro (itself created by CREATE_ACCESSORS), and I cannot break into it in the debugger.
What can I do to get actual parity information about serial ports on this OS? Note that there are no problems with the other config parameters on this system, e.g. I get printouts:
config: Baudrate: 9600, data bits: 8, parity: (Invalid), stop bits: 1
I have noticed, that while running on WIndows,
sp_get_config_paritynearly always returns some concrete parity for a serial port, e.g.SP_PARITY_NONE- but on Linux, even if I call with my libserialport application withsudo, having used these lines from examples:... and then, whever I print
parity_name_sp(parity)I get "(Invalid)" that isSP_PARITY_INVALID. This is on Raspbian 9, Raspberry Pi 3B+.I would inspected the matter more, unfortunately
parity_name_sp()is a macro (itself created byCREATE_ACCESSORS), and I cannot break into it in the debugger.What can I do to get actual parity information about serial ports on this OS? Note that there are no problems with the other config parameters on this system, e.g. I get printouts: