diff --git a/README.md b/README.md index e6a7fce..f01346f 100755 --- a/README.md +++ b/README.md @@ -534,16 +534,19 @@ void loop() { ⚠️ **Note**: Software timer mode provides less accurate timing than hardware interrupts. -## Migration Guide (v1.x → v2.0) +## Migration Guide (v1.x → v2.3) ### Breaking Changes -| Old API (v1.x) | New API (v2.0+) | +| Old API (v1.x) | New API (v2.3+) | |----------------|-----------------| | `setClock96PPQNOutput()` | `setOnOutputPPQN()` | | `setClock16PPQNOutput()` | `setOnStep()` | | `setOnClockStartOutput()` | `setOnClockStart()` | | `setOnClockStopOutput()` | `setOnClockStop()` | +| `setOnSync24()` | `setOnSync(uClock.PPQN_24, onSync24)` | +| `setOnSync48()` | `setOnSync(uClock.PPQN_48, onSync48)` | +| `setOnSyncXX()` | `setOnSync(uClock.PPQN_XX, onSyncXX)` | ### Resolution Changes diff --git a/src/platforms/esp32-nofrertos.h b/src/platforms/esp32-nofrertos.h index 70d2720..23efa77 100644 --- a/src/platforms/esp32-nofrertos.h +++ b/src/platforms/esp32-nofrertos.h @@ -17,7 +17,7 @@ void ARDUINO_ISR_ATTR handlerISR(void) void initTimer(uint32_t init_clock) { - _uclockTimer = timerBegin(init_clock); + _uclockTimer = timerBegin(1000000); // attach to generic uclock ISR timerAttachInterrupt(_uclockTimer, &handlerISR); @@ -29,4 +29,4 @@ void initTimer(uint32_t init_clock) void setTimer(uint32_t us_interval) { timerAlarmWrite(_uclockTimer, us_interval, true); -} \ No newline at end of file +} diff --git a/src/platforms/esp32.h b/src/platforms/esp32.h index f0ef639..fb5b3b9 100644 --- a/src/platforms/esp32.h +++ b/src/platforms/esp32.h @@ -43,7 +43,7 @@ void initTimer(uint32_t init_clock) // create the clockTask xTaskCreate(clockTask, "clockTask", CLOCK_STACK_SIZE, NULL, 1, &taskHandle); - _uclockTimer = timerBegin(init_clock); + _uclockTimer = timerBegin(1000000); // attach to generic uclock ISR timerAttachInterrupt(_uclockTimer, &handlerISR); @@ -55,4 +55,4 @@ void initTimer(uint32_t init_clock) void setTimer(uint32_t us_interval) { timerAlarm(_uclockTimer, us_interval, true, 0); -} \ No newline at end of file +}