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.

TSW1400 automation DLL

Dear sir/madam:

Hi~ I need to use TSW1400EVM to capture data thousands of times so I use matlab automation DLL(64bit). I want extract the data (just channel one, first column) every time but not save as csv (cuz that will be much slower to go with hard drive). Save as csv is the only function in the library. I am just asking whether or not you have solution that help me do that. 

Thank you so much,

Jin

  • Hi Jin,

    Unfortunately we don't have something that you can use directly. However, you could access the binary file directly. Every ADC capture is stored into "ADC Temp.bin" in the HSDCPro root directory. The attached code should work for you, but I'm not sure how much faster it will be. "num_channels" is the total number of channels for the device (not the number of channels you want to get) and "format_pat" is taken from the "channel pattern" line in the ini file for the device. The ini files are located in the HSDCPro root directory in the "1400 Details" folder and then "ADC files" folder. The "format_pat" parameter should be an array of numbers.

    4527.load_captured_data.m

    Regards,
    Matt Guibord 

  • Just a note:

    I often find people using evaluation boards for research or production. The nature of evaluation board is to provide a means for measuring device parameters and usefulness in different applications.

    User can develop a new board with any features/functions needed in application. TI is IC not DAQ card manufacturer.

    Board uses FTDI chip so you should be able to write your own software for data capture and convert it to any format you like. Just use native OS serial routines or FTDI dll.

    PS. I assume there is no need to re-program FPGA every time board connect to PC.

    Regards,
    Maciej 

  • Dear Maciej:

    Hello~ Thank you for your note. So you are saying I should make and load my own firmware to stratix IV on the board, right? I didn't do that before. So now I have access to Quartus ii with deivice stratix IV available. How do I start? Do I need to have some kind of source codes to make my own function. 

    Thank you,

    Jin

  • I might not understand what you want to do after all. I thought you want to gather data into some other format than CSV. In that case you can write your own PC software to read data from FTDI. I see no need to modify any firmware. 

  • I need to average the data many many times. (I need to do many many captures and I want their averaging result) The only problem is speed. I can do this by csv but it is too slow. any loading.to hard drive is slow. I am guessing I need to reprogram FPGA to let the broad do multiple captures and spit out the average signal.

  • Now when you mention this - yes you need to modify firmware. Nowadays USB is often bottleneck in data acquisition applications. 

    All the best with your project,
    Maciej 

  • Thank you. It is actually the first time I use quartus,haha

  • Dear Guibord:

    So now I am trying to download a different firmware to the board. I just want to add a averaging funtion (averaging multiple captured data) to the FPGA. I just wonder can you give me any help to add this functionality to the Altera stratix iv? Is it possible to have that funtion download into the board.

    Thank you,

    Jin

  • Hi Yuning,

    Can you describe what you need to do? How many averages do you require? Are you averaging the time domain signal or the FFT?

    Regards,
    Matt Guibord 

  • Dear Matt:

    Hi~ I just want to average the time domain signal about 1000 times. So it is just like averaging the signal with 1000 time domain captures (This is to get rid of noise to see a certain pulse pattern in the waveform). I am guessing it is just adding a function module to the firmware.

    Thank you,

    Yuning Jin

  • Hi Yuning,

    1000 captures would take quite a while using the HSDCPro automation...

    Have you thought about how you're going to guarantee the pulse is in the same location every time? Otherwise, the pulse will be averaged out over time, assuming it arrives at a different place every capture.

    Regards,
    Matt Guibord 

  • Dear Matt:

    There should be no problem, I have trigger to help me with that and I have tested that.

  • Or

    Dont take the data to save in hard drive each time it captures, send it to DDR memory to further operation, that will be much faster than loading the hard drive.

    Or

    Make captures 1000 times and spit the whole thing from USB to PC so I just need to read the data once and do averaging on matlab.

  • And I am just using channel one

  • Dear Matt:

    And I am curious why each capture costs so much time?

  • Hi Yuning,

    The loading of memory from the board takes some time because there is some processing required to form samples and some of it is due to the signal processing. How much time for 1000 captures would be acceptable? I think even in the optimal case, it might take 20 minutes to take 1000 captures (without any processing done). The FPGA implementation may be the only feasible way to do it in a reasonable time.

    Regards,
    Matt Guibord