File tree Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Expand file tree Collapse file tree 1 file changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -370,13 +370,9 @@ bool TonePwmConfig::startPlayback(void) {
370
370
371
371
bool TonePwmConfig::stopPlayback (bool releaseOwnership) {
372
372
373
- bool notInIsr = !isInISR ();
374
-
375
373
if (!_HwPWM->isOwner (TonePwmConfig::toneToken)) {
376
- if (notInIsr) {
377
- LOG_LV2 (" TON" , " Attempt to set noTone when not the owner of the PWM peripheral. Ignoring call...." );
378
- }
379
- return false ;
374
+ LOG_LV2 (" TON" , " Attempt to set noTone when not the owner of the PWM peripheral. Ignoring call...." );
375
+ return false ;
380
376
}
381
377
// ensure stopped and then disable
382
378
if (_is_pwm_enabled (_PWMInstance)) {
@@ -388,5 +384,6 @@ bool TonePwmConfig::stopPlayback(bool releaseOwnership) {
388
384
if (releaseOwnership) {
389
385
_HwPWM->releaseOwnership (TonePwmConfig::toneToken);
390
386
}
387
+
391
388
return true ;
392
389
}
You can’t perform that action at this time.
0 commit comments