todbot / circuitpython-tricks

Some CircuitPython tricks, mostly reminders to myself
MIT License
577 stars 65 forks source link

Audio: Making Simple tones #4

Closed gmeader closed 1 year ago

gmeader commented 2 years ago

Here's how to make simple tones with Circuit Python

import board import simpleio

f = 440 # frequency in hz d = 0.25 # duration in seconds simpleio.tone(board.A0, f, d)

todbot commented 1 year ago

thanks!