Difference between revisions of "StackClock"

From Hackstrich
Line 2: Line 2:
  
 
== Status ==
 
== Status ==
 +
* 2017-10-17: Did as much routing of Base board as possible without knowing how big the Display boards will need to be.
 +
* 2017-10-10: Completed and checklisted Base schematic, started routing board.
 
* 2017-10-04: Put together most of the schematic for the Base Board, just need to finish the USB interface, IR emitter, and diagnostics (test points, etc.).
 
* 2017-10-04: Put together most of the schematic for the Base Board, just need to finish the USB interface, IR emitter, and diagnostics (test points, etc.).
 
* 2017-09-17: Started working on this again, putting BOM together and such.
 
* 2017-09-17: Started working on this again, putting BOM together and such.

Revision as of 21:25, 15 October 2017

I'd like a series of clocks on my desk at work to show various timezones.

Status

  • 2017-10-17: Did as much routing of Base board as possible without knowing how big the Display boards will need to be.
  • 2017-10-10: Completed and checklisted Base schematic, started routing board.
  • 2017-10-04: Put together most of the schematic for the Base Board, just need to finish the USB interface, IR emitter, and diagnostics (test points, etc.).
  • 2017-09-17: Started working on this again, putting BOM together and such.
  • 2016-09-15: Started putting this idea together.
  • 2015: Tried to find some commercial clocks I could stack up to make this, failed to find anything nice looking that supported 24h time. The Hayes Stack Chronograph would be cool but they're very rare now.

Specs

  • Arduino-compatible Base Board on the bottom has the RTC and keeps time
    • Supports multiple oscillator options:
      • TCXO (cheap, stable to ~216ms/day)
      • OCXO (less cheap, stable to ~840us/day or 305ms/year)
      • External 10Mhz clock input from a Rb/Cs or other reference
    • Has an encoder on it to allow changing the time briefly to compare between time zones
      • For instance, "this log is in UTC and it says 0502, what time was that in Calgary?"
      • A few seconds after the encoder stops rotating, display goes back to real time
  • Arduino-compatible Display Boards stack on top of that board
    • As many as you want to stack (up to maybe 8 or 16, but the bus limit with the current design would be 127)
    • Each display board has:
      • 3 alphanumeric LED displays to show which timezone
      • 4 numeric LED displays to show the time (or maybe 6, need to decide if they'll include seconds)
      • Using displays available in Red, Yellow, and Green so can have different "levels" of the stack different colours
  • Stack communicates internally via I2C
    • SCL/SDA and power carried on standoffs
  • Stack is configurable via USB interface
    • Also initial time set will happen via USB from an NTP server, once set it can free-run for a long period while staying accurate

Enumeration Process

I want the display boards to figure out what order they're in without needing to set any DIP switches or anything. To accomplish this, each board has an IR emitter pointing up, and an IR detector pointing down.

Calibration Phase

  1. Base sets ENUM as output and lowers it, displays set ENUM as input.
  2. All boards toggle emitter on and off while recording min/max detector levels.
  3. After CALIBRATE_TIME, base raises ENUM to start the enumeration process.

Enumeration Phase

  1. All boards set ENUM_COUNT as an input and reset an internal counter to zero.
  2. Base turns on LED, waits for ENUM_COUNT to go high.
  3. Whichever board sees their detector goes high:
    1. Sets themself as node #1.
    2. Sets ENUM_COUNT as an output briefly.
    3. Raises ENUM_COUNT for COUNT_HOLD_TIME.
    4. Sets ENUM_COUNT back to an input.
  4. Any boards that didn't see their detector go high just increment their counter and continue on.
  5. Once ENUM_COUNT is low again, the board that was enumerated in step 3 turns its LED on, repeats steps 2-4.
  6. When a board turns its emitter on and ENUM_COUNT does not go high in ENUM_TIMEOUT time, the enumeration process is complete.