shieldbase confusion for a n00b
#1
Posted 13 August 2012 - 03:08 AM
#2
Posted 13 August 2012 - 12:29 PM
#3
Posted 13 August 2012 - 01:17 PM
#4
Posted 13 August 2012 - 03:09 PM
Hi Ulrik,
Thanks for your explanation. I only used the RTC example as that is what I had been working on. My confusion still lies wht the driver itself. It uses the following code to begin the connection:
Clock = new I2CDevice(new I2CDevice.Configuration(CHRONODOT_ADDRESS, 100));
It never specifies any pins, etc. So that is where my confusion comes in.
Thanks again!
Greg
The pin specification is implicit, on the Netduino+ I2C is available only on pins A4 & A5. When taking the library to the Netduino!Go You'll have to make it more generic. What I would do is have the class' constructor take an I2CDevice as a paramter then you'll have something like this
ShieldBase sb = new ShieldBase(); I2CDevice i = new I2CDevice(new I2CDevice.Configuration(...), sb.I2C); Clock c = new Clock(i);
When you talk EE use small words, I'm just a Software Developer
My Blog/Site and Everything Else
If my post helped you please consider pressing the "Like This" button in the bottom right-hand corner.
Oh my. So many things, so little money!!
#5
Posted 13 August 2012 - 03:57 PM
- Arron Chapman likes this
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users