PID was not checked properly in cdcprolific

This commit is contained in:
Kristian Sloth Lauszus 2015-04-17 22:51:41 +02:00
parent 3d5b46d055
commit 71580acca2
2 changed files with 2 additions and 2 deletions

View file

@ -66,7 +66,7 @@ uint8_t PL2303::Init(uint8_t parent, uint8_t port, bool lowspeed) {
if(rcode)
goto FailGetDevDescr;
if(udd->idVendor != PL_VID && udd->idProduct != PL_PID)
if(udd->idVendor != PL_VID && CHECK_PID(udd->idProduct))
return USB_DEV_CONFIG_ERROR_DEVICE_NOT_SUPPORTED;
// Save type of PL chip

View file

@ -20,7 +20,7 @@ e-mail : support@circuitsathome.com
#include "cdcacm.h"
#define PL_VID 0x067B
#define PL_PID ( 0x2303 || 0x0609 )
#define CHECK_PID(pid) ( pid != 0x2303 && pid != 0x0609 )
//#define PL_PID 0x0609