USB HID Communication

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

USB HID Communication

1,189 Views
berndgrossmann
Contributor II

I am using the dev_composite_hid_mouse_hid_ keyboard_bm sample and try to send and receive some data with MCXA153 controller.

What ist the best way to send some data (USB_DeviceSendRequest) and detect a sucessful transmission?

Loop?

-> Ready to send?

-> Send data

-> Wait some time to detect a sucessful transmission?

-> Next data

In posts are some NACK, busy flags proposals in some HID codes. 

Labels (2)
0 Kudos
Reply
4 Replies

942 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @berndgrossmann 

USB Stack documentation please refer to:

https://mcuxpresso.nxp.com/mcuxsdk/latest/html/middleware/usb/docs/index.html 

 

BR

Alice

0 Kudos
Reply

1,081 Views
berndgrossmann
Contributor II

Thanks, but how can I detect a ready to send?

Is there any USB Stack documentation available?

How can I detect a busy transmission?

0 Kudos
Reply

1,095 Views
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @berndgrossmann 

Yes, I think your idea is correct. First, confirm that it is ready to send. Then, send the data. Next, confirm that the data has been sent successfully. After that, proceed to the next loop.

 

BR

Alice

0 Kudos
Reply

1,038 Views
berndgrossmann
Contributor II

Thanks, but how can I detect a ready to send?

Is there any USB Stack documentation available?

How can I detect a busy transmission?

0 Kudos
Reply