BS2PX CONFIGPIN 3V logic level
JimK
Posts: 21
I recently purchased the HM55B compass from Parallax but discovered after·testing and calibration the accuracy and issue with tilt error would·not be practical for my application (for use on a sailboat in the·ocean).· I also saw this thread which explained in more detail those issues.
http://forums.parallax.com/showthread.php?p=736727
I·found this compass sensor OS5000 TTL that seems to have better accuracy, tilt compensated, plus pitch and roll data·in a ASCII NMEA output format (and expensive at $250).
http://www.oceanserver-store.com/os3axdicoton.html
In reading the Ocean Server user manual it states the TTL version, Tx uses a voltage level 3v and the Rx says 3v or 5V tolerant.
I have a BS2px and noticed the CONFIGPIN command has a logic threshold option that can set a pin for TTL or CMOS levels.· My question is can I use the CONFIGPIN command to specify CMOS logic levels and be able to use the 3v output level of the compass sensor ?· I assume I cannot simply connect Tx to the BS2px since it does not output 5v levels ?
I also saw Sparkfun sells a logic level convertor board but wonder if anyone could tell me if the think the CONFIGPIN option would work.· As I said the sensor is expensive and I do not want to purchase it unless I am somewhat confident it can interface to the BS2px.·
http://www.sparkfun.com/commerce/product_info.php?products_id=8745
Thanks!
http://forums.parallax.com/showthread.php?p=736727
I·found this compass sensor OS5000 TTL that seems to have better accuracy, tilt compensated, plus pitch and roll data·in a ASCII NMEA output format (and expensive at $250).
http://www.oceanserver-store.com/os3axdicoton.html
In reading the Ocean Server user manual it states the TTL version, Tx uses a voltage level 3v and the Rx says 3v or 5V tolerant.
I have a BS2px and noticed the CONFIGPIN command has a logic threshold option that can set a pin for TTL or CMOS levels.· My question is can I use the CONFIGPIN command to specify CMOS logic levels and be able to use the 3v output level of the compass sensor ?· I assume I cannot simply connect Tx to the BS2px since it does not output 5v levels ?
I also saw Sparkfun sells a logic level convertor board but wonder if anyone could tell me if the think the CONFIGPIN option would work.· As I said the sensor is expensive and I do not want to purchase it unless I am somewhat confident it can interface to the BS2px.·
http://www.sparkfun.com/commerce/product_info.php?products_id=8745
Thanks!
Comments
So I would go with the CMOS levels, but really it rarely makes a difference.
Bean.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
"The welfare of the people in particular has always been the alibi of tyrants." ~ Camus
www.iElectronicDesigns.com
·
When I'm designing with 5V CMOS circuitry that may have to accept inputs from 3V or 3.3V logic, I always interpose a 74HCTxx gate or buffer to make sure the CMOS device receives an adequate signal. Fortunately, the BS2px gives you a choice, obviating the need for external circuitry.
-Phil
Thank you for your comments.· So it sounds like TTL mode would work.· Is this generally true of interfacing any 3.3 volt sensor with a stamp ?· I have seen several sensors that use 3.3 volts and always thought they would not work with a stamp.· Thanks
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
For a 4.5V Vdd (and who knows why they spec it that way) the minimum input level to guarantee being read as a "high" is 3.15 volts over temp. This is 0.7 * Vdd, which is typical of CMOS specs. At 5V Vdd this would be 3.5V, which makes driving with 3.3V logic not a total slam dunk. While it would take an extreme situation for it to fail under such circumstances, I always design with the worst case in mind, and that usually entails interposing a 74HCT gate, with its lower input thresholds, in the signal path.
The fact that VIH(min) and VIL(max) are so widely separated doesn't imply that there's hysteresis built into the inputs, though. It only means that the actual switching threshold can vary between those two values, across production lots and at various operating temperatures. Typically, at room temperature, this range is reduced to 0.47 * Vdd - 0.53 * Vdd, according to the datasheet. This is where the "Vdd/2" value that's so often quoted comes from.
Am I being overcautious? Probably. But it's an approach learned the hard way I'm afraid.
-Phil
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering
I had a case recently where I spec'd a 74HCT595 that had to run on 5V and, as an option, be driven by 3.3V. But the assembly house subbed a 74HC595 instead. I didn't catch it in the first articles, since they worked fine, and the boards went into production that way. To date there hasn't been a failure that I know of, despite my initial chagrin and unease over it. But I always try to use 'HCT parts in cases like this, just to be on the safe side.
-Phil
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Engineering