Close
0%
0%

Vlad's Round Watch

ATTiny841 based wrist watch for 9 year old

Similar projects worth following
A few years ago, I made a simple toothbrush timer for my son. It was basically a DigiSpark clone with a WS2812 LED, a button and a piezo buzzer, and programmed to time him for 3 minutes, display different colors during that time, and beep at the end. It worked out so well, I wanted to make him a portable version to keep track of time when playing with friends, how long before he had to start his homework, etc.

I thought if I'm going to make a timer for him to carry around, I might as well make it in the form of a wrist watch. For reasons of both simplicity (I didn't want to solder or figure out how to drive 60 LEDs for the minutes), and practicality (a 9 year old doesn't really need to tell the time down to the minute), I thought I'd just make it round to the nearest 5 minutes. I could make it physically round, and call it his Round Watch.

I settled on a Tiny841 because it had enough IO's for what I wanted to do, and because it was supported by the Micronucleus bootloader, so I could program it over USB.  For driving the LEDs, I found the IS31FL3235 from ISSI, which is a 28 channel LED driver and communicates over I2C.  For timing, I choose the LCC8 M41T62 from ST because it had an integrated crystal in an incredibly small package.  Lastly, an MCP73831 from Microchip handles the lipo charging.  


I've been working on it in my spare time over the past 2 to 3 months and it's coming down the home stretch.  Here's a video of the basic functionality:




I've started working on the case/housing for it.  I just made a test case from clear acrylic on a Taig CNC mill before making the final piece from aluminum.  The face will be clear acrylic or polycarbonate, whichever I have on hand.  The face piece will screw into the aluminum housing, hold the PCB in place, and the face itself will be thin enough to be mildly flexible, so he'll be able to press the button "through" the face. 

RoundWatch7.zip

In progress source code...

x-zip-compressed - 4.29 kB - 08/12/2019 at 23:48

Download

Vlad's Round Watch Source.zip

Source files for Vlad's Round Watch. Bootloader hex and config files, KiCad project and exported gerbers and a BOM with links to components. I didn't list prices and only linked to parts on DigiKey for simplicity. Shop around for best prices or preferred suppliers. Resistors, caps and LEDs, I didn't link to specific parts since most will just use what they have on hand.

x-zip-compressed - 296.48 kB - 03/31/2019 at 22:46

Download

  • 1 × Microchip ATTiny841 Microcontroller
  • 1 × ST M41T62 RTC in LCC8 package
  • 1 × ISSI IS31FL3235 28 channel LED driver
  • 1 × Microchip MCP73831 Single cell lipo charger
  • 26 × 0603 LEDs Various colors

  • Posted files

    Chris O'Riley03/31/2019 at 02:19 0 comments

    Hi Everyone, 

    Just a little update. 

    I posted the KiCad project files with footprints and a set of exported gerbers.  The PCB has a few minor changes to resolve the issue of the LED driver getting disabled after the battery died.  I had left the enable pin floating, which worked fine in all my testing, but seemed to get latched low after the battery died once everything was on the real PCB.  It's now tied high and has been verified to work on Vlad's watch by bodging a single strand of wire between the enable pin on the LED driver and a nearby v+ source.  That was some fine soldering! ;)  I also moved the test point for the Tiny 841's reset pin out from under the piezo buzzer so it's still accessible after soldering the buzzer should the bootloader need to be re-flashed or fuses changed.  I had the PCB made in a .8mm thickness.  If you make one thicker, the housing will need to be modified to accommodate the extra thickness.

    There's also an Excel spreadsheet with all the components.  I didn't list prices and only included links to the parts on DigiKey for simplicity since they have everything.  On the LEDs, resistors and capacitors, I didn't list specific part numbers or links, since I assume people will have these on hand in a sample book or something, or will want to choose their own color LEDs.  These parts aren't too critical, as long as they're the specified values and 0603 packages.  The two zener diodes on the USB + and - lines are somewhat critical, so I listed the specific ones I used.  

    Lastly, I included the bootloader for the Tiny841, the hex and the config file should anyone want to make changes.  This sets the correct pins for the USB lines and configures it to enter programming on a watchdog reset, which I'm using so it can be reset from within the sketch.  This was important to be able to keep to the single button for input.  A triple press of the button after the time is displayed sets a watchdog reset, which will then accept programming.  Use the following command to flash the bootloader and set the fuses:

    avrdude -c stk500v1 -B 10 -P COM12 -b 19200 -p attiny841 -e -U flash:w:t841.hex:i -U lfuse:w:0xE2:m -U hfuse:w:0xDD:m -U efuse:w:0xF4:m

    Obviously replace the com port and the location of the .hex file with your specifics. 

    I'm changing the programming and time/alarm setting around a bit, so I won't post the sketch for now, but if anyone really wants it, let me know and I'll send it.

    Need to finalize the housing files before I can post anything remotely useful... will do so ASAP.

    -Chris

  • Done! Pretty much almost!

    Chris O'Riley02/24/2019 at 22:25 0 comments

    Face plate is done and everything is ready for my son to start wearing it to school, which he's been itching to do for months now!

    I'll probably be making a new face plate with some tweaks to the dimensions to reduce the pressure needed to press the button.  It's not hard now, but I think I can make it a bit easier.  And plastic mills like butter compared to metals, so it wouldn't take long.  Aside from that and a few tweaks to the programming, it's pretty much done.


    There's one issue I'm investigating that might require a modification to the PCB.  Once I take care of that, or rule out that the circuit might need to change, I'll post the KiCad files, Arduino sketch and 3D model of the housing.  

    Here's a video of it working:




    And here's some photos:


  • Band done, face next.

    Chris O'Riley02/22/2019 at 21:32 0 comments

    My Son's chosen band was delivered today and I *carefully* drilled the holes for the pins.  I sacrificed two drill bits by snapping off a little more than an 1/8th inch of the ends and gluing them into thin plastic tubes.  This let me bend the tube slightly as I twisted so I could drill the hole as straight as possible while avoiding the lug thing on the other side... if that makes sense!  

    Just down to the face piece, which is small and pretty simple.

  • Final polish, PCB in place.

    Chris O'Riley02/18/2019 at 03:33 0 comments

    Final polish and milled out the opening for the USB port.  Down to just the face and drilling the holes for the watch band pins, which I'll probably do by hand.


  • Quick sanding and polish...

    Chris O'Riley02/17/2019 at 04:49 0 comments

    And I couldn't resist a quick sanding and polish....

  • Milled aluminum housing

    Chris O'Riley02/17/2019 at 02:14 0 comments

    Milled the housing today, still need to mill the hole for the USB port, but I'll have to make a bracket to hold this piece vertically.  A little sanding and polishing and this piece will be done.  Then it's on to the clear face piece.  Going to buy a band with a magnetic clasp (son already picked out what he wants).  I'm not crazy enough to try to mill all the pieces for a band!  





View all 6 project logs

Enjoy this project?

Share

Discussions

A-Ibrahim wrote 08/12/2019 at 17:35 point

Hi, thanks for this great project

please is the source code available for learning purposes?

  Are you sure? yes | no

Chris O'Riley wrote 08/13/2019 at 00:00 point

It's definitely a work in progress, but I just uploaded a zip with the latest Arduino sketch. 

I'm changing things around a bit, so I think the alarm functions are disabled, but the basic time keeping is all working.  To enter programming mode, you triple click after the time is displayed (while it pauses on the time before the lights fade out).  That triggers a watchdog reset into bootloader/program mode and it acts like any other micronucleus AVR from there. 

To make setting time/alarm easier, I plan to set the alarm with a long press wakeup, and time with a long press after the time is displayed.  Having both functions together was confusing for my son and he kept changing the time when trying to set an alarm.

Got a little sidetracked with the project, hopefully I can get back to it soon.

  Are you sure? yes | no

A-Ibrahim wrote 08/13/2019 at 13:09 point

installed both "SoftWire-2.0.0" and "AsyncDelay-1.1.0" but when compiling the source code in Arduino IDE keep getting this error

no matching function for call to 'SoftWire::SoftWire()'

any help please?

  Are you sure? yes | no

TwinkleTwinkie wrote 03/28/2019 at 17:43 point

Looks great!  How many layers is the PCB?

  Are you sure? yes | no

Chris O'Riley wrote 03/28/2019 at 20:12 point

Thanks!  It's two layers, it was challenging routing all the traces, but I managed to fit them all in.  Hopefully I can wrap this up soon and post all the files.  Been tied up with work for the past few weeks.   

  Are you sure? yes | no

Chris O'Riley wrote 03/09/2019 at 04:58 point

Pretty sure I have the minor problem worked out.  It looks like it was an issue with the bootloader, not with the circuit, although I'm still going to change the board slightly.  I recompiled the firmware with some different settings for the bootloader entry and timeout and it's working on a bench power supply.  Just going to confirm it works when the battery drains and then I'll wrap it all up and post files.  

  Are you sure? yes | no

Nikhil wrote 03/05/2019 at 11:38 point

This is sweet. Which battery is used here ?

I wonder if this could be adapted to run something like a e-ink based watch..

  Are you sure? yes | no

Chris O'Riley wrote 03/05/2019 at 14:09 point

Thanks!  The battery is a 50mAh lipo from e-bay.  If you search lipo 360821, you'll find lots of them.  I don't want to link to a specific listing because they come and go.  For those that don't know, the numbers on cells like this are the dimensions - in this case, 3.6mm thick, 8mm wide and 21mm long. 

I'd love to make something with an e-ink display at some point.  It would have the huge advantage of displaying the time continuously without an increase in power usage.  But I haven't seen many or really any round e-ink displays readily available.  Hopefully that'll change as the tech proliferates.  

  Are you sure? yes | no

Nikhil wrote 03/07/2019 at 07:58 point

That's great info! and thanks a lot for explaining the bit about numbers and size, as I couldn't find a 360821 locally, but there were other in similar that didn't write dimensions on the page.

Somebody had started on a smart e-ink watch here. But I don't think that got around anywhere https://hackaday.io/project/21581-flexible-smartwatch

  Are you sure? yes | no

k1200s wrote 03/04/2019 at 04:22 point

Well done! Nice work!

But I have one question: how do you see if the minute's indicator is in between the 5 min. markers?

  Are you sure? yes | no

Chris O'Riley wrote 03/04/2019 at 15:09 point

Thanks!  As to your question... you don't!  ;)  The time is rounded to the nearest 5 minutes.  So about 2.5 minutes before to 2.5 minutes after a 5 minute mark, that light is illuminated.  I figured mt son didn't need to tell the time down to the minute.

A few ways were suggested below to indicate the actual minute, with the cleanest being to blink the minute light the number of minutes the actual time is after a 5 minute mark.  So it'd light up as it does, but then blink the minute light for each minute after the 5 minute mark.  That should be pretty easy to program, which I'll do as soon as I finalize the PCB.

  Are you sure? yes | no

k1200s wrote 03/04/2019 at 18:03 point

Thanks for the reply!

Looking forward to make one, as soon as you kindly share the schematic/programming files...

  Are you sure? yes | no

Chris O'Riley wrote 03/04/2019 at 21:39 point

No problem, and I'll be posting files soon.  I just need to confirm a small issue and probably make a small change to the PCB to fix.  I left the enable pin on the LED driver floating because it didn't seem to matter when I tested it on a separate breakout board I made prior to designing the watch board.  But when the battery drains, the LED driver seems to get stuck disabled.  I'm thinking the enable pin is getting latched low.  Once I confirm that, I'll update the PCB and post files.

  Are you sure? yes | no

Kurt Roesener wrote 03/03/2019 at 15:50 point

Looks great!! 2 questions, 1.  Did you solder this up by hand?  2.  Do you have the PCB boards on OSHpark or someplace that we can order them?

  Are you sure? yes | no

Chris O'Riley wrote 03/03/2019 at 18:53 point

Thanks, yes, all soldered by hand.  If people are interested, I might do a video on how to solder components that small.  It's hard to believe, but it's not as hard as it looks!  Definitely need hot air for the ICs, and in my experience, the key is to tin the pads on the ICs and the board with an iron first.  Doing that, I'm pretty much at a 100% success rate down to these .4mm pitch pads on the LED driver.  And on the PCB, yea, I'll be making it available as soon as it's finalized.  There's one or two small changes I want to make after I confirm a small issue, and then I'll post all the files.

  Are you sure? yes | no

hacky wrote 03/02/2019 at 04:13 point

Terrific project! How long does the battery last?

  Are you sure? yes | no

Chris O'Riley wrote 03/02/2019 at 17:09 point

Thanks everyone.  On the battery life, I'm testing that now that it's seeing normal use.  My son has been wearing it daily, and it's on its 5th day since being charged last.  I measured it at about 15 mA while displaying the time, and I think a few 10's of micro amps while in sleep.  The Tiny841's internal pullups on the interrupt pins  (button and RTC) consume a portion of that, and I just realized I could set the pullup on the RTC pin only when an alarm is set, as it's not needed otherwise.  I'd love to get it to last a solid week on a charge, but even if not, 5 days is fine.  It recharges pretty quickly, so if needed to be popped on a charger twice a week, I'd be happy with that.  

  Are you sure? yes | no

k1200s wrote 02/27/2019 at 02:08 point

Great project! Looking forward to make one to myself!

  Are you sure? yes | no

Tobias wrote 02/18/2019 at 17:22 point

Superb work on the case, it looks really good!

  Are you sure? yes | no

Chris O'Riley wrote 02/19/2019 at 23:31 point

Thanks!  When my son saw it polished up, he said "Wow!  I'm going to be going to school FANCY!!!"  ;)

  Are you sure? yes | no

Dan Maloney wrote 02/14/2019 at 15:45 point

Really, really cool! But I don't know why you'd go with aluminum for the case - that acrylic is pretty boss looking by itself!

  Are you sure? yes | no

Chris O'Riley wrote 02/23/2019 at 03:35 point

Thanks!  I agree on the acrylic, if it was me, I'd polish it up to glass-like clear and go with that, but my son has his heart set on polished aluminum.  It's such a small piece, it won't take too long to mill, and since the PCBs come in 3s, I'll probably make up a second one and put it in the acrylic case. 

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates