PDA

View Full Version : I2C object needed for DS2760 Thermocouple



T Chap
11-13-2006, 10:23 AM
There is an object in the library for the DS1621 (to 275F). I need measurement to <500F, and the DS2760 either standalone or Parallax kit seems like the way to go. With no i2c experience, would it be a simple adaptation to upgrade the 1620/21 to the 2760?

Secondly, there was no mention of any interface details to the Propeller. The i2c can be directly connected via resistors?

What is needed is the temperature in F(preferred) as an integer in the Propeller that can be sent serially as a string to somewhere else for decisions.

Thanks for any tips on where to start

Post Edited (originator99) : 11/13/2006 3:28:47 AM GMT

James Long
11-13-2006, 10:45 AM
first......there are different voltage I2C components....as I have found recently. You need to make sure the DS2760 is 3.3v compatable. If not you will have to do a voltage level shift in the bus.

The bus on I2C has pull up resistors to the level that is being used.

It can be a challenge with I2C to interface·among different voltage components. Phillips makes a level shifter "P82B96" that does this, but it is about 3 bucks ($3.00).

The I2C protocol is already in the BS2_functions library, so using the chip once the electrical part is figured out, is not that hard.

The electrical part of I2C is the hardest with the Prop. I'm used to 5 volts....and I'm encountering the same problem, but I have decided to use the Phillips chip as a level shifter.

I doubt this helps much....but I'm trying,

James L

T Chap
11-13-2006, 11:23 AM
Well if it is just level conversion, a 4050 with VDD at 5v will get you 3.3 to 5v on the output easily. A 4050 with 3.3v at VDD will get you the reduction coming in as they will accept over voltage. Also, the Inputs could just have a series resistor. Maybe it is more to it than this but I do this type of shifting all the time no problem.

Javalin
11-13-2006, 05:19 PM
If the DS2760 is a +5V device then see the documentation in either the i2cDemo.spin or the i2cObject.spin (cannot remember which I put them in). The Prop will run a 5v i2c with a 1k resistor in the right place on the lines.

James