From 5ca37d5ffd7c8c897b6c0739aaf84ef04b25e53d Mon Sep 17 00:00:00 2001 From: RezHackXYZ Date: Wed, 9 Jul 2025 06:36:44 -0700 Subject: [PATCH] first commit --- BOM.csv | Bin 0 -> 1800 bytes JOURNAL.md | 29 ++++ PCB.json | 368 ++++++++++++++++++++++++++++++++++++++++++ SCHEMATIC.json | 57 +++++++ firmware or whatever! | 109 +++++++++++++ 5 files changed, 563 insertions(+) create mode 100644 BOM.csv create mode 100644 JOURNAL.md create mode 100644 PCB.json create mode 100644 SCHEMATIC.json create mode 100644 firmware or whatever! diff --git a/BOM.csv b/BOM.csv new file mode 100644 index 0000000000000000000000000000000000000000..9333152c1f0308344ca60afdf66d98379fdc9e25 GIT binary patch literal 1800 zcmd6nOKuZE5Qb}qoKr+dk&ML5c>IjnAV1|qHW^}21T3r&+sS~jEsxDh9D)@~j=&LE zau^N)eAPXjH~|NcSfEyS*Q=}kuBz_u-}a;_8M!CN@?q_eu8X;^@zDG5t4;DwaF$UeeCCq3I6od&ysaN5f(8~ z6mw)SB~S(M_dq&CK7nsQD?+t>ihp;Xed(f$nDsSu+wc>RCX9^1F_q`CB{wBxW|$pN zhD7N~j`c|LoXDMP50JM&;H(|*$pcOf&=#a5z7)mdY=Pm!4}Rm-dAmNgYO}I8xiP+# zV$~b=nHG6ND#R@luga*TQbm)4E2n%h-Tw{p3H3>s7C}p1lm8L*(CQ4=@^1BKXtl!< zxg!BXyKl+rBY8_TtS_H^Mz02@TPD!Q_zF0;qQcrcCx#o+g#jmL$QQ^)aCz>UC+m7+ zr32Z8Dp0Q)xlyW0CYq*(YEvY8O*7TLg|-IQ;x*JwF56(66Mf7LwM+8pO+)J4$A6A& zx2biWT{$n^T}AtJK`6Je)lRZmP})P%Bl3VK5nLBkS|{xqM@8tgdsN!RzM5Ke@T79< z&3XM(L>+lV#H`%?_x()z^NouSwS?Top|LS)EZsa=9}KX;u!&u6ACL>B(by=}-<* z-9t1sTMcAA#zh}ocg|(}s*V1kv()1eujD0fAdxdD{gt!wY4G(!X%%g(af$nAe}$lR z`1QXCxv@j4f0)H=SNBRS_qTO^B|3cORkS|8#)#h_Ko|2T$51 debounce_delay + ): + if not game_over: + if current_turn == 1: + current_turn = 2 + last_update_time = current_monotonic_time + elif current_turn == 0: + current_turn = 2 + last_update_time = current_monotonic_time + last_press_time = current_monotonic_time + + if ( + not sw2_current_state + and last_sw2_state + and (current_monotonic_time - last_press_time) > debounce_delay + ): + if not game_over: + if current_turn == 2: + current_turn = 1 + last_update_time = current_monotonic_time + elif current_turn == 0: + current_turn = 1 + last_update_time = current_monotonic_time + last_press_time = current_monotonic_time + + last_sw1_state = sw1_current_state + last_sw2_state = sw2_current_state + + oled.fill(0) + + p1_minutes = int(player1_time // 60) + p1_seconds = int(player1_time % 60) + p1_display = "{:02d}:{:02d}".format(p1_minutes, p1_seconds) + + p2_minutes = int(player2_time // 60) + p2_seconds = int(player2_time % 60) + p2_display = "{:02d}:{:02d}".format(p2_minutes, p2_seconds) + + oled.text("P1: {}".format(p1_display), 0, 0, 1) + oled.text("P2: {}".format(p2_display), 0, 16, 1) + + if game_over: + if player1_time <= 0: + oled.text("P2 WINS!", 70, 0, 1) + elif player2_time <= 0: + oled.text("P1 WINS!", 70, 16, 1) + + oled.show()