View Single Post
Old 04 March 2021, 20:30   #25
amiga_amigo
Registered User
 
Join Date: Aug 2018
Location: Germany
Posts: 46
Sorry Toni - but it's not working.

This time it's parity Odd and Space that seem to be wrong.
Odd opens the port as N (both my own program and term4.8).
Space opens the port as N (my program) or E (term4.8) => ?

Don't know why this differs but this is how i understood the docs and set the flags:


Code:
SerialIO->io_SerFlags = SERF_XDISABLED; // disable XON/XOFF, clear all other bits

switch(parity)
{
case PAR_O:
	SerialIO->io_SerFlags |= SERF_PARTY_ODD; // fall-through to PAR_E!
case PAR_E:
	SerialIO->io_SerFlags |= SERF_PARTY_ON;
	break;
case PAR_M:
	SerialIO->io_ExtFlags |= SEXTF_MARK; // fall-through to PAR_S!
case PAR_S:
	SerialIO->io_ExtFlags |= SEXTF_MSPON;
	break;
}
so:

PAR_N sets no flags
PAR_O sets SERF_PARTY_ODD and SERF_PARTY_ON,
PAR_E sets SERF_PARTY_ON,
PAR_M sets SEXTF_MARK and SEXTF_MSPON (and automatically SERF_PARTY_ON),
PAR_S sets SEXTF_MSPON (and automatically SERF_PARTY_ON)

Maybe i misunderstood...?
amiga_amigo is offline  
 
Page generated in 0.09942 seconds with 11 queries