Best Answer cce1911, 31 July 2013 - 04:26 AM
It looks like this wiring diagram may have been for the N+: http://netmftoolbox....ailable classes
The N+2 has pins SC and SD. When I wired my RTC to these pins, everything worked.
Go to the full post  | ||||||||||||||
Toolbox.NETMF.Hardware.DS1307 problem
Started by cce1911, Jul 30 2013 07:16 PM
Best Answer cce1911, 31 July 2013 - 04:26 AM
It looks like this wiring diagram may have been for the N+: http://netmftoolbox....ailable classes
The N+2 has pins SC and SD. When I wired my RTC to these pins, everything worked. Go to the full post
1 reply to this topic
#1Posted 30 July 2013 - 07:16 PM I purchased this RTC: http://www.adafruit.com/products/264
But when I go to set the time using the Toolbox.NETMF.Hardware.DS1307 I get the following error: "Something went wrong setting the time. Did you use proper pull-up resistors and is there a 3V battery connected?"
The wiring is pretty simple and I've double checked it (see pic).The kit has the resistors and the battery, any ideas?
Here is the code where it fails: DS1307 RTC = new DS1307(); RTC.SetTime(2013, 7, 29, 23, 14, 0);
here is the toolbox code where the call is throwing an exception public void SetTime(DateTime Time) { // Writing 7 bytes to the buffer, starting at address 0 int BytesTransferred = this._Device.Write(new byte[] { 0x00, (byte)Tools.Hex2Dec(Time.Second.ToString()), (byte)Tools.Hex2Dec(Time.Minute.ToString()), (byte)Tools.Hex2Dec(Time.Hour.ToString()), (byte)Tools.Hex2Dec(((int)Time.DayOfWeek).ToString()), (byte)Tools.Hex2Dec(Time.Day.ToString()), (byte)Tools.Hex2Dec(Time.Month.ToString()), (byte)Tools.Hex2Dec((Time.Year - 2000).ToString()) }); if (BytesTransferred != 8) throw new ApplicationException("Something went wrong setting the time. Did you use proper pull-up resistors and is there a 3V battery connected?"); }
Attached Files#2Posted 31 July 2013 - 04:26 AM Best Answer It looks like this wiring diagram may have been for the N+: http://netmftoolbox....ailable classes
The N+2 has pins SC and SD. When I wired my RTC to these pins, everything worked. 0 user(s) are reading this topic0 members, 0 guests, 0 anonymous users | ||||||||||||||
|
||||||||||||||
This webpage is licensed under a Creative Commons Attribution-ShareAlike License. | ||||||||||||||