mirror of
https://github.com/tinygo-org/tinygo.git
synced 2026-08-11 14:33:41 +00:00
machine/usb: add ability to override default VID, PID, manufacturer name, and product name
Signed-off-by: deadprogram <ron@hybridgroup.com>
This commit is contained in:
@@ -126,3 +126,21 @@ func NewSetup(data []byte) Setup {
|
||||
u.WLength = uint16(data[6]) | (uint16(data[7]) << 8)
|
||||
return u
|
||||
}
|
||||
|
||||
var (
|
||||
// VendorID aka VID is the officially assigned vendor number
|
||||
// for this USB device. Only set this if you know what you are doing,
|
||||
// since changing it can make it difficult to reflash some devices.
|
||||
VendorID uint16
|
||||
|
||||
// ProductID aka PID is the product number associated with the officially assigned
|
||||
// vendor number for this USB device. Only set this if you know what you are doing,
|
||||
// since changing it can make it difficult to reflash some devices.
|
||||
ProductID uint16
|
||||
|
||||
// Manufacturer is the manufacturer name displayed for this USB device.
|
||||
Manufacturer string
|
||||
|
||||
// Product is the product name displayed for this USB device.
|
||||
Product string
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user