You should not send data if the port is not opened. This overflows the buffer inside chibios and eventually halts your process, or in your case causes a "panic". It might be nice to have a flag say: "not really imporant, if the computer doesn't read this data, forget about it"...Korken wrote:* If I do not send any data at all, there is no halt.
* If I do not send data until after I have opened the port (wait with sending until a character has been received), there is no halt.
USB CDC on STM32F746 with ChibiOS 16.1
Moderator: RoccoMarco
Re: USB CDC on STM32F746 with ChibiOS 16.1
- Giovanni
- Site Admin
- Posts: 14893
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: USB CDC on STM32F746 with ChibiOS 16.1
The problem is that it should not panic, simply the writer should get MSG_RESET.
Panics cannot be a normal reaction to an externally-triggered event.
Giovanni
Panics cannot be a normal reaction to an externally-triggered event.
Giovanni
Re: USB CDC on STM32F746 with ChibiOS 16.1
In my case the important: "measure something (Debug: print measurement) do something " thread stopped. But I can imagine that e.g. a thread not processing data trhown at it would cause another thread to crash. On the other hand, IIRC there are traces that indicate that this is happing in the thread that is printing things to the USB port, right?
- Giovanni
- Site Admin
- Posts: 14893
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: USB CDC on STM32F746 with ChibiOS 16.1
Hi,
I tried using CuteCom on Mint 18 and it works using trunk code on an STM32F746-Discovery board.
I get the prompt and the OS executes the commands.
Enabling/disabling handshake and parity on CuteCom makes no difference, am I missing some fundamental step?
Giovanni
I tried using CuteCom on Mint 18 and it works using trunk code on an STM32F746-Discovery board.
I get the prompt and the OS executes the commands.
Enabling/disabling handshake and parity on CuteCom makes no difference, am I missing some fundamental step?
Giovanni
- Giovanni
- Site Admin
- Posts: 14893
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: USB CDC on STM32F746 with ChibiOS 16.1
Is it possible you have some backgroud process writing on com ports that triggers the problem?
I have a clean Mint Cinnamon install.
Giovanni
I have a clean Mint Cinnamon install.
Giovanni