0

I'm controlling a motor bridge via a serial port by using the voltage from the pins on the serial plug directly.

This would normally only give me the RTS and DTR pins to use (controllable through PySerial) as motor controls; however, if I send a string through the data out pin, I can generate enough voltage to control the motor bridge.

My question is-- Why do I get a higher voltage for characters with more binary zeroes in them? A string of "~" (01111110)gets me only 1.3 volts, 'Z' (01011010) gets about 2 volts, and "@" (01000000)clears the 3 volt threshold I need operate the motor bridge.

It's not really a problem, but I feel I'm missing something conceptually important here as I assumed it would be the opposite (more binary ones = higher voltage).

Thanks in advance.

4

1 回答 1

0

Hans Passant had the right answer: inverted outputs on RS-232. I'm just putting it so this questions doesn't stay open.

于 2014-03-03T11:19:49.753 回答