CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

2 ds18s20

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
jeremy57350



Joined: 11 Jan 2012
Posts: 14

View user's profile Send private message

2 ds18s20
PostPosted: Thu Feb 02, 2012 8:38 am     Reply with quote

hello,
I have just acquired a DS18S20 sensor via one wire bus, now I am interested in the acquistion of two sensors and read their ROM code

for this I thought to read a code Roma and me on a afiche aficheur
I can not but if anyone can help me

I thought this:

Code:

float ds18s20_read1()
{
long int toto;
 onewire_reset();
onewire_write(0x33);
toto=onewire_read();
return (toto);
}


and

Code:


while (1)
{
 lcd_gotoxy(2,2);
temperature = ds18s20_read();
printf(lcd_putc,"\f%3.1f%cC", temperature, 223);
 
 
}
}

temtronic



Joined: 01 Jul 2010
Posts: 9162
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Thu Feb 02, 2012 9:16 am     Reply with quote

There are drivers for this chip in the examples folder as well as the code library here in this forum.
jeremy57350



Joined: 11 Jan 2012
Posts: 14

View user's profile Send private message

PostPosted: Thu Feb 02, 2012 4:02 pm     Reply with quote

thank you, I'll get this. would you have the links please?
dyeatman



Joined: 06 Sep 2003
Posts: 1923
Location: Norman, OK

View user's profile Send private message

PostPosted: Thu Feb 02, 2012 5:01 pm     Reply with quote

The CCS examples folder is on your hard drive in PICC\Examples

For the Code Library click on CCS Forum Index at the top left
(right above the blue line) then select Code Library.
_________________
Google and Forum Search are some of your best tools!!!!
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group