First commit

This commit is contained in:
2026-07-30 16:19:15 -04:00
parent fbc5b3d4d3
commit d51ad8db38
12 changed files with 888 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
from machine import PWM, Pin
from utime import sleep
# From https://github.com/udacity/cd13765-deci-emb-sys-l4-term2-project.git
class Buzzer:
def __init__(self, pin):
self.pin = pin
self.buzzer = PWM(Pin(pin, Pin.OUT))
self.buzzer.duty(0)
def beep_once(self):
self.buzzer.freq(1047)
self.buzzer.duty(50)
sleep(0.2)
self.buzzer.duty(0)