Go Down

Topic: Problem with OneWire library (Read 2177 times) previous topic - next topic



I recently picked up a Due and I'm finding that the OneWire library is giving me some compile errors.

Just trying to run the example "DS18x20_Temperature" in theOneWire\examples\DS18x20_Temperature folder give me a bunch of errors.  Since this is a very commonly used library I was wondering, has anyone been able to get this working on their Arduino Due?

Here is the error that is coming up when compiling:
Code: [Select]

In file included from DS18x20_Temperature.pde:1:
C:\Users\KCORE\Documents\Arduino\libraries\OneWire/OneWire.h:77: error: #error "Please define I/O register types here"
C:\Users\KCORE\Documents\Arduino\libraries\OneWire/OneWire.h:84: error: 'IO_REG_TYPE' does not name a type
C:\Users\KCORE\Documents\Arduino\libraries\OneWire/OneWire.h:85: error: ISO C++ forbids declaration of 'IO_REG_TYPE' with no type
C:\Users\KCORE\Documents\Arduino\libraries\OneWire/OneWire.h:85: error: expected ';' before '*' token

The OneWire library I'm using is from this link:

Thanks for any replies or help you can provide.


I'd very much like to get this working as well so I can talk to my 1-wire EEPROM.

I tried the Teensy library and mucked around with some changes, but didn't have much luck. I would think this library would be pretty important.

I tried the modifications to the code as posted here:

But still ran into compiler errors after this as well, where: "digital_pin_to_info_PGM[(pin)] was not delared in this scope"

Is there something in the core that needs to be modified?

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131