How to communicate with firmware?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
LuTa_4642501
Level 3
Level 3
Welcome!

Whats the example where I can send a USB package to the firmware using control endpoint zero?

I need to configure some options for the firmware.

Thanks

Lucas

0 Likes
1 Solution
Rashi_Vatsa
Moderator
Moderator
Moderator
5 likes given 500 solutions authored 1000 replies posted

Hello Lucas,

USB packets can be sent through control endpoints using vendor commands.

Vendor commands are used in the bulksrcsink example of the SDK

When these vendor requests are sent from the host application, it can be handled in the way you want. .

vendor1.PNG

In bulksrcsink example there is one vendor request which passes current event log index to host.

The below vendor request is 0x81 with bytes to transfer (wLength ) as 2 bytes

vendor.PNG

When vendor command is sent from host application. I am sending it from control center

control_center.PNG

The direction of data is IN here (data is transferred from FX3 to host).

Similarly you can define vendor commands and then handle them accordingly

Other examples in SDK which have vendor commands are i2cregmode, i2cdmamode. Please refer to readme.txt file of these firmware examples to understand better.

Please let me know if any queries on this

Regards,

Rashi

Regards,
Rashi

View solution in original post

0 Likes
2 Replies
Rashi_Vatsa
Moderator
Moderator
Moderator
5 likes given 500 solutions authored 1000 replies posted

Hello Lucas,

USB packets can be sent through control endpoints using vendor commands.

Vendor commands are used in the bulksrcsink example of the SDK

When these vendor requests are sent from the host application, it can be handled in the way you want. .

vendor1.PNG

In bulksrcsink example there is one vendor request which passes current event log index to host.

The below vendor request is 0x81 with bytes to transfer (wLength ) as 2 bytes

vendor.PNG

When vendor command is sent from host application. I am sending it from control center

control_center.PNG

The direction of data is IN here (data is transferred from FX3 to host).

Similarly you can define vendor commands and then handle them accordingly

Other examples in SDK which have vendor commands are i2cregmode, i2cdmamode. Please refer to readme.txt file of these firmware examples to understand better.

Please let me know if any queries on this

Regards,

Rashi

Regards,
Rashi
0 Likes

Great thanks!

0 Likes