File tree Expand file tree Collapse file tree 1 file changed +3
-4
lines changed
ports/raspberrypi/common-hal/audiopwmio Expand file tree Collapse file tree 1 file changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -102,6 +102,7 @@ void common_hal_audiopwmio_pwmaudioout_construct(audiopwmio_pwmaudioout_obj_t *s
102
102
}
103
103
104
104
audio_dma_init (& self -> dma );
105
+ self -> pacing_timer = NUM_DMA_TIMERS ;
105
106
106
107
self -> quiescent_value = quiescent_value ;
107
108
}
@@ -127,10 +128,8 @@ void common_hal_audiopwmio_pwmaudioout_deinit(audiopwmio_pwmaudioout_obj_t *self
127
128
128
129
void common_hal_audiopwmio_pwmaudioout_play (audiopwmio_pwmaudioout_obj_t * self , mp_obj_t sample , bool loop ) {
129
130
130
- if (self -> dma .channel [0 ] < NUM_DMA_CHANNELS ) {
131
- if (common_hal_audiopwmio_pwmaudioout_get_playing (self )) {
132
- common_hal_audiopwmio_pwmaudioout_stop (self );
133
- }
131
+ if (common_hal_audiopwmio_pwmaudioout_get_playing (self )) {
132
+ common_hal_audiopwmio_pwmaudioout_stop (self );
134
133
}
135
134
136
135
// TODO: Share pacing timers based on frequency.
You can’t perform that action at this time.
0 commit comments