Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Problem with serial port polarity

Status
Not open for further replies.

billybobjack

Newbie level 3
Joined
Feb 4, 2011
Messages
4
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Activity points
1,340
Hello,
I am trying to connect a pulse oximeter (see next post for data sheet) up to my computer, but I am having trouble reading the data in the correct format. I should be receiving 3 bytes per second when the sensor is plugged in. If there isn't a finger in the pulse ox it should read (in hex):
'BF 7F 7F'
I receive this output when I hook the sensor up to a bus pirate (see next post for data sheet) attached to my laptop in this UART configuration:
Set serial port speed: 9600
Data bits and parity: 8, none
Stop bits: 1
Receive polarity: idle 1 *
Select output type: Open drain (H=Hi-Z, L=GND)

* the receive polarity seems to be my issue. When I try to read from the sensor through a COM port on my desktop or the embedded computer that I eventually want to have it hooked up to, the readings I get are as follows (in hex):
'20 40 40'
which is (close to) the binary inverse of what I should be reading. Also, if I set my bus pirate 'Receive polarity' to idle 0 I also receive this (close to) binary inverse.

Does anyone have any idea why this is happening? I don't think I can simply get away with converting whatever value I read back to binary and inverting it because I'm going to lose an unknown number of leading ones, because whatever they are converted to originally will only see leading zeros and ignore them. Does one of the stock serial port settings allow me to reverse the polarity?

Thanks in advance for any help you can offer!

addendum: need one post to post links, I will respond to this post with the data sheets

---------- Post added at 14:17 ---------- Previous post was at 14:16 ----------

data sheets
pulse oximeter(pdf)
bus pirate
 

I hope this is not a stupid suggestion but just maybe this helps. I see the sensor uses 5v / 3.3v and this might be a wild goose chase but here goes:
The RS232 physical specification gives a logic 1 at the receiver input as -3 to -25 volts and logic 0 as +3 to +25 volts. so I assume the voltages used by the sensor will be the same as used by a micro please have a look at this just maybe? Simple RS232 to logic level converter (TTL, CMOS) the voltage does not swing enough for the desktop rsr232 you can uses a level converter or google max232 chip MAX232 - Wikipedia, the free encyclopedia
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top