This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TSW1400EVM: automation

Part Number: TSW1400EVM
Other Parts Discussed in Thread: ADS42LB49

Dear sir/madam:

I use TSW1400EVM for automation test. TSW1400EVM worked well  with GUI. When I tried to connect board with python automation DLL(64bit), It showed error 7004 which meant "Board handle not found".

I got the board number from GUI "K1316383-TSW1400", 1316383 was shown on board sticker. I set board number as "K1316383-TSW1400", "K1316383","1316383-TSW1400","1316383". Nothing worked.

My script is as below:

from ctypes import *
import os

'''******************************** Loading the HSDCPro Automation DLL ****************************************************'''


dll_path = "C:\\Program Files (x86)\\Texas Instruments\\High Speed Data Converter Pro\\HSDCPro Automation DLL\\64Bit DLL\\HSDCProAutomation_64Bit.dll"
HSDC_Pro = cdll.LoadLibrary(dll_path)

'''*************************************************************************************************************************'''
'''***************************************ADC Configuration Settings********************************************************'''
'''*************************************************************************************************************************'''

Boardsno = "K1316383-TSW1400" #Serial Number of board to be connected. Eg: "TIVHIV9Z" or "TIVHIV9Z-TSW1400"
Devicename = "ADS42LB49" #ADC device to be selected(should be same as what appears in the HSDC Pro GUI selection drop down box.

Datarate = 50000000 #ADC output Data Rate

#File Import Settings. Please provide file path with the respective extension
ImportCSVFilePathWithName = "C:/HSDCPro Data/Testdata.csv"
ImportBinFilePathWithName = "C:/HSDCPro Data/TestBinary.bin"
NoofBits = 16
NoofChannels = 4

#File Save Settings. Please provide file path with the respective extension
SaveCSVFilePathWithName = "C:/HSDCPro Data/ADCdata.csv"
SaveBinFilePathWithName = "C:/HSDCPro Data/ADCdata.bin"

#Additional Frequency Settings
Enable = 1 #1-Enable Additional device parameters 0-Disable Additional device parameters
ADCOutputDatarate = 2949120000
InputTargetFrequency = 2205000000
SecondInputTargetFrequency = 2210000000
NCO = -2500000000
Decimation = 4

#Getting the Single Tone Parameters
#Unit settings for Single Tone
SingleToneUnit = 1 #0-dBc 1-dBfs 2-Hz
#The parameters whose values are needed must be sent separated by ";" as a string
SingleToneParametersIn = "SNR;SFDR;THD;SINAD;ENOB;Fund.;Next Spur;HD2;HD3;HD4;HD5;NSD/Hz"

#Getting the Two Tone Parameters
#Unit and Nyquist settings for Two Tone
TwoToneUnit = 1 #0-dBfs 1-Hz
Nyquist = 1 #0-Nyquist1 1-Nyquist2 2-Both
#The parameters whose values are needed must be sent separated by ";" as a string
TwoToneParametersIn = "F1;F2;2F1+F2;2F2+F1;2F1-F2;2F2-F1;3F2-2F1;3F1-2F2;F1+F2;F1-F2;3F1;3F2;2F1+2F2"

TimeoutinMs = 30000

'''*************************************************************************************************************************'''
'''**************************** The actual call to the function contained in the dll ***************************************'''
'''*************************************************************************************************************************'''

print "Connecting to board : " + Boardsno
Err_Status = HSDC_Pro.Connect_Board(Boardsno,TimeoutinMs)
print "Error Status = " + str(Err_Status)

Is there any solution?

Thank you

Andy

  • Hi Andy,

    Have you tried replacing the "1" with a capitol letter "I"? I have seen this cause issues before. Additionally, please double check the FTDI device handle in the opening dialog box when launching HSDC Pro.

    Best Regards,

    Dan

  • Hi Dan,

    Thanks for your reply. I checked board no again, there is no "I" in it.

    Is it because of the 64bit DLL path?

    dll_path = "C:\\Program Files (x86)\\Texas Instruments\\High Speed Data Converter Pro\\HSDCPro Automation DLL\\64Bit DLL\\HSDCProAutomation_64Bit.dll"

    Do I have to move it to:

    dll_path = "C:\\Program Files\\Texas Instruments\\High Speed Data Converter Pro\\HSDCPro Automation DLL\\64Bit DLL\\HSDCProAutomation_64Bit.dll"

    Thank you

    Andy