LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

stop writing start bit on serial port Tx but keep the baud rate timing

Hi everybody,

I'm actually sending the data 0x5B at 115200bps on my serial port so that I produce a 38.4kHz waveform during a 78µs writing period, so I control the sending of a signal on Tx on a smaller timebase than the minimum 1ms of Windows. The problem is that I'd like to have 38.4kHz or nothing on this period and even sending 0x00, the start bit create a signal (at 12.5kHz, 1 bit on 8). As my knowledge on the serial port is limited, I'd like to know if there's a way to avoid this, maybe by using another signal (DTR for example) to pull down the Tx when I want to avoid writing.
I don't know if it's the simplest way to manage this so I wanted to talk about it before starting my development.

Thank you in advance

Bim
0 Kudos
Message 1 of 3
(2,135 Views)
With one start bit and sending 0x55, I see the square wave you want to have. I think your problem is sending 0x5B not with the start bit.
Randall Pursley
0 Kudos
Message 2 of 3
(2,129 Views)
If you want 4 cycles of the square wave instead of 5 then set you byte to 0xD5. Here is a table

5 cycles 0x55
4 cycles 0xD5
3 cycles 0xF5
2 cycles 0xFD
1 cycle 0xFF

If you want longer send two bytes to the serial port such as

6 cycles 0x55 and 0xFF
7 cycles 0x55 and 0xFD

etc...
Randall Pursley
0 Kudos
Message 3 of 3
(2,128 Views)