The nRFready desktop USB dongle is a single chip ultra miniature dongle that uses the nRF24LU1+ USB SoC solution from Nordic Semiconductor. It supports USB HID class devices and has native support for 5 remote devices. It can pair up with new remote devices at any time, but avoids cross pairing issues with other desktop systems through its proximity pairing feature.
The architecture of the USB dongle FW implementation is shown here:
USB dongle firmware organization
The component modules are generic modules in the Gazell wireless protcol stack and can/should be re-used to save time and lower risk. The application layer is only made as an example and will of course change depending on application needs.
The USB dongle application will enumerate as a composite USB device on power-up and then go to one of the two following operational states after completed enumeration:
The dongle operates in Active state when the PC is awake. In this state the Gazell Link Layer operates in Host low latency mode and the dongle is able to receive user data from the mouse, keyboard or remote control.
In Suspend state the MCU sleeps but can be woken from USB wake up or incoming data from the radio. During suspend the Gazell link layer operates in Host low power mode .
For in-depth description of Gazell modes please refer to Gazell Link Layer Overview.
The code implementation can be found in projects/nrfready/dongle/main.c
The following flowchart describes the application flow in the dongle firmware.
Dongle firmware flowchart
The USB dongle application acts upon events generated by the Gazell protocol stack and takes actions toward the USB interface based on them.
The different actions are:
Handling pairing request - a new device discovered by the Gazell protocol stack. Please see Pairing.
The user data arrives from the remote devices on a format that fits the USB end points, the dongle application are therefore limited to transferring the user data forwarded from the different remote devices by Gazell to the correct USB endpoint.
Please refer to the documentation on Mouse, Keyboard , Remote control for details on the user data format and interpretation.
If a remote device sends any "button push" commands to the USB dongle and then moves out of range, the dongle will detect this and automatically send a "release buttons" data packet to the PC. This is to prevent stuck keys or e.g. a "run away" volume control if a device gets out of range during operation.
Continue reading about the Mouse