Hello, i am in the process of porting all my stuff to ChibiOS 3.1. Most of the time, it works flawlessly.
With usb-cdc, i notice different behaviour between 2.6 and 3.1 :
2.6 : data is flushed after each chSequentialStreamWrite
3.1 : data is flushed only after the buffer of size SERIAL_USB_BUFFERS_SIZE if full
To let my application run, I have lowered SERIAL_USB_BUFFERS_SIZE, but it's not ideal,
is there any means to flush data after a chSequentialStreamWrite on usb-cdc ?
Thanks,
Alexandre
port from 2.6.x to 3.1.x : usb-cdc flush behavior
- Giovanni
- Site Admin
- Posts: 14893
- Joined: Wed May 27, 2009 8:48 am
- Has thanked: 1202 times
- Been thanked: 997 times
Re: port from 2.6.x to 3.1.x : usb-cdc flush behavior
Hi,
Look at the latest demos, there is a new function to associate to the periodic USB callback, it flushes the buffer automatically. Examples are in any usbcfg.c file.
Giovanni
Look at the latest demos, there is a new function to associate to the periodic USB callback, it flushes the buffer automatically. Examples are in any usbcfg.c file.
Giovanni