Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
7 years, 3 months ago.
Thread::wait does not work on my own target
I am writing a target port for pixhawk stm32f427vit6 board and add it inside the mbed-os source. The main routine is as following
main.cpp
DigitalOut myled(LED1); BufferedSerial pc(PA_0, PA_1); int main() { pc.baud(115200); while(1) { myled = !myled; pc.printf("Hello World - buf\r\n"); wait(1); } }
In debug mode, it can go to wait > wait_us > Thread::wait > svcDelay > scvHandler > svcUser > defaultHandler. Can anyone tell me where the problem is and how to fix it?? If you can, can you explain how the svcHandler involves into the delay routine of os???
i changed the configuration so that it uses the no-rtos wait method. It shows that the led toggled and serial terminal receives some bytes (not "hello\r\n"). However, the waiting time is around 8 second when it should be 1 second instead. Is it that I config the clock wrongly???
posted by Khiem Do 15 Jan 2017Yes that is most likely the issue.
posted by Erik - 19 Jan 2017