Valkertown Home

Site Menu

2008-11-26-finally publishing ds1m12 python code

It's located on the mercurial repos, it's hosting two files that maybe I will have to delete since they come from the original source that I do not own. Also everything is build around Python 2.5, going to try building it for Python 2.6

It requires two downloads one from USB Instruments itself and another from a thirdparty driver

You have to use these before compiling anything of the code and also remember to update your LD_LIBRARY_PATH to poing where you placed the .so files. On my code everything is supposed to be on the same directory as the project. You will also need the .rbf files, the linux packages comes with one file that means it will use 1K buffer but the windows package comes with several files for 1K,2K,4K and 8 K buffers. These files are used to program some FPGA inside the osciloscope and set the buffer size for the capture and output, one should do some testing to find the optimum buffer for the application.

I have some bad luck now since I no longer own one of these osciloscopes and can't continue testing and improving the code.

What I found is that there's still some bugs, I think there's a buffer overun that leads to a segfault when the code it's run over continued periods of time but I don't know what is causing it exactly. My main suspects are the numpy arrays being passed to the ds1m12 libraries but I didn't have enough time with the device so I could investigate it further. I also tried almost every configuration parameter and operation mode and seems to be working, then, I was able to use the signal generator, external trigger and all the options you can set for each one of the channels even turning on/off each channel individually.

I did several testing and found that the kernel I was using had some really big impacts, 2.6.26 kernels worked fine for me, with 2.6.27 kernels it didn't work at all. So if you experience some problems with the code try downgrading or upgrading the linux kernel you are using.