Connect with us

How difficult would it be to design ?

Discussion in 'Electronic Design' started by JJ, Sep 7, 2003.

Scroll to continue with content
  1. JJ

    JJ Guest

    I am looking for a small digital clock with a feature that I can set today's
    date and a date in the future and have the clock calculate the difference in
    days, and count off the days as the date changes. I would also like this
    and the time to be displayed.

    Is this something that would be difficult to design and how expensive would
    it be to create a prototype ?

    Any help or direction would be appreciated

  2. onestone

    onestone Guest

    For someone who does embedded design work this would not be difficult,
    for someone just starting out it would be a medium level project.
    However most micros you might pick for the clock chip would probably
    have a real time clock application note somewhere, all you'd have to do
    would be to figure out the method to subtract the two dates.

  3. Don Pearce

    Don Pearce Guest

    These were made by the million during the countdown to the millennium
    (both of them, in fact ;-) ), and I'm sure they can still be had.


  4. I am looking for a small digital clock with a feature that I can set
    Quite simple in fact, you just need a microcontroller (any of them...), a
    LCD display (a small one, say 2x16 characters, some pushbuttons, a power
    supply... and some software ! As you don't have any speed constraints on
    such a design, and assuming that you are just looking for a unique prototype
    then the easiest way will probably be to use a platform programmable in
    Basic with already all LCD support functions and real time clock, like a
    Basic-Stamp or similar.It could be a quite interesting application to learn
    microcontroller technology.

    On the hardware side the cost will be limited ($100 ?), assuming that you
    will develop the software yourself...

  5. Jim Stockton

    Jim Stockton Guest

    It should not be too difficult with just about any microcontroller.
    A hint to get you started:
    Search for Julian Date.
    The two dates then become large numbers that the difference can be
    handled by simple subtraction.
    Good Luck
    Jim Stockton
  6. As others have said, if you treat it as a microcontroller "course" and
    are prepared to put the time in plus a few bucks (your tuition), it
    would not be especially difficult. The hardware design would be very

    I used to have a Casio VFD clock that would subtract any two times and
    dates and give the correct difference in hours and minutes, including
    leap years and such like. The calendar function went back to cover
    most of recorded history and forward to something like 2500 AD. I
    don't recall how accurately it handled changes to the calendar, leap
    seconds etc.

    You can probably google for algorithms to do this. If you're only
    interested in the future and relatively recent past you can convert
    the dates and times to the number of seconds since Jan 1 1970 (the
    Unix epoch) using int mktime() (IIRC), subtract using regular long int
    math, and then convert to days, hours and seconds. The latter
    conversion is very easy.

    BTW, if you want this thing to work for a long time, there's an
    upcoming Y2038 bug if you use 32-bit longs. Seems a long way off, but
    so did Y2K in 1965.

    Best regards,
    Spehro Pefhany
  7. Norm Dresner

    Norm Dresner Guest

    If what you're after is the product and not the digital design
    experience, getting and programming a palmtop computer would provide you
    with a lot more function besides this one thing.

  8. Use it for a retirement clock! I used mine for one of the senior
    techs at Microdyne. I put it on an empty bench next to his and let it
    run the last two weeks. He thought it was great. Every time he glanced
    up at one of his equipment carts he could see the time slipping away,
    till he was free on his last day.

    Another use: Put it up in the lunchroom or breakroom and set it to show
    how long till the next holiday. Good for morale.
  10. Iwo Mergler

    Iwo Mergler Guest

    There is a large 10x7-segment one here in Southampton. It must have had
    some sort of millenium bug - after it finished the countdown it crashed
    with all segments on, appart from one which flickers. It's still doing
    that now.


Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day