torfbolt / PyDAQFlex

Python implementation of Measurement Computing's DAQFlex command framework
15 stars 14 forks source link

USB_1608G productID #10

Open ckshobha opened 8 years ago

ckshobha commented 8 years ago

I got USB-1608G MC and while working on it I figured out the product ID for the same turns out to be 0x134 and not 0x0110. Having changed this i was able to work with opening my device and accessing it. Is this something that should be changed in devices.py or is it the standard is 0x0110?

class USB_1608G(MCCDevice): """USB-1608G card""" fpga_image = 'firmware/USB_1608G.rbf' max_counts = 0xFFFF id_product = 0x0110 -> should be 0x134

Thanks Shobha

ixjlyons commented 8 years ago

I own a USB-1608G (bought in early 2014) and the product ID is indeed 0x0110. My guess is they changed or upgraded the USB controller, but that doesn't really make sense because they use their own product/vendor IDs anyway. Maybe contact MC if you're interested in finding out why.

For now, you can just specify your own class for the device with the correct IDs (or just overwrite the id_product class attribute of USB_1608G).

As far as PyDAQFlex is concerned, I'm not sure what the best way to handle this would be. I suppose the product ID could be treated similarly to the serial number (i.e. an optional parameter in case you have more than one device plugged in).

ckshobha commented 8 years ago

As per manual this is a newer revisions of USB-1608G along with their product ID. I will cross check with them. For now I have the product ID the way you mentioned. I just thought this had to reach the group.

Solution can be to use one own class but it would be good if it can be documented or the later option that you specified have this has optional parameter with default being 0x0110. Thanks for the response and clarification.