Jump to content
43oh

[Energia Library] OneWire DS18B20 (430 & Stellaris)


Recommended Posts

  • Replies 85
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

G'day, I now have a working Dallas Library that works on both 430 and Stellaris using Energia IDE. Have fun. Grant StellarisDS18B20.zip

Opps, zip file now attached GFDS18B20.zip

Tks Pivden, Yes your correct, no idea how the microsec's snuck through, they seem to do that at 2AM. Have updated the zip file. Tks again GFDS18B20V2.zip

Posted Images

  • 2 weeks later...
  • 2 months later...

Hi, i am using MSP430F5529 launchpad and DS18S20. I am trying to make it work, but search returns 1. So no devices found. I only get this.

 

G'day StellarisOW
ret=(1) No more addresses.
From array
 

I have checked the connections to make sure they are right.

The data pin is connected to pin P3.6

 

Any help please??

Link to post
Share on other sites

I'm not able to run the demo code as parasitic. What should I do to make it working? Thank you

@@hawwwran, I realize that your question is old but I have your answer for you.

 

You can operate the ds18b20 in parasitic mode for all normal interactions except temperature conversions and EEPROM programming. During those operations, parasitic mode requires that you apply a strong pull-up to DQ in order to supply extra energy to the device via the DQ pin.

 

It would seem that these energia libraries expect the device to operate in three wire mode only. That means, wire the device fully with Vcc, DQ and GND.

Link to post
Share on other sites

Hi, i am using MSP430F5529 launchpad and DS18S20. I am trying to make it work, but search returns 1. So no devices found. I only get this.

 

G'day StellarisOW

ret=(1) No more addresses.

From array

 

I have checked the connections to make sure they are right.

The data pin is connected to pin P3.6

 

Any help please??

What is your cpu clock speed set to?

Do you have a logic analyzer to inspect the signals?

Did you wire up the sensor in three wire mode?

 

The simplest one-wire test is to do a one-wire reset and see if the device responds with a presence pulse.

Link to post
Share on other sites

What is your cpu clock speed set to?

Do you have a logic analyzer to inspect the signals?

Did you wire up the sensor in three wire mode?

 

The simplest one-wire test is to do a one-wire reset and see if the device responds with a presence pulse.

 

My cpu speed is 16MHz, and i do not have a logic analyzer, sorry. I am using the three wire mode to wire up the sensor.

If the return is 1, does it mean that the device does not pull down the pulse when a reset happens??

Link to post
Share on other sites

@@Grandthau, you said that you put DQ on P3.6.  Have you told the GFDS18B20 library where to find your temperature sensor?

I constructed an object of class DS18B20 and gave the pin as a parameter. Do i have to change anything else?

After that i change the family code to 0x10h which is the code for DS18S20 sensors. But the program never reaches this point of course...

Link to post
Share on other sites

I am not an energia user so we may have to ask an energia user to pipe up here.

 

In CSS, I would have to setup both the pin number and the port number in C code so that the functions would know where to find the sensor.

 

So, the missing information is how to tell energia what port the sensor is on.

 

Figure that out and it ought to work.

Link to post
Share on other sites

Which sensor are you using?

 

There are two different temperature sensors being discussed in this thread - the DS18B20 and the DS18S20. 

 

The math to compute the temperature is slightly different for each sensor.

 

Concerning accuracy, the Dallas sensor is amazingly accurate. I have never seen one that was as bad as, say, the internal temp sensor of the MSP430 (+/- 2 degrees). 

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...