Smart-watches are becoming the next big thing, but with increased miniaturization it is
becoming impossible to build these sorts of devices yourself. This project aims to provide
a "smart-watch" which can be built from readily available components (eg. from element14, digikey, etc.),
and able to be soldered by hand. Of course, processing power must be sacrificed, but who
needs a camera and 60FPS graphics on a watch???
I have been working on this watch since early 2013, and it has come a long way!
It is still very much a work-in-progress though, and I am working on another hardware revision
which will fix all the hardware bugs.
(you can read more about those from my previous posts on the project)
The watch features a PIC24F microcontroller and a 128x128 RGB OLED display, along with an
accelerometer and magnetometer. The goal is to have both USB-HID (driverless) and
Bluetooth 4.0 LE connectivity, so I can sync the calendar quickly and easily.
Real-Time Clock - It can tell the time!
University Timetable - I can tell when and where my next class is
USB-HID comms and bootloader
Basic accelerometer logging
Battery charging & monitoring
Anti-aliased font drawing (Just grayscale at the moment, no "clear-type")
Bluetooth 4.0 LE
Alarm clock with peizo buzzer
Desktop GUI for updating the calendar
The hardware is a 2-layer design utilizing SMD components, and is fully open-source in case you'd like to build your own.
Schematics and PCB layout were done using Altium, which unfortunately is quite expensive, but they recently announced they
would be releasing a free version sometime in the future!
Watch sometimes resets when waking up (possibly supply decoupling issues)
USB comms task sometimes doesn't go to sleep (drains the battery)
OLED display has some weird ghosting artifacts
In the schematic I got the connector around the wrong way, so the OLED is on the opposite side of the PCB than I wanted.
I didn't assign the OLED data lines to the PIC24's TFT driver, so I can't make use of it and drawing performance is less than what it could be.
Bluetooth 4.0 is untested
There are a few minor "bodges" on the PCB required to make it function correctly
Future (Rev 3)
I am working on a revision 3, which will fix all of the above issues and make the PCB much more compact!
Stay tuned... (Subscribe to the RSS feed to keep up-to-date)
The firmware is available on my github: jorticus/zeitgeber-firmware
You will need the MPLAB-X IDE, the XC16 free compiler, and the Microchip Application Framework.
Alternatively you can download the bootloader & firmware binaries here: oshwatch-binaries.zip
Custom RTOS, with power saving
Custom graphics library, with anti-aliased text drawing
This is a fun project I did for my computer vision research project at the University of Canterbury.
It uses the Kinect face-tracking library to replace a user's face with a custom face, which warps to match their expression.
It is written in C++ and includes a few GLSL shaders.
A stand-alone version is available here if you want to try it out:
You'll need to download the Microsoft Kinect SDK Runtime which installs the required device drivers for the Kinect.
Alternatively you can use a different depth sensor, as long as it works with OpenNI2.
I developed this project in Visual Studio 2013 (MSVC++ 12), but it should work in other versions provided you can compile the required libraries.
Before you can compile this, make sure you set up the following libraries:
Detect head pose and face features using Kinect SDK
Deform the Candide-3 mesh to the given head pose and face features
Process the RGB + Depth frames using OpenCV
Draw the RGB video frame
Draw the texture-mapped candide-3 model in OpenGL, using a custom blend shader.
Side-note: This project uses a custom candide-3 face model instead of the Kinect SDK's internal model,
since it's not easy to match vertices with tex coords using the internal model.
This functionality is provided through the WinCandide-3 project
(all source code named 'eru' is part of this project).
It's probably unlikely I'll do much more on this project since I have other commitments, but here's a list of things that could be improved upon in the future:
Write a plugin for blender that can read and write the candide-3 model, so textures can be more accurately mapped. (I'm currently using the WinCandide-3 utility to approximately map the texture)
Add support for multiple people
Decrease tracking latency/improve face location. (Perhaps something like meanshift/optical flow + a kalman filter?)
So it's been a while since I last posted about my OLED watch, and I've done a lot of work on it! (And also broke it multiple times)
It's taken me a lot of work to get this far, and I developed EVERYTHING from the ground up. The electronics design, the PCB layout, the RTOS and firmware drivers, the graphics engine, the user-mode app code, and even USB communications apps. I've used C, C#, and Python extensively in this project, and Altium Designer for the schematic and PCB.
Overall it has been an awesome learning experience, and if I was to make another one I would do a lot of things differently!
Here's a few features of my firmware:
USB HID Communication (No PC drivers required!)
Watch face for telling the time (Kind of required...)
Date & Upcoming events
RTOS Kernel debug info
And some features planned for the future:
Bluetooth 4.0 (Still need to get the IC for it though)
Smart alarm clock that wakes me up at the ideal time, by detecting my sleeping patterns through the accelerometer
Auto screen on by rotating or shaking my wrist
If you've read my last blog post, you'll know that I ripped the USB traces off my last PCB! I ended up using my hot-air reflow station to transfer the components to a spare PCB, and luckily it all powered up and worked after that! Here are some photos of my reflow process:
Notice how I soldered the OLED directly to the PCB, I had used a connector in my last board but it added extra distance to the OLED cable, so it wouldn't fit into the case. Soldering directly to the PCB gave me a few more millimeters to work with!
I was going to print a case for my watch on the 3D printer, but then I found something far more suitable - an aluminium case designed for iPod Nanos. After struggling with metal cutters and grinders, I managed to turn it into something my watch could fit into:
It's by no means waterproof, but it looks nice!
Unfortunately I found that the cable on the OLED screens doesn't like being bent at tight angles:
After breaking two screens this way I decided to try and fix it:
This provided enough strength to the cable to prevent it from breaking, and it's working beautifully now!
I've also had a few bugs with my hardware design, and they are so much harder to debug than software! One particuarly problematic issue was that my LiPo charger circuit wouldn't charge the battery if it was completely flat! The only way to power it back up was to apply voltage directly to the battery to "jump-start" it. Eventually after many iterations of soldering in different resistors, I noticed I had set the charge current an order of magnitude too low (something like 10mA charge current instead of 100mA), so the battery would never charge. After replacing that resistor it came right.
Now the hardware is mostly done, I just need to work on the user interface to make it more usable. Currently battery life is just over 24 hours with intermittent use, but I plan on extending that through better firmware.
I've released the schematics, PCB layout, and firmware as open-source:
OSHW OLED Watch