From c99d1d2be8f48e6c40db8a29bfce2b9be4fe886f Mon Sep 17 00:00:00 2001 From: Kristin Galvin Date: Sun, 19 Jan 2020 17:12:21 -0800 Subject: [PATCH] audio test --- apps/stetho/stetho.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/apps/stetho/stetho.js b/apps/stetho/stetho.js index c3c9ccff9..ec7d4542d 100644 --- a/apps/stetho/stetho.js +++ b/apps/stetho/stetho.js @@ -13,12 +13,13 @@ function freq(f) { if (f===0) digitalWrite(SPEAKER_PIN, 0); else analogWrite(SPEAKER_PIN, 0.5, {freq: f}); } - freq(1000); + + + +function readHRM() { + freq(1000); freq(1500); freq(0); - - -function readHRM() { var a = analogRead(D29); var h = getTime(); min=Math.min(min*0.97+a*0.03,a);