117 Commits

Author SHA1 Message Date
Alexsander Akers
84b65cb699 Remove ADC_* defines in favor of hardware-specific mapping 2022-01-25 17:28:15 -05:00
Alexsander Akers
b8de35658f
Sensor Watch Simulator (#35)
* Put something on screen

* Use the 32bit watch_date_time repr to pass from JS

* Implement periodic callbacks

* Clear display on enabling

* Hook up watch_set_led_color() to SVG (green-only)

* Make debug output full-width

* Remove default Emscripten canvas

* Implement sleep and button clicks

* Fix time zone conversion bug in beats-time app

* Clean up warnings

* Fix pin levels

* Set time zone to browser value (if available)

* Add basic backup data saving

* Silence format specifier warnings in both targets

* Remove unnecessary, copied files

* Use RTC pointer to clear callbacks (if available)

* Use preprocessor define to avoid hardcoding MOVEMENT_NUM_FACES

* Change each face to const preprocessor definition

* Remove Intl.DateTimeFormat usage

* Update shell.html title, header

* Add touch start/end event handlers on SVG buttons

* Update shell.html

* Update folder structure (shared, simulator, hardware under watch-library)

* Tease out shared components from watch_slcd

* Clean up simulator watch_slcd.c inline JS calls

* Fix missing newlines at end of file

* Add simulator warnings (except format, unused-paremter)

* Implement remaining watch_rtc functions

* Fix button bug on mouse down then drag out

* Implement remaining watch_slcd functions

* Link keyboard events to buttons (for keys A, L, M)

* Rewrite event handling (mouse, touch, keyboard) in C

* Set explicit text UTF-8 charset in shell.html

* Address PR comments

* Remove unused directories from include paths
2022-01-25 15:03:22 -05:00
Joey Castillo
68f17c8970 movement: add time zone conversion in sunrise/sunset face 2022-01-21 00:11:43 -05:00
Joey Castillo
3efdcd78a1 fix out of bounds access when position != 0 2022-01-19 17:22:31 -05:00
Joey Castillo
19fd519209 add gettimeofday function 2022-01-15 12:26:17 -05:00
Joey Castillo
68e792f9b7 lis2dw: add low power / low noise mode 2022-01-09 12:25:56 -05:00
Joey Castillo
a102675522 set correct registers for range and rate 2022-01-09 12:12:41 -05:00
Joey Castillo
54762248a3 use lowest power LP mode 2022-01-09 12:06:44 -05:00
Joey Castillo
71c2eaa3f9 shuffle uart pins for new accelerometer board 2022-01-09 12:05:21 -05:00
Joey Castillo
5ceec26d5a start in low power mode 2022-01-09 12:02:58 -05:00
Joey Castillo
1ea476ca24 remove unused enums 2022-01-09 12:02:26 -05:00
Joey Castillo
496530c85c add driver, test app for LIS2DW accelerometer 2022-01-08 19:27:41 -05:00
Joey Castillo
b341227797 add utility function to check if TCC is enabled 2021-12-21 10:01:33 -06:00
Joey Castillo
762af872d2 fix missing prototype warnings 2021-12-10 12:00:26 -05:00
Joey Castillo
bbd394a19a use true random number generator to provide entropy 2021-12-03 21:12:15 -05:00
Joey Castillo
b8c824419f remove A LOT of dead ASF lcd driver code 2021-12-02 22:50:47 -05:00
Joey Castillo
36be251e89 lis2dh: add support for interrupt latching (stays active until cleared) 2021-12-01 09:41:48 -05:00
Joey Castillo
45282f2ef4 lis2dh driver: add support for int2 pin 2021-11-30 20:02:41 -05:00
Joey Castillo
4ae46f907b lis2dh driver: add basic interrupt functionality 2021-11-30 19:33:49 -05:00
Joey Castillo
48ceef7af3 fix (most) external interrupts on the 9-pin connector 2021-11-30 17:02:42 -05:00
Joey Castillo
473bd1637a lis2dh driver: make the implicit explicit 2021-11-30 11:55:16 -05:00
Joey Castillo
812c6c2612 more character map edge cases 2021-11-29 10:28:02 -05:00
Joey Castillo
470544823b add LIS2DH accelerometer driver, test app 2021-11-27 13:32:33 -05:00
Joey Castillo
4a4ab81c6c remove log statements (oops) 2021-11-25 13:18:10 -05:00
Joey Castillo
ac43c1ca48 utilities: convert unix timestamp to watch_date_time 2021-11-25 11:10:06 -05:00
Joey Castillo
5c3967aea2 movement: implement time zone setting 2021-11-25 10:36:01 -05:00
Wesley Ellis
653dd862b8 Fill out watch_utility_convert_to_unix_time 2021-11-23 21:32:25 -05:00
joeycastillo
f9e3dc865d
add stubs for UNIX timestamp conversion 2021-11-23 15:57:18 -05:00
joeycastillo
ad558da328
add stubs for UNIX timestamp conversion 2021-11-23 15:54:12 -05:00
Joey Castillo
7817e6696e Merge branch 'main' of github.com:joeycastillo/Sensor-Watch into main 2021-11-22 17:35:50 -05:00
Joey Castillo
0ca729eaba move thermistor calculation to watch utilities 2021-11-22 17:31:51 -05:00
Joey Castillo
0f03257ee9 movement: add voltage monitor watch face 2021-11-06 23:52:00 -04:00
Joey Castillo
2d6fcd77ab add ability to preview display on USB serial 2021-10-29 12:09:45 -04:00
Joey Castillo
f98bc9bb4e steps toward SPI support in watch library 2021-10-25 16:06:08 -04:00
Joey Castillo
22c072ac3f Merge branch 'main' into more-asf-files 2021-10-25 14:52:40 -04:00
Joey Castillo
8f6cd8b290 move weekday lookup to new utilities file 2021-10-23 16:13:11 -04:00
Joey Castillo
f1a706792e movement: add character set demo 2021-10-21 17:28:59 -04:00
Joey Castillo
4df23ea9f9 typo in documentation: all five pins are analog capable 2021-10-21 15:10:06 -04:00
Joey Castillo
38a2dff234 more accurate names for deep sleep and shallow sleep modes 2021-10-20 13:45:22 -04:00
Joey Castillo
148a47f76a movement: add tick animation in sleep mode 2021-10-19 15:37:08 -04:00
Joey Castillo
52c5747d2e getting the sensor watch dev board working 2021-10-19 10:14:24 -04:00
joeycastillo
6210e1c233
Merge pull request #17 from joeycastillo/wip-launcher
Resolves #13
2021-10-18 15:37:41 -04:00
Joey Castillo
7f8973a8cc slcd: add more special cases 2021-10-04 14:12:39 -04:00
Joey Castillo
4300dff616 launcher: first crack at low power 'screensaver' mode 2021-10-03 20:47:15 -04:00
Joey Castillo
8d5280a34f slcd: add function to blank entire screen 2021-10-03 18:48:55 -04:00
Joey Castillo
84c0fbfa2a slcd: add autonomous blinking and animation 2021-10-01 20:53:32 -04:00
Joey Castillo
6334af0136 tweak to API nomenclature: tick happens once a second, other interrupts are periodic 2021-09-28 19:18:42 -04:00
Joey Castillo
9da9dfb7b2 rtc: support periodic ticks at intervals from 1 to 128 Hz 2021-09-28 15:13:09 -04:00
Joey Castillo
39a17c99b9 overdue refactor: compile all watch modules separately 2021-09-28 14:42:56 -04:00
Joey Castillo
152ba8aec6 simplification: return date/time in same format as clock register 2021-09-28 11:06:27 -04:00