SainSmart DDS140

From sigrok
Jump to navigation Jump to search
SainSmart DDS140

The SainSmart DDS140 is a USB-based, 2-channel oscilloscope with an analog bandwidth of 40MS/s and 200MS/s sampling rate.

Optionally, it also supports usage as signal generator or logic analyzer.

See SainSmart DDS140/Info for more details (such as lsusb -v output) about the device.

Hardware

Photos - Oscillocope (main unit)

Photos - Signal generator extension

Photos - Logic analyzer extension

Protocol

The protocol used by this device is not based on anything else. It seems to be based on a raw data exchange using a WinUSB pipe.

Sending commands

The DDS140 uses a simple set of command codes (uint8_t, from 0 to 255) that may take arguments.

The host software uses an helper DLL to send theses commands to the device. In this DLL, two functions act as a wrapper around WinUsb_ControlTransfer():

  • USBCtrlTransSimple() is used for simple commands, that does not take arguments
  • USBCtrlTrans() is used for more complex commands, i.e that takes arguments

It has to be noted that both functions can return data.


The list of currently reversed command codes is available here:


Getting the data back

the process that gets the data back from the device is not well understood yet. It seems that the helper DLL contains a wrapper function around WinUsb_ReadPipe() (for raw buffer read), plus a lot of pre-processing (via the DataPreDisposal() function) which is directly dependant of the GUI settings (graph zoom and position).

This has yet to be reversed.

Firmware

Resources