this post was submitted on 21 Jun 2023
2 points (100.0% liked)
Ask Electronics
3316 readers
2 users here now
For questions about component-level electronic circuits, tools and equipment.
Rules
1: Be nice.
2: Be on-topic (eg: Electronic, not electrical).
3: No commercial stuff, buying, selling or valuations.
4: Be safe.
founded 1 year ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
In addition to the voltages being different between real-RS232 and "TTL"-serial, they're also swapped. On a DB9 you probably have something approximating RS232, where mark=-9V and space=+9V, but the debug header is likely mark=+3V and space=0V. So even if your inputs can handle a wide voltage range, the sense is inverted, which is why you'll get garble.
(For example, when the line is idle it's at the 'mark' voltage and the receiver knows a character is incoming when it transitions to 'space' for one period (the start-bit). If mark and space are swapped, the receiver will see 'space' most of the time and only detect a character starting when there are some 'mark' bits in the middle of a transmitted character. It'll never actually synchronize correctly with the transmitter.)
You can figure out what you've got with a multimeter and checking what the voltage is on the TX pin when it's idle.