|
15 | 15 | should have been included with this software. |
16 | 16 |
|
17 | 17 | This software is not intended for medical use. |
| 18 | +
|
| 19 | + For more information on the PulseSensor methods and functions |
| 20 | + go to our Resources page |
| 21 | + https://github.com/WorldFamousElectronics/PulseSensorPlayground/blob/master/resources/PulseSensor%20Playground%20Tools.md |
18 | 22 | */ |
19 | 23 |
|
20 | 24 | /* |
@@ -147,19 +151,20 @@ if(pulseSensor.UsingHardwareTimer){ |
147 | 151 | */ |
148 | 152 | if (pulseSensor.sawNewSample()) { |
149 | 153 | /* |
150 | | - Every so often, send the latest Sample. |
| 154 | + Every 20 milliseconds, send the latest Sample. |
151 | 155 | We don't print every sample, because our baud rate |
152 | 156 | won't support that much I/O. |
153 | 157 | */ |
154 | | - if (--pulseSensor.samplesUntilReport == (byte) 0) { |
| 158 | + if ((pulseSensor.samplesUntilReport--) == 0) { |
155 | 159 | pulseSensor.samplesUntilReport = SAMPLES_PER_SERIAL_SAMPLE; |
156 | 160 | pulseSensor.outputSample(); |
157 | 161 | } |
158 | 162 | } |
159 | 163 | } |
160 | 164 | /* |
161 | 165 | If a beat has happened since we last checked, |
162 | | - write the per-beat information to Serial. |
| 166 | + write the per-beat information to Serial, formatted as CSV: |
| 167 | + BPM, IBI, PulseSensor Signal |
163 | 168 | */ |
164 | 169 | if (pulseSensor.sawStartOfBeat()) { |
165 | 170 | pulseSensor.outputBeat(); |
|
0 commit comments