jtag/drivers: give ANGIE a new PID after renumeration
Give ANGIE a new PID after renumeration to be able to distinguish the two cases (programmed and not programmed) Change-Id: I30a91d8ed2e8e261221488b98d40a027ca41da52 Signed-off-by: Ahmed BOUDJELIDA <aboudjelida@nanoxplore.com> Reviewed-on: https://review.openocd.org/c/openocd/+/7991 Tested-by: jenkins Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
This commit is contained in:
committed by
Antonio Borneo
parent
74807daeb3
commit
868700e720
@@ -31,10 +31,11 @@
|
||||
|
||||
/** USB Product ID of ANGIE device in unconfigured state (no firmware loaded
|
||||
* yet) or with its firmware. */
|
||||
#define ANGIE_PID 0x424e
|
||||
#define ANGIE_PID_2 0x4255
|
||||
#define ANGIE_PID_3 0x4355
|
||||
#define ANGIE_PID_4 0x4a55
|
||||
#define ANGIE_PID 0x414F
|
||||
#define ANGIE_PID_2 0x424e
|
||||
#define ANGIE_PID_3 0x4255
|
||||
#define ANGIE_PID_4 0x4355
|
||||
#define ANGIE_PID_5 0x4a55
|
||||
|
||||
/** Address of EZ-USB ANGIE CPU Control & Status register. This register can be
|
||||
* written by issuing a Control EP0 vendor request. */
|
||||
@@ -255,8 +256,8 @@ static struct angie *angie_handle;
|
||||
static int angie_usb_open(struct angie *device)
|
||||
{
|
||||
struct libusb_device_handle *usb_device_handle;
|
||||
const uint16_t vids[] = {ANGIE_VID, ANGIE_VID, ANGIE_VID, ANGIE_VID, 0};
|
||||
const uint16_t pids[] = {ANGIE_PID, ANGIE_PID_2, ANGIE_PID_3, ANGIE_PID_4, 0};
|
||||
const uint16_t vids[] = {ANGIE_VID, ANGIE_VID, ANGIE_VID, ANGIE_VID, ANGIE_VID, 0};
|
||||
const uint16_t pids[] = {ANGIE_PID, ANGIE_PID_2, ANGIE_PID_3, ANGIE_PID_4, ANGIE_PID_5, 0};
|
||||
|
||||
int ret = jtag_libusb_open(vids, pids, NULL, &usb_device_handle, NULL);
|
||||
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user