Get 12% off, TODAY ONLY 12/12 – use the code TWELVE on check out! Some restrictions apply!

ChronoDot 32K external device clock
Moderators: adafruit_support_bill, adafruit

ChronoDot 32K external device clock

by fedez on Mon Sep 03, 2012 7:08 pm

Hi,

I would like to use the 32 kHz clock signal.
The documentation states the following:

32K
The 32K pin is open-drain (needs a pullup resistor) and outputs a 32768 Hz clock signal. This can be enabled using the EN32kHz bit in the Status register (address 0x0F). This pin could be used as an accurate oscillator reference for some external device.


If I am correct I need the following code? Right?
Code: Select all | TOGGLE FULL SIZE
void setup()
{
  Wire.begin();
  Serial.begin(9600);
 
  // clear /EOSC bit
  // Sometimes necessary to ensure that the clock
  // keeps running on just battery power. Once set,
  // it shouldn't need to be reset but it's a good
  // idea to make sure.
  Wire.beginTransmission(0x68); // address DS3231
  Wire.send(0x0E); // select register
  Wire.send(0b00011100); // write register bitmap, bit 7 is /EOSC
  Wire.endTransmission();

  Wire.beginTransmission(0x68); // address DS3231
  Wire.send(0x0F); // select register
  Wire.send(0b00001000); // write register bitmap, bit 3 is EN32kHz
  Wire.endTransmission();
}


I am thinking on using a 10K resistor connected as in the attached image.
pullup.png
pullup.png (16.14 KiB) Viewed 1058 times

Is this correct?


Thanks all for any help!
fedez
 
Posts: 5
Joined: Wed Aug 22, 2012 7:23 pm

Re: ChronoDot 32K external device clock

by adafruit_support_bill on Tue Sep 04, 2012 6:14 am

That looks about right, but I haven't tried it myself. Macetech (the designers of the Chronodot) come by these forums fairly regularly. But you might get a quicker answer if you contact them directly: http://www.macetech.com/
User avatar
adafruit_support_bill
 
Posts: 32597
Joined: Sat Feb 07, 2009 10:11 am

Re: ChronoDot 32K external device clock

by fedez on Wed Sep 05, 2012 12:36 pm

I will try my setup once my chronodot arrieves!
I'll let you know if it worked.

Thanks
fedez
 
Posts: 5
Joined: Wed Aug 22, 2012 7:23 pm