Now Reading
Hacking the Timex m851

Hacking the Timex m851

2023-09-03 01:09:23

Hacking the Timex m851

This put up is a part of a sequence on my quest to seek out the proper watch.

Timex m851

Check out this watch, it’s just a few boring look ahead to runners, proper?

Nope, I feel this is likely to be the perfect ultra-low energy client digital watch ever produced!

Let me clarify…


That is the Timex m851. It makes use of an 8-bit Seiko SC188 CPU, has 48KB of ROM, 2KB of RAM and a 42×11 dot matrix foremost show.

The cpu is designed for ultra-low energy operation – a single battery can final 3 years!

It is a large promoting level for me, I don’t suppose they’re making client watches like this any extra.

Timex USB Timex USB

These pins on the aspect? That’s USB. Naturally, you may synchronize issues like appointments, and so forth (there’s a neat linux library for that).

Right here’s the place it get’s attention-grabbing… this factor has an SDK, and it’s surprisingly good!

You’ll be able to simply $ cc helloworld.c, and add it to your watch.

I didn’t actually suppose I might be enamored with this watch at first – the Home windows XP-era wizard Timex offered for improvement was… painful. Nevertheless, it turned out it was simply driving a UNIX-like toolchain behind the scenes.

After pulling that out, hacking this began to turn out to be fairly enjoyable!

Makefile Hello World

Simply wish to see some code? No downside, I’ve uploaded a good day world and a Makefile to construct it to github:

If you wish to browse the total handbook, there are some hyperlinks beneath.

You are able to do some enjoyable issues with this, individuals wrote every kind of games and productiveness tools.

If you would like a TL;DR of improvement, I’ll attempt!


States and Modes

It’s worthwhile to cut up your software into states.

A state is only a solution to swap code out and in as wanted. While you change states, the lively code is discarded and the brand new code is swapped in.

You might write an app that makes use of as much as ~30kb of code and/or information, however there’s solely ~2kb of RAM. For this reason it is advisable to use states, there isn’t a paging and also you couldn’t match that in!

There’s room for some frequent code that each one your states share, and naturally there’s house for variables, and a database API for persistent information.

The primary few states are reserved for dealing with frequent occasions. The remaining you need to use for something you need – you simply ask the kernel to modify you everytime you want it!

A mode is only a foreground software.

Your app is (in all probability) offering a mode, however you too can add background duties, periodic duties, and so forth.

Requesting a mode change is form of like exit(), the following app will achieve management.


Every state wants an occasion handler. An excellent easy one could be like this:

On the whole, you may ignore any occasion you don’t care about.


The kernel takes care of dealing with the {hardware}, dispatching occasions to you and supplies numerous providers.

See Also

Issues like timers, producing tones (beeps), scrolling the show, entry to database data, and so on.

The watch has a crown – and you may ask the kernel to configure it in a couple of other ways. For instance, you may want pulse mode so you may monitor how shortly the person is popping it.

Crown Demo
Crown Demo

It has a backlight, you may management that from software program too.


There’s no reminiscence safety or something, you may simply clobber the kernel in order for you… so what occurs in the event you crash?

Effectively, one factor the kernel does is notify a watchdog each 2 seconds that it’s nonetheless alive. If the watchdog doesn’t see that notification, it’ll simply reset the watch… so attempt not to try this! ????

For those who’re performing some heavy computation you may by chance set off the watchdog. Simply bear in mind to let the watchdog know you’re nonetheless alive:

 // Let the watchdog know we're not useless.

Fortunately there’s a extremely good simulator obtainable, so that you don’t have to sit down by tedious resets everytime you make a typo. It’s truly an open supply third occasion device, Virtual Datalink.

Sadly it’s for Home windows solely. I might port it to Linux, however it’s written in Delphi… is it possible to port it to free pascal? Let me know!

It has conditional breakpoints, a dissasembler, save states, useful resource and energy evaluation. I’ve discovered it fairly succesful.

Virtual Datalink
Digital Datalink

The principle app I’m engaged on proper now’s integrating my watch with remind.

Hacking this little watch has been a brilliant enjoyable challenge!


Now that I’ve advised you the way a lot I really like this factor – the dangerous information.

They’re lengthy out of manufacturing, and getting laborious to come back by.

I purchased a set of two on eBay, they simply wanted new batteries and had been nearly as good as new.

If that is the form of factor that appeals to you, setup an alert after which assist me hack on it ????


  • An important doc is the Design Guide, it’s very properly written.
  • Then after all, you want the CPU manual. It’s additionally wonderful!
  • The toolchain additionally has an intensive handbook.
  • Lastly, the entire API reference lists the providers offered by the Kernel.

Source Link

What's Your Reaction?
In Love
Not Sure
View Comments (0)

Leave a Reply

Your email address will not be published.

2022 Blinking Robots.
WordPress by Doejo

Scroll To Top