Philip P. Ide

Author, programmer, science enthusiast, half-wit.
Life is sweet. Have you tasted it lately?

User Tools

Site Tools


blog:articles:raspberry:mechanical_clock:mech_clock

Mechanical Clock

I was looking around at some of the projects people have done with their Raspberry Pi computers, and I must admit I'm pretty impressed with a lot of them. Then I came across one I've seen before: a binary clock. A binary clock usually has a set of LEDs that indicate a number in binary, so for example, 25 seconds would be displayed as 11001.

This is all well and good, and a bit (a lot) nerdy, but there are very few people in this world that can read hours, minutes and seconds off such a clock without working out what each of those digits represents. Another base would be better than base 2.

Choosing a Base

People assume - because we were wrongly taught at school - that humans use base 10 (decimal) because we have ten fingers. This is so wrong it is outrageous. Think of all the weird things in our numerical lexicon:

  • Dozen (base 12)
  • Guinea (base 21)
  • Hand (base 5)
  • Shilling (base 20)

Those are actual bases we used before the decimal system was eventually imposed by law in France after the revolution (which of course also included weights and measures). Yes, we've always used decimals too, but historically we've used a number of bases for counting, depending upon what was convenient for the things we were counting. Base 2 was never one of them.

The upshot of this is we are actually fairly proficient at counting in more than just decimal systems - even if you grew up in a modern decimal culture. Base 5 systems are known as Quinary, and counting in fives is very natural for us. Think of this: with a decimal system you can only count to ten using your fingers (without re-using any). With a quinary system you can count five on one hand and multiples of five on the other, allowing you to count up to thirty.

In fact, senary systems (base 6) are even more efficient, counting multiples of six on one hand and the remainder on the other allows you to count up to thirty-five. Most people struggle with decoding senary values into decimal, but can handle quinary values with ease.

Mechanical or Electro-Mechanical

I at first decided to go with quinary (base 5) simply because it was still rather nerdy yet readable by most people. The next thing to do was decide how the clock would function. If I used gears like a wind-up watch, my head would explode working out the gear sizes and how to regulate them. Not to mention creating them. I am though, a programmer, so that simplifies things a lot. Firstly I would need to write a program to determine the current state of the clock (the time) and then send signals to servo-motors to change the appearance of the indicators.

It would be best if the indicators only set if their new state differed from the previous state, but let's do baby steps and worry about that when the time comes. The code for a quinary clock is pretty straight forward, so first off we can get a working example of a software-only version of the clock to see how readable it is:

Base 5 Clock
25 5 1
Hours
Minutes
Seconds

If you look at the seconds, you can see how to read the clock. This is written in Javascript, which is a good language to enliven web pages, but isn't my language of choice for a long-running application. I'd prefer Go or Rust for that, but Javascript also helps me to prototype the core functionality.

Senary Clock

A senary (a.k.a. Base 6, heximal or seximal) system also looks appealing. A quinary system looks like it will fit the bill because on an analogue clock the seconds and minutes are divided into sections of blocks of five, which also neatly divides the hours into blocks of twelve. A quinary clock is easy to read because it reads very similarly to an analogue clock - so reading 6:20:10 is very simple.

As mentioned before though, a senary counting system is more efficient, using one hand to count digits and the other to count multiples of six. The clock is divided into 60 units of seconds and minutes, twelve and twenty four hours, all of which divide neatly by six.

Base 6 Clock
30 6 1
Hours
Minutes
Seconds

From a logistical point of view, assuming we were using LEDs to display in a similar fashion to these software clocks, we would actually need more LEDs to create the senary clock than the quinary clock - even if we omitted the the 30-minute and 30-second LEDs. That of course, means a mechanical version would also be more complicated.

Decisions

When it comes to art and crafts, I'm awful. I can't paint or draw to save my life. If you want a drawing that looks like it was painted by a five-year old, I'm your man. The same comes to woodwork, metalwork and soldering. I bought a Raspberry Pi Zero 2 recently, which doesn't come with any pre-soldered GPIO headers. I Have a soldering kit so decided to have a go. I watched a number of youtube videos beforehand, just to make sure I knew what I was doing, and still destroyed my Zero 2. My eyes are just not that good anymore, and my hands are not steady.

Therefore, my best bet is to buy stuff in kit for that I can easily(ish) put together. However, before I do that, I need to know whether to make a Base-5 or Base-6 clock. I feel the Base-5 clock is easier to read, but that's just me. Solution? Build a software version of the clock that can display both versions and take it out on the road to get opinions from people who have no clue as to why I would set out on such as ridiculous venture.

Your opinions count too, so if you want to leave me a message, please feel free.

This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies

Discussion

Enter your comment:
M J M M T
 
blog/articles/raspberry/mechanical_clock/mech_clock.txt · Last modified: 2024/07/23 15:12 by 127.0.0.1

Except where otherwise noted, content on this wiki is licensed under the following license: Copyright © Phil Ide
Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki