The "1 stop bit" thing is really screwing me up from understanding the hserout command.
Specifically, I am looking at the MIDI spec which needs a high-to-low, start bit, before the 8-bit MIDI message.
If hserout always inserts a 1 after 8 bits, I don't see how a MIDI-receiving device will ever see a high-to-low, start bit, before the actual 8-bit MIDI message.
For instance, a typical program change message should look like this:
[11111111]0010000111000000[01111111] where the data gets read right to left.
The bytes in brackets ([...]) are what bytes I imagine should be sent to include the necessary, MIDI start and stop bits (a MIDI stopbit is a low-to-high transistion).
In between the bytes in brackets = $21C0. The LSByte of this word is $C0 which is the status byte. And the MSByte is the program change number "33".
But, if the HSEROUT always places a 1 after every 8-bits, then the message would be read differently:
[1]00100001[1]11000000[1][01111111] = $0781, where the single "[1]' is the HSEROUT stopbit. But the MIDI-receiving device doesn't know that.
Can anyone clear this up for me?
Thanks!