+Capt. Obvious Posted March 21, 2013 Author Share Posted March 21, 2013 go to your libraries folder, and look in the one wire folder...how many items are in the folder Link to comment Share on other sites More sharing options...
+olaggie01 Posted March 21, 2013 Share Posted March 21, 2013 EDITED: In my one wire folder, I have an examples folder, keywords.txt, onewire.cpp, and onewire.h Link to comment Share on other sites More sharing options...
+Capt. Obvious Posted March 21, 2013 Author Share Posted March 21, 2013 there should be three in the library folder plus an examples folder the files are keywords.txt, OneWire.cpp, and OneWire.h you probably extracted the library incorrectly (or not at all) the errors you are receiving are due to all or at least one of these files missing here is the library: http://www.pjrc.com/...ies/OneWire.zip Link to comment Share on other sites More sharing options...
+olaggie01 Posted March 21, 2013 Share Posted March 21, 2013 Sorry, see above. I edited my previous post. I do have those files in the one wire library. Link to comment Share on other sites More sharing options...
+Capt. Obvious Posted March 21, 2013 Author Share Posted March 21, 2013 start a fresh arduino sketch and paste the following: #include <OneWire.h> OneWire ds(3); void setup(void) { Serial.begin(9600); discoverOneWireDevices(); } void discoverOneWireDevices(void) { byte i; byte present = 0; byte data[12]; byte addr[8]; Serial.print("Looking for 1-Wire devices...\n\r"); while(ds.search(addr)) { Serial.print("\n\rFound \'1-Wire\' device with address:\n\r"); for( i = 0; i < 8; i++) { Serial.print("0x"); if (addr < 16) { Serial.print('0'); } Serial.print(addr, HEX); if (i < 7) { Serial.print(", "); } } if ( OneWire::crc8( addr, 7) != addr[7]) { Serial.print("CRC is not valid!\n"); return; } } Serial.print("\n\r\n\rThat's it.\r\n"); ds.reset_search(); return; } void loop(void) { } then verify (click the check mark) Link to comment Share on other sites More sharing options...
+olaggie01 Posted March 21, 2013 Share Posted March 21, 2013 Nope, same problem. Link to comment Share on other sites More sharing options...
(Bio)³ Posted March 21, 2013 Share Posted March 21, 2013 Sounds like he doesn't have an #include iostream or manip? Maybe missing a ; if this is like c++ I haven't programmed one yet but doesn't one code look like its not pulling the correct inclusions? Link to comment Share on other sites More sharing options...
+Capt. Obvious Posted March 21, 2013 Author Share Posted March 21, 2013 it looks like you need to edit onewire.h since you are using a due..see the following http://arduino.cc/forum/index.php?topic=141030.0 and use this onewire library (if you have a due):http://www.pjrc.com/teensy/td_libs_OneWire.html Link to comment Share on other sites More sharing options...
+olaggie01 Posted March 21, 2013 Share Posted March 21, 2013 Thanks. I guess using the due will be more of a pain than I hoped. Guess I'll have to check everything on the arduino website to see if modifications to the libraries should be made for the due. Link to comment Share on other sites More sharing options...
+Capt. Obvious Posted March 21, 2013 Author Share Posted March 21, 2013 well...it is new hardware...things change a bit I only have an uno and a Mega to test the code with Link to comment Share on other sites More sharing options...
Stephen Posted April 29, 2013 Share Posted April 29, 2013 here is the rough layout: I don't think I am doing this right.. I have my temp sensor hooked up to the 3 pin just like your diagram and when I run the one wire address finder I get nothing.. It says "Looking for 1-wires device"...It doesn't seem to be recognizing the sensor. Any ideas? Link to comment Share on other sites More sharing options...
+Capt. Obvious Posted April 29, 2013 Author Share Posted April 29, 2013 Can you post a pic? Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.