Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature: allow std::function for STM32 #105

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/TaskScheduler.h
Original file line number Diff line number Diff line change
Expand Up @@ -234,9 +234,9 @@ extern "C" {
#endif // _TASK_SLEEP_ON_IDLE_RUN


#if !defined (ARDUINO_ARCH_ESP8266) && !defined (ARDUINO_ARCH_ESP32)
#if !defined (ARDUINO_ARCH_ESP8266) && !defined (ARDUINO_ARCH_ESP32) && !defined (ARDUINO_ARCH_STM32)
#ifdef _TASK_STD_FUNCTION
#error Support for std::function only for ESP8266 or ESP32 architecture
#error Support for std::function only for ESP8266, ESP32, STM32 architecture
#undef _TASK_STD_FUNCTION
#endif // _TASK_STD_FUNCTION
#endif // ARDUINO_ARCH_ESP8266
Expand Down Expand Up @@ -1086,7 +1086,7 @@ bool Scheduler::execute() {
iCPUCycle += ( (micros() - tPassStart) - (tTaskFinish - tTaskStart) );
#endif // _TASK_TIMECRITICAL

#if defined (ARDUINO_ARCH_ESP8266) || defined (ARDUINO_ARCH_ESP32)
#if defined (ARDUINO_ARCH_ESP8266) || defined (ARDUINO_ARCH_ESP32) || defined (ARDUINO_ARCH_STM32)
yield();
#endif // ARDUINO_ARCH_ESPxx
}
Expand Down