Commit graph

1184 commits

Author SHA1 Message Date
David Volovskiy f6f427ca7d Daylight offsets now references the timezone of the destination; but it does cause an issue due to DST 2024-09-08 18:13:17 -04:00
Matheus Afonso Martins Moreira 337864eb54 Merge PR #454 - fix activation event
Fix issue where the calculator face's user interface display
was delayed about a quarter second due to the activation event
being a no-op.

Tested-by: David Volovskiy <devolov@gmail.com>
Reported-by: David Volovskiy <devolov@gmail.com>
Fixed-by: David Volovskiy <devolov@gmail.com>
Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/454
2024-09-08 15:33:35 -03:00
Matheus Afonso Martins Moreira 0f6f79a85a Merge PR #468 - fix github ci
Bump GitHub's checkout action to v4, fixing the continuous integration.

GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/468
2024-09-08 15:22:50 -03:00
Matheus Afonso Martins Moreira c2723ebc8e make: fix missing separator error 2024-09-08 14:22:26 -03:00
Matheus Afonso Martins Moreira ac5bf8cfce Merge PR #470 - implement automatic DST toggling
Implements logic to automatically offset daylight saving time settings
when calculating timezone offsets. This should make the DST functions
work automatically with no need for user input in most cases.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/470
2024-09-08 13:41:52 -03:00
mcguirepr89 608199268e removed break; from EVENT_ACTIVATE -- thanks @voloved 2024-09-08 11:49:01 -04:00
David Volovskiy 5ae88e438d Minot cleanup 2024-09-08 10:50:09 -04:00
Matheus Afonso Martins Moreira 5a8a49a8c7 Merge PR #268 - add daylight savings time toggle
Adds a toggle in the preferences face that allows the user
to enable or disable the daylight savings time.

Should help produce the correct results with the sunrise/sunset presets.

A proper solution would be to integrate the tzinfo database
but it's too big for the watch at the time of this writing.
Can't be done unless it can be shrunk down into a subset
the user would be interested. Even then it's a stopgap
since the database is likely to keep growing over time.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/268
2024-09-08 11:09:10 -03:00
R. Alex Barbieri 52f9500666 add blinking to DST toggle in settings page 2024-09-08 11:08:14 -03:00
Matheus Afonso Martins Moreira bfadb81e82 Merge PR #401 - add fuzzy time watch face
Displays the time in a "close enough" manner:
periods of five minutes, relative to the nearest hour.

For example:

 - 3:24 -> 25 past 3
 - 3:50 -> 10 to 4
 - 3:59 -> 4 o'clock
 - 1:35 -> 35 past 1
 - 1:50 -> 10 to 2
 - 2:00 -> 2 o'clock

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Tested-on-hardware-by: Ruben Nic <RubenSandwich@users.noreply.github.com>
Tested-on-hardware-by: KlingonJane <148595159+KlingonJane@users.noreply.github.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/401
2024-09-07 20:57:24 -03:00
Matheus Afonso Martins Moreira 6d1d4f0594 Merge PR #386 - add beep demo face
Allows the user manually trigger all 87 buzzer notes.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Tested-on-hardware-by: Wesley Black <hello@wesleyblack.ca>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/386
2024-09-07 20:53:08 -03:00
Matheus Afonso Martins Moreira 1f6153809b Merge PR #413 - add thermometer face
Measures the temperature until it stabilizes for half a minute.

This watch face is not meant to diagnose, treat, cure or prevent
any disease.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/413
2024-09-07 20:49:19 -03:00
Matheus Afonso Martins Moreira 941a6ec523 Merge PR #454 - add simple calculator watch face
Adds a simple calculator watch face to the sensor watch
capable of addition, subtraction, multiplication, division
and exponentiation.

Reviewed-by: Joey Castillo <joeycastillo@utexas.edu>
Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Tested-by: Joey Castillo <joeycastillo@utexas.edu>
Tested-on-hardware-by: mcguirepr89 <mcguirepr89@gmail.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/454
2024-09-07 20:38:08 -03:00
Matheus Afonso Martins Moreira 99586f8442 Merge PR #394 - keep LED lit while buttons held
Keeps the LED turned on while the user is interacting with the watch.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/394
2024-09-07 20:31:46 -03:00
Matheus Afonso Martins Moreira b9dbc4ed21 Merge PR #398 - add simon game watch face
Adds a watch face that allows playing the classic Simon game
with the watch's buzzer and RGB LED.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/398
2024-09-07 20:28:45 -03:00
Matheus Afonso Martins Moreira 543788b622 Merge PR #287 - add minimal clock face
Add a minimalist clock face that shows only hours and minutes.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/287
2024-09-07 20:14:26 -03:00
Matheus Afonso Martins Moreira 7de53f9fa0 Merge PR #269 - add french revolutionary time face
Adds a french revolutionary time watch face which displays the time
divided into ten hours of one hundred minutes each which are in turn
divided into one hundred seconds each.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Reviewed-by: Wesley Aptekar-Cassels <me@wesleyac.com>
Reviewed-by: Alex Maestas <git@se30.xyz>
Tested-on-hardware-by: CarpeNoctem <cryptomax@pm.me>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/269
2024-09-07 20:00:16 -03:00
Matheus Afonso Martins Moreira ce249abde6 Merge PR #259 - add higher or lower game face
Adds a watch face that implements a game where the player
must guess if the next card will be higher or lower than
the last cards that have been revealed.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Tested-on-hardware-by: Chris <chris.ellis.git.dev@gmail.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/259
2024-09-07 19:59:52 -03:00
Matheus Afonso Martins Moreira c805cdc7df Merge PR #266 - add deadline tracking watch face
Adds a timing watch face that focuses on
keeping track of specific deadlines.

Dates and times can be set on the watch face
and it will display the time remaining at ever
decreasing levels of granularity for the sake
of brevity and ease of understanding.

For example, it will display years and months if over a year is left,
months and days if less than one year is left,
days and hours if less than one month is left
and the full remaining time if less than a day is left.

It also notifies the user when a deadline has passed recently.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Tested-on-hardware-by: Konrad Rieck <konrad@mlsec.org>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/266
2024-09-07 19:59:31 -03:00
Chris 9e1e692511 Hi-lo: Additional code tweaks 2024-09-07 19:59:04 -03:00
Konrad Rieck 50cff54833 move to deadline face on alarm 2024-09-07 19:59:04 -03:00
Chris 97ad12d939 Merge pull request #1 from voloved/higher-lower-game
Hi-lo: Made cards go through a deck format.
2024-09-07 19:59:04 -03:00
Konrad Rieck e2ec468754 Alarm handled using background task.
The alarm for deadlines is now handled via a background task. Instead of a scheduled task that prevents sleep mode, the face checks in the background every minute whether an deadline is due. If this is the case, the face wakes up from sleep mode and starts a scheduled task for the remaining seconds.
2024-09-07 19:59:04 -03:00
Chris 6db0a62bbf Hi-lo: Use alternate card faces 2024-09-07 19:59:04 -03:00
David Volovskiy 93b9ca6341 Made cards go through a deck format. 2024-09-07 19:59:04 -03:00
Konrad Rieck 27ab799e85 Fixed bugs and improved watchface
- A background task is only scheduled if the alarm option is activated. If the option is enabled, an alarm sounds when the next deadline is reached. If the option is disabled, no alarm sounds and the watch can enter low energy sleep.

- Fixed tick frequency error. During running mode, the clock ticks at 1Hz. This is set in the init function `_running_init` and thus ensures that we do not run too fast when returning from the setting mode.

- Minor corrections to comments and indentations.
2024-09-07 19:59:04 -03:00
Konrad Rieck c89316b3ec removed higher frequency in first loop run. 2024-09-07 19:59:04 -03:00
Konrad Rieck fab8c94428 moved tick_freq to deadline_state_t structure. 2024-09-07 19:59:04 -03:00
Konrad Rieck c102a10165 beep on button 2024-09-07 19:59:04 -03:00
Konrad Rieck 4cb00ebb4e support for alarm 2024-09-07 19:59:04 -03:00
Konrad Rieck fea60e615c display closest deadline on activation 2024-09-07 19:59:04 -03:00
CarpeNoctem 07a2a49e72 french_revolutionary face: fix compiler warning and uninitialized date_time variable 2024-09-07 19:47:17 -03:00
Matheus Afonso Martins Moreira 852c3aad27 Merge PR #423 - add periodic table face
Adds a watch face full of useful information
about every known chemical element.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Tested-on-hardware-by: PrimmR <primmr@icloud.com>
Tested-on-hardware-by: David Volovskiy <devolov@gmail.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/423
2024-09-07 18:47:20 -03:00
Matheus Afonso Martins Moreira 02e66309d4 Merge PR #444 - implement countdown autorepeater
Adds the ability to automatically restart the timer
in the countdown watch face. This allows users to
easily time repeating events.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/444
2024-09-07 16:52:29 -03:00
Joseph Bryant ddaf3a8324 Add auto-repeat feature to Countdown watch face 2024-09-07 16:49:45 -03:00
Matheus Afonso Martins Moreira 80dc8a247f Merge PR #465 - add metal gear solid codec chime
Snake? Snake?! SNAAAAAAAAAAAAAAAAAAAAAAKE!

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/465
2024-09-07 16:43:00 -03:00
Jeremy O'Brien a79bb46d39 add metal gear solid codec tune 2024-09-07 16:41:56 -03:00
Matheus Afonso Martins Moreira 3462d51071 Merge PR #467 - add harry potter chimes
Add Harry Potter themed hourly signal chimes, short and long variants.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/467
2024-09-07 16:26:10 -03:00
mcguirepr89 48fd4ee903 slightly shorter first note 2024-09-06 10:19:17 -04:00
Alex Maestas fd526ed401 bump to the newer upload-artifact github action 2024-09-04 20:10:37 +00:00
mcguirepr89 b37be89bae adds a short and long harry potter signal 2024-09-04 11:46:33 -04:00
Matheus Afonso Martins Moreira 014ef32576 Merge PR #293 - add instant LED duration
Adds an instant LED duration preference that only keeps the LED lit
while the LIGHT button remains held down.

Matches the behavior of the original watch.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
Tested-on-hardware-by: Wesley Aptekar-Cassels <me@wesleyac.com>
Tested-on-hardware-by: 814d3 (GitHub)
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/293
2024-09-03 19:06:40 -03:00
Matheus Afonso Martins Moreira c0a72acb7c Merge PR #419 - add endless runner watch face
Adds an endless runner game face to the Sensor Watch.

The player character runs endlessly towards the right.
An endless number of obstacles speed towards him.
The player must jump over them or lose the game
when the player character runs smack into the obstacle.
Jumping requires fuel which is a limited resource
that must be managed by the player.

Features selectable difficulties and high score tracking.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/419
2024-09-03 18:50:12 -03:00
Matheus Afonso Martins Moreira cd4b285c6e Merge PR #436 - add wordle watch face
Ports the famous Wordle game to the Sensor Watch.

A random 5 letter word is chosen and the player must guess it
without exceeding the configured maximum number of attempts.
Letters guessed correctly will stay in place.
Letters present in the word but in the wrong place will blink.

Streak tracking is supported and compile time configurable.

A Python script which finds an optimal dictionary is also included
and can be used to further customize the watch face.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/436
2024-09-03 18:49:18 -03:00
Matheus Afonso Martins Moreira 4d6a9345f2 Merge PR #299 - leading zero representation
Adds a movement-wide leading zero 024h representation mode
that's toggleable in the preferences watch face.
Also adds support for the new display mode to existing faces.

I modified the logic a bit to ensure the 24h indicator remains lit
in the simple clock face even when in 024h mode. I also added support
to the more advanced clock face. In the future I will add a compile time
toggle to it as well.

Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com>
GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/299
2024-09-03 18:49:13 -03:00
David Volovskiy 118c07a3b6 Reduced struct memory per code review 2024-09-03 17:13:59 -04:00
David Volovskiy faec45ce24 Include ability to select only the best words as the first choice 2024-09-03 17:09:52 -04:00
David Volovskiy 2e46aa0e2c got rid of hardcoding of half-second zero blink 2024-09-03 16:25:05 -04:00
David Volovskiy c74ed78d72 Changed U LOSE to LOSE 2024-09-03 16:20:11 -04:00
David Volovskiy e4a5121303 bug fix on displaying time in LE mode 2024-09-03 16:20:11 -04:00