Commit 80dfa09
committed
Fix tone after rework of HardwareTimer
When timerTonePinDeinit() is called, it will deinitialize timer.
It is then necessary to recreate HardwareTimer object to initialize timer.
So, when NoTone() is called, without destruct, only pause the timer.
Also when frequency is null just pause the timer.1 parent 7e682d2 commit 80dfa09
1 file changed
+8
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
84 | | - | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
85 | 87 | | |
86 | 88 | | |
87 | 89 | | |
| |||
121 | 123 | | |
122 | 124 | | |
123 | 125 | | |
124 | | - | |
125 | | - | |
126 | | - | |
127 | | - | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
128 | 129 | | |
129 | 130 | | |
| 131 | + | |
| 132 | + | |
130 | 133 | | |
131 | 134 | | |
132 | 135 | | |
| |||
0 commit comments