diff --git a/DCCRMT.cpp b/DCCRMT.cpp index 4c5fe4e..631cc16 100644 --- a/DCCRMT.cpp +++ b/DCCRMT.cpp @@ -21,6 +21,7 @@ #include "defines.h" #include "DIAG.h" #include "DCCRMT.h" +#include "DCCTimer.h" #include "DCCWaveform.h" // for MAX_PACKET_SIZE #include "soc/gpio_sig_map.h" @@ -67,6 +68,8 @@ RMTChannel *channelHandle[8] = { 0 }; void IRAM_ATTR interrupt(rmt_channel_t channel, void *t) { RMTChannel *tt = channelHandle[channel]; if (tt) tt->RMTinterrupt(); + if (channel == 0) + DCCTimer::updateMinimumFreeMemoryISR(0); } RMTChannel::RMTChannel(pinpair pins, bool isMain) {