We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 40a9e63 + 460e837 commit f0d83f9Copy full SHA for f0d83f9
Introducing_CircuitPlaygroundExpress/CircuitPlaygroundExpress_AudioSine.py
@@ -24,7 +24,7 @@
24
length = SAMPLERATE // FREQUENCY
25
sine_wave = array.array("H", [0] * length)
26
for i in range(length):
27
- sine_wave[i] = int(math.sin(math.pi * 2 * i / 18) * (2 ** 15) + 2 ** 15)
+ sine_wave[i] = int(math.sin(math.pi * 2 * i / length) * (2 ** 15) + 2 ** 15)
28
29
# Enable the speaker
30
speaker_enable = digitalio.DigitalInOut(board.SPEAKER_ENABLE)
0 commit comments