Retrieving Serial Number in MATLAB 2018a | LabJack
 

Retrieving Serial Number in MATLAB 2018a

3 posts / 0 new
Last post
mssquillante
mssquillante's picture
Retrieving Serial Number in MATLAB 2018a

I am trying to retrieve and store the serial number from my U6-PRO connected via USB in MATLAB 2018a.

It seems like this should be easy to do, but I have as yet been unsuccessful.

I would greatly appreciate any assisstance.

Thanks. 

LabJack Support
labjack support's picture
After opening the device you

After opening the device you can read the serial number with a call like:

[ljerror, serialNumber] = ljudObj.eGetSS(ljhandle, 'LJ_ioGET_CONFIG', 'LJ_chSERIAL_NUMBER', 0, 0);

These kind of configuration IOTypes and Channels are mentioned here in the U6 Datasheet:

https://labjack.com/support/datasheets/u6/high-level-driver/example-pseu...

If you need to get a list of devices connected over USB, which includes their serial number, there is the ListAll function:

https://labjack.com/support/datasheets/u6/high-level-driver/function-ref...

Use the MATLAB "methodsview(LabJack.LabJackUD.LJUD)" call to see how the ListAll function looks in MATLAB.

mssquillante
mssquillante's picture
Thank you very much, I should

Thank you very much, I should have read the manual instead of Googling randomly. :)