This project was designed for me to personally learn more about electronics design and embedded software design. As such, there are guaranteed to be bugs, issues and things that can be improved. I recommend not taking any of my instructions or designs at face value. However, I do have a working device so I must of done something right(ish).
The watch itself is meant to be a fun project for a more advanced tinkerer/hacker/maker. The goal is to have something that is rugged and visually pretty enough for daily wear while offering several benefits to the electronics enthusiast. Specific design goals are:
Mechanical
- Rugged and water-resistant for daily wear -- Failed
- Visually not ugly for daily wear -- Failed
- Reprogrammable without disassembling case -- Success
Electrical
- Relatively inexpensive -- Failed (BOM is $50+)
- Low Power, several days between charges -- Success (Lasts approximately 12 days in always on watch mode)
- Adjustable backlight -- Success
- Utilize a novel binary entry method utilizing 6 buttons vice a touch screen interface -- Not yet started
- Provide audible alarm -- Failed (Didn't even think about putting a speaker into it until already built)
- Interface with ESP8266 for wireless capability -- Failed (Some unknown hardware bug causes device to reset when attached)
- Able to accept daughter boards for device capability expansion:
- Keyboard for text entry -- Not yet started (probably not worth doing)
- Bluetooth -- umm, don't even know where to start
- Temperature sensing -- Not yet started
- Micro SD card for storage and data transfer -- Not yet started
Firmware
- Tells time -- Success
- Is able to decode and send I2C, SPI and UART data -- In progress
- Able to display and edit text -- Display only (editing in progress)
- Stopwatch, Timer, Alarm Functionality -- In progress
- Able to capture and display analog signals -- Not yet started (practical limit of 3.3V)
- Calculator Functionality
Known Issues:
- Shorting ESP8266 VCC to ground causes really bad things
- On device reset unused random pixels at top of screen
- Setting device time does not function correctly due to BCD/decimal error
- Device display does not clear properly following setting time
- When turning off display, backlight may become fully turned on, requiring turning on then off display to clear
- Year is not read properly (Century is hardcoded, note to self: Fix this some time in the next ~80 years)
- Day of week is not displayed properly
Lessons Learned:
- Finish your design specs before you build hardware. It is a lot harder to add a hardware function (like a speaker) after you have ordered the PCBs.
- Stop inventing the wheel. For every common thing that a processor can do, it's been done. While trying to write a function to draw lines on the screen, I floundered for about an hour to even comprehend how such a think is possible before discovering the Bresenham's Line Algorithm. Rosetta Code is amazingly awesome for this.
- Understand everything in the vendor code, but don't rely on it. I originally used vendor code to test and get the LCD working, but found that it left me without actually understanding what my hardware was doing. This being said, if you are not planning on writing a driver from scratch this isn't strictly necessary.
- Explode the prototype. I used an off the shelf SMD breakout board to prototype my specific processor on my specific LCD prior to assembling the whole mess. I really wish I spent more time exploring the firmware before I fully constructed the hardware. Then I would have known if my LCD was going to explode by changing the aforementioned code before combining it in a small combustible enclosure with other electronics.
- Document during design. Cool story, I actually designed and built the entire watch in February. Over the course of the year, I got busy and stopped at the point of getting numbers on the screen that may have been the correct time. It was late November before I got back to the project. I looked over...