CD4060 Q&A

Timer circuit does not work as intended (fixed)

Ask Question

Asked today

Modified today

Viewed 21 times


I am trying to make a 1 Hz clock with a CD4060, a crystal oscillator and an Arduino UNO. The problem is I am pretty sure the circuit does not work right. It oscillates but it is slower than 1 Hz.

I don’t have right now any way to make timing measurement (I try to avoid making one I just compare the serial output of Arduino by looking to windows clock). I would be happy with something that counts seconds with a small error.

The circuit oscillates if I take out the 470k resistor which means it does not use the crystal… The 4060 contains an internal oscillator, how to disable it? Any information would be appreciated.


The circuit in my case worked with the following values (in contrast with the values mentioned on the old or the newer datasheet):

both capacitors 100pF The capacitor on the (11) pin connected with some wire to add some capacitance.

Resistor 11-10 -> 1M

Second resistor 300k

corrected circuit:

enter image description here

Arduino divide by two, counting seconds and measuring period:

enter image description here


#include "printf_function.h"

#pragma GCC optimize ("Os")

bool state = false; 
uint8_t seconds = 0;
uint32_t time_stamp = 0;
uint32_t PreviousMillis = 0;
uint32_t m_i = 0;

void blink(){ 

    state = !state; 

    if( state ){
        m_i = millis();
        time_stamp = m_i - PreviousMillis; 
        PreviousMillis = m_i; 
        serial_printf( Serial, "%i   %i\n", seconds, time_stamp );
        if( seconds++ > 58 ) seconds = 0;


void setup(){

    pinMode( 2, INPUT );
    pinMode( 13, OUTPUT );
    digitalWrite( 13, LOW );
    Serial.begin( 9600 );
    attachInterrupt( digitalPinToInterrupt( 2 ), blink, RISING );


void loop(){ } 






edited 8 mins ago

asked 2 hours ago

user avatar

John Am

58988 silver badges2222 bronze badges

Add a comment

Categories: Uncategorized

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.