Код: Выделить всё
std::this_thread::sleep_for(10ms);
Код: Выделить всё
./build/thumb/v6-m/nofp/libstdc++/src/c++11/../../../../../../../src/libstdc++-v3/src/c++11/thread.cc:228: undefined reference to `usleep'
/usr/lib/gcc/arm-none-eabi/12.2.1/../../../arm-none-eabi/bin/ld: ./build/thumb/v6-m/nofp/libstdc++/src/c++11/../../../../../../../src/libstdc++-v3/src/c++11/thread.cc:238: undefined reference to `sleep'
/usr/lib/gcc/arm-none-eabi/12.2.1/../../../arm-none-eabi/bin/ld: ./build/thumb/v6-m/nofp/libstdc++/src/c++11/../../../../../../../src/libstdc++-v3/src/c++11/thread.cc:238: undefined reference to `sleep'
collect2: error: ld returned 1 exit status
Код: Выделить всё
void usleep(uint64_t microseconds) {
sleep_us(microseconds);
}
Подробнее здесь: https://stackoverflow.com/questions/785 ... ry-pi-pico
Мобильная версия