109 Commits

Author SHA1 Message Date
joeycastillo
996571967f bring in battery voltage face, add new method and demo for displaying floats 2024-09-30 00:24:23 -04:00
joeycastillo
0185b56972 custom LCD: fix garbled text in top row when using WATCH_POSITION_FULL 2024-09-29 22:53:54 -04:00
joeycastillo
e5b458fe3b blink colon when clock is in sleep mode (custom LCD only) 2024-09-29 15:49:51 -04:00
joeycastillo
4b8b092594 tick_animation is now sleep_animation (which just displays an indicator on new LCD) 2024-09-29 15:24:43 -04:00
joeycastillo
b66f91a0b9 add option for text across the top on custom LCD 2024-09-29 15:24:43 -04:00
joeycastillo
523d416502 add function for long weekdays 2024-09-29 15:24:43 -04:00
joeycastillo
67e33000d9 add edge cases for custom LCD 2024-09-29 14:18:53 -04:00
joeycastillo
2af976c8c8 clean up const qualifiers in display functions 2024-09-29 13:56:16 -04:00
joeycastillo
e2ac434c3b move buzzer sequence timing to TC0 2024-09-29 12:43:12 -04:00
joeycastillo
9bedee8e54 consistently use _t convention 2024-09-29 07:45:24 -04:00
joeycastillo
52578e5413 integrate utz, use DST-aware time zones instead of bare offsets 2024-09-23 23:27:10 -04:00
joeycastillo
f03a414ca8 use signed integers for UTC offset 2024-09-23 23:24:17 -04:00
joeycastillo
e1fa85faf7 fix typo 2024-09-22 15:04:34 -04:00
joeycastillo
e8cedeac6c rename enum, rearrange watch_tcc.h 2024-09-22 14:26:49 -04:00
joeycastillo
2e738db673 add buzzer volume control 2024-09-22 13:34:46 -04:00
joeycastillo
9274f532d2 improve API for text display 2024-09-19 08:42:07 -04:00
joeycastillo
dbf31b4e28 new name for irq handlers 2024-09-18 21:28:55 -04:00
joeycastillo
66f7a8802e remove dependency on Atmel HRI in storage module 2024-09-18 17:44:14 -04:00
joeycastillo
d0ca6a025a bring in deep sleep / external wake functions 2024-09-18 17:37:20 -04:00
joeycastillo
c02c89c880 clean up location of buzzer functions, notes 2024-09-18 17:25:41 -04:00
joeycastillo
422cea8ff6 simpler USB CDC with gossamer / yield (no need for TC0/TC1) 2024-09-18 17:14:06 -04:00
joeycastillo
7ee3eeac49 clean up location of some private functions 2024-09-18 17:05:10 -04:00
joeycastillo
6706452353 port ADC functions to gossamer 2024-09-18 16:10:12 -04:00
joeycastillo
9e32cbc523 port SLCD to gossamer, add new string display options 2024-09-18 16:04:55 -04:00
joeycastillo
ac88e2de8c port external interrupts to gossamer framework 2024-09-18 15:29:31 -04:00
joeycastillo
f5435d468d use #pragma once 2024-09-18 15:12:58 -04:00
joeycastillo
29d6ce42f1 bring in RTC functionality 2024-09-18 15:06:38 -04:00
joeycastillo
0585a1d0d8 consolidate buzzer and LED into TCC file 2024-09-18 14:53:46 -04:00
joeycastillo
29f020e207 port buzzer and LED functions to gossamer framework 2024-09-18 14:47:53 -04:00
joeycastillo
5ba64844e2 port GPIO functions to new framework 2024-09-18 14:33:07 -04:00
joeycastillo
02f7469400 remove ASF code, config 2024-09-18 13:56:49 -04:00
joeycastillo
9f73677883 let's begin 2024-09-18 13:47:35 -04:00
joeycastillo
0a82d16d4e remove watch_app 2024-09-18 13:19:52 -04:00
Matheus Afonso Martins Moreira
a2e5417de9 Merge PR #461 - improve t/y special case docs
Fix a typo and make the documentation clearer.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/461
2024-09-03 00:28:25 -03:00
Matheus Afonso Martins Moreira
db4097bf84 Merge PR #426 - add temperature input to simulator
This patch enhances the Sensor Watch simulator with a temperature input
allowing users to simulate and test the temperature sensor.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/426
2024-08-30 16:47:47 -03:00
Matheus Afonso Martins Moreira
663cd725f8 Merge PR #434 - fix leap years
Improves handling of months in the Sensor Watch
by computing whether the given year is a leap year.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/434
2024-08-30 16:47:38 -03:00
David Volovskiy
fe259ee526 Comment change 2024-08-26 21:40:56 -04:00
David Volovskiy
9640f452cd Made the T and Y characters look more unique on the 4 and 6 position 2024-08-22 20:46:47 -04:00
David Volovskiy
09576807eb Made the days_in_month its own function 2024-08-10 07:40:52 -04:00
Robert Masen
ccf99a9727 add temp input to simulator 2024-08-02 18:20:44 -05:00
joeycastillo
5ec3dca9e4 documentation fix 2024-07-10 06:56:49 -04:00
joeycastillo
ac5fb40730 remove dead code 2024-07-10 06:49:56 -04:00
Jose Castillo
d98d14d236
Add support for Sensor Watch Pro (#412)
* Sensor Watch Pro board definition

* Disable hot-plugging on SWCLK

* Add rainbow test

* Move interrupt mapping to board config

* New color definition for Pro boards in makefile
2024-07-06 11:07:02 -04:00
joeycastillo
89a2af92ef silence warnings 2024-07-06 08:52:41 -04:00
Matheus Afonso Martins Moreira
35c0a4be87 Merge branch 'usb-improvements' into advanced
- Change newline prints to also send carriage return
 - Introduce shell module for serial shell with argument parsing
 - Introduce shell command list for compile time command registration
 - Refactor file system commands for shell subsystem
 - Introduce new shell commands:
   - 'help' command
   - 'flash' command to reset into bootloader
   - 'stress' tests CDC serial writes of various lengths
     - optional delay parameter
 - Harden USB handling
   - Hangs less
   - Drops fewer inputs
 - Circular buffers for both reads and writes

Reported-by: Edward Shin <contact@edwardsh.in>
Tested-by: Edward Shin <contact@edwardsh.in>
Tested-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
Tested-on-hardware-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
Reviewed-by: James Haggerty <james@gruemail.com>
Reviewed-by: Wesley Aptekar-Cassels <me@wesleyac.com>
Reviewed-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
Signed-off-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/344
2024-03-08 06:51:34 -03:00
Matheus Afonso Martins Moreira
592e18bf0e Merge branch 'silicon-errata' into advanced
Implements the recommended workarounds for numerous silicon errata,
reducing power consumption and preventing freezes and hard faults.

Tested-by: Alex Maestas <git@se30.xyz>
Tested-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
Tested-on-hardware-by: Alex Maestas <git@se30.xyz>
Tested-on-hardware-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
Reviewed-by: Wesley Aptekar-Cassels <me@wesleyac.com>
Reviewed-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
Signed-off-by: Matheus Afonso Martins Moreira <matheus.a.m.moreira@gmail.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/340
GitHub-Related-Issue: https://github.com/joeycastillo/Sensor-Watch/issues/361
GitHub-Related-Issue: https://github.com/joeycastillo/Sensor-Watch/issues/359
Reference: https://ww1.microchip.com/downloads/aemDocuments/documents/MCU32/ProductDocuments/Errata/SAM-L22-Family-Silicon-Errata-and-Data-Sheet-Clarification-DS80000782.pdf
2024-03-08 06:50:16 -03:00
Alex Maestas
83a0e4e992 annotate TRNG erratum, address review comment 2024-01-22 00:39:18 +00:00
Wesley Aptekar-Cassels
50dccd07d3 buzzer: fix simulator build, refactor sequence_length. 2024-01-09 16:22:21 -05:00
Wesley Aptekar-Cassels
e9fe4aeefe Enable custom signal tones in LE mode.
This makes movement_play_signal synchronous when in LE mode, despite
using the underlying asynchronous API. It's a bit of a hack, but it
should work well enough for now.

This also moves the enabling/disabling of the buzzer into the
movement_play_signal function, so that watch faces no longer have to do
it.
2024-01-09 16:22:21 -05:00
Edward Shin
5b762d0168 USB Improvements
* Introduce shell module for basic serial shell with argument parsing
* Introduce shell_cmd_list module for basic compile-time command
  registration
* Harden USB handling to hang less and drop fewer inputs
  - Service tud_task() with periodic TC0 timer interrupt
  - Service cdc_task() with periodic TC1 timer interrupt
  - Handle shell servicing in main app loop
  - Add a circular buffering layer for reads/writes
* Change newline prints to also send carriage return
* Refactor filesystem commands for shell subsystem
* Introduce new shell commands:
  - 'help' command
  - 'flash' command to reset into bootloader
  - 'stress' command to stress CDC writes

Testing:
* Shell validated on Sensor Watch Blue w/ Linux host
* Shell validated in emscripten emulator
* Tuned by spamming inputs during `stress` cmd until stack didn't crash
2024-01-07 00:20:20 -05:00