dirkwhoffmann/vAmiga

serial data transmission and data item size

Closed this issue · 1 comments

Hi Dirk
vAmigaCore 2.3 generated a message for each outgoing serial data item, i.e. it sent directly the internal transmitted data buffer which can contain 8 or 9 bits.

Version 2.4 was refactored in order to not let the vAmigaCore generate a message for each outgoing byte, which was considered to be spamming the message listener and thereby wasting some performance in case nobody listens for serial data transmission. As a result the transmit data buffer is now not outputted directly anymore. Instead its data is copied into a string of characters where the size of each char is 8 Bit. Obviously the 9th data bit (d8) defined in the HRM is lost this way.

to let the vAmigaCore also transmit the bit D8, I applied the following change in SerialPort.cpp / SerialPort.h

instead of the
string outgoing;

I used a u16 string (which has enough bits to store the 9 bit transmit buffer)
std::u16string outgoing;

see for your reference also here
vAmigaWeb/vAmigaWeb@26c0975

Fixed in v2.5b1