USBLib_FindFreeDev (SWI &56354) — Finds a device in the unclaimed device pool
R0 | Vendor ID ( or -1 for any ) |
R1 | Product ID ( or -1 for any ) |
R2 | Class code ( or -1 for any ) |
R3 | Sub-class code ( or -1 for any ) |
R4 | Protocol code ( or -1 for any ) |
R5 | Number of matches to skip before returning match. |
This call may be used to obtain a new device block from the unclaimed device pool. The device driver may search for a specific vendor,class,sub class and product code. If more than one device is available that matches the parameters the next may be found by looping calling the SWI with increasing R5 value untill the required device is located or 0 returned.
This call may return an error if the core is not loaded.