Home
Developer Resources
QNX RTOS v4
QNX RTOS v4 Knowledge Base

QNX RTOS v4 Knowledge Base

Foundry27
Foundry27
QNX RTOS v4 project
Resources

QNX RTOS v4 Knowledge Base

Title Data corruption with the USB DDK.
Ref. No. QNX.000010320
Category(ies) USB, Development
Issue We are getting data corruption in data written to our QNX4 USB device.  The write function (called by server()) in our driver reports the number of bytes we expect (23114) in a message (write from application layer).  However, data dumps in the application and in the driver show that only 1016 bytes are being copied properly.  Is this the correct behaviour?
Solution Yes, this is correct behavior.  The iomgr lib only has a 1024 byte receive buffer.  If your app is writing more than this amount it will need to read the rest of the data.  The printer class driver that comes with the USB DDK, shows how to obtain the remaining data.