use yield() only #defined ARDUINO

This commit is contained in:
wuhanstudio 2021-10-05 23:23:13 +01:00
parent 91fd7ad476
commit 79ba6cac99
1 changed files with 2 additions and 0 deletions

View File

@ -44,7 +44,9 @@ static Print *u8g2_print_for_screenshot;
void u8g2_print_callback(const char *s)
{
#ifdef ARDUINO
yield();
#endif
u8g2_print_for_screenshot->print(s);
}