Difference between revisions of "SainSmart DDS140"

From sigrok
Jump to navigation Jump to search
(Add pictures for the signal generator extension module)
(→‎Hardware: Fix error made in previous change: the two AD devices in SOIC8 are completely different chips)
 
(4 intermediate revisions by the same user not shown)
Line 9: Line 9:
== Hardware ==
== Hardware ==


* '''USB''': [http://www.cypress.com/documentation/datasheets/cy7c68013a-cy7c68014a-cy7c68015a-cy7c68016a-ez-usb-fx2lp-usb Cypress CY7C68013A-100AXC] (FX2LP) ([http://www.cypress.com/file/138911/download datasheet])
* Main unit:
* '''64-kbyte I²C EEPROM''': [http://www.microchip.com/wwwproducts/Devices.aspx?dDocName=en010831 Microchip 24LC64I] ([http://ww1.microchip.com/downloads/en/DeviceDoc/21189f.pdf datasheet])
** '''USB''': [http://www.cypress.com/documentation/datasheets/cy7c68013a-cy7c68014a-cy7c68015a-cy7c68016a-ez-usb-fx2lp-usb Cypress CY7C68013A-100AXC] (FX2LP) ([http://www.cypress.com/file/138911/download datasheet])
* '''Dual 8bit, 100MSPS ADC''': [https://translate.google.com/translate?hl=en&sl=zh-CN&tl=en&u=http%3A%2F%2Fwww.mxtronics.com%2Fn107%2Fn124%2Fn181%2Fn184%2Fc692%2Fcontent.html MXTronix MXT2088] ([http://www.mxtronics.com/n107/n124/n181/n184/c692/attr/2630.pdf datasheet])
** '''64-kbyte I²C EEPROM''': [http://www.microchip.com/wwwproducts/Devices.aspx?dDocName=en010831 Microchip 24LC64I] ([http://ww1.microchip.com/downloads/en/DeviceDoc/21189f.pdf datasheet])
* 5x '''CMOS differential 4-channel analog mux/demux with logic-level conversion''': [http://www.ti.com/product/cd4052b/description Texas Instruments CD4052BM] ([http://www.ti.com/lit/gpn/cd4052b datasheet])
** '''Dual 8bit, 100MSPS ADC''': [https://translate.google.com/translate?hl=en&sl=zh-CN&tl=en&u=http%3A%2F%2Fwww.mxtronics.com%2Fn107%2Fn124%2Fn181%2Fn184%2Fc692%2Fcontent.html MXTronix MXT2088] ([http://www.mxtronics.com/n107/n124/n181/n184/c692/attr/2630.pdf datasheet])
* '''CPLD''': [https://www.altera.com/products/cpld/max-series/max-ii/overview.html Altera MAX II EPM240T100CN] ([https://www.altera.com/content/dam/altera-www/global/en_US/pdfs/literature/hb/max2/max2_mii5v1.pdf datasheet])
** 5x '''CMOS differential 4-channel analog mux/demux with logic-level conversion''': [http://www.ti.com/product/cd4052b/description Texas Instruments CD4052BM] ([http://www.ti.com/lit/gpn/cd4052b datasheet])
* '''64K x 16 CMOS anyc SRAM (8ns)''': [http://www.issi.com/US/product-asynchronous-sram.shtml ISSI IS61LV6416-8TI] ([http://www.issi.com/WW/pdf/61LV6416_L.pdf datasheet])
** '''CPLD''': [https://www.altera.com/products/cpld/max-series/max-ii/overview.html Altera MAX II EPM240T100CN] ([https://www.altera.com/content/dam/altera-www/global/en_US/pdfs/literature/hb/max2/max2_mii5v1.pdf datasheet])
* '''Dual voltage comparator''': [http://www.ti.com/product/LM393 TI LM393] ([http://www.ti.com/lit/gpn/lm393 datasheet])
** '''64K x 16 CMOS anyc SRAM (8ns)''': [http://www.issi.com/US/product-asynchronous-sram.shtml ISSI IS61LV6416-8TI] ([http://www.issi.com/WW/pdf/61LV6416_L.pdf datasheet])
* '''1A low-dropout voltage regulator (3.3V):''' [http://www.advanced-monolithic.com/products/voltreg.html#1117 Advanced Monolithic Systems AMS1117-3.3] ([http://www.advanced-monolithic.com/pdf/ds1117.pdf datasheet])
** '''Dual voltage comparator''': [http://www.ti.com/product/LM393 TI LM393] ([http://www.ti.com/lit/gpn/lm393 datasheet])
* '''Crystal''': 24MHz (for Cypres FX2)
** '''1A low-dropout voltage regulator (3.3V):''' [http://www.advanced-monolithic.com/products/voltreg.html#1117 Advanced Monolithic Systems AMS1117-3.3] ([http://www.advanced-monolithic.com/pdf/ds1117.pdf datasheet])
* '''Crystal''': 80MHz (for Altera MAX II)
** '''Crystal''': 24MHz (for Cypres FX2)
** '''Crystal''': 80MHz (for Altera MAX II)
 
* Logic analyzer:
** '''Octal translating transceiver''' [https://www.nexperia.com/products/analog-logic-ics/asynchronous-interface-logic/voltage-translators-level-shifters/series/74LVC4245A.html NXP (Nexperia) LVC4245A] ([https://assets.nexperia.com/documents/data-sheet/74LVC4245A.pdf datasheet])
 
* Signal generator:
** '''CMOS Single 8-Channel Analog Multiplexer/Demultiplexer''' [https://www.ti.com/product/CD4052B Texas Instruments CD4052B] ([https://www.ti.com/lit/ds/symlink/cd4052b.pdf datasheet])
** '''90 MHz Variable Gain Amplifier''' [https://www.analog.com/en/products/ad603.html Analog Devices AD603AR] ([https://www.analog.com/media/en/technical-documentation/data-sheets/AD603.pdf datasheet])
** '''Dual Operational Amplifier''' [https://www.analog.com/en/products/ad826.html Analag Devices AD826] ([https://www.analog.com/media/en/technical-documentation/data-sheets/AD826.pdf datasheet])


== Photos - Oscillocope (main unit) ==
== Photos - Oscillocope (main unit) ==
Line 52: Line 61:
File:Saintsmart dds140 - signal generator - PCB bottom.jpg|<small>PCB, bottom</small>
File:Saintsmart dds140 - signal generator - PCB bottom.jpg|<small>PCB, bottom</small>
File:Saintsmart dds140 - signal generator - PCB top (closeup).jpg|<small>PCB, top (closer view)</small>
File:Saintsmart dds140 - signal generator - PCB top (closeup).jpg|<small>PCB, top (closer view)</small>
</gallery>
== Photos - Logic analyzer extension ==
<gallery>
File:Saintsmart dds140 - logic analyzer - device top.jpg|<small>Device, top</small>
File:Saintsmart dds140 - logic analyzer - PCB top.jpg|<small>PCB, top</small>
File:Saintsmart dds140 - logic analyzer - PCB top (closeup).jpg|<small>PCB, top (closer view)</small>
</gallery>
</gallery>


== Protocol ==
== 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:
* https://gitlab.com/SamantazFox/dds140-reverse-engineering/-/blob/master/program/Commands_summary.rst (main)
* https://github.com/SamantazFox/dds140-reverse-engineering/blob/master/program/Commands_summary.rst (mirror)
=== 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 ==
== Firmware ==
Line 60: Line 106:
== Resources ==
== Resources ==


* [http://www.sainsmart.com/zen/documents/20-010-731/20-010-731_Hardware_Manual.pdf Vendor hardware manual]
* [https://www.sainsmart.com/products/dds140-pc-based-usb-oscilloscope-40mhz-bandwidth-200ms-s-black vendors page]
* [http://www.sainsmart.com/zen/documents/20-010-731/Sofeware_Manual.pdf Vendor software manual]
* [http://s3.amazonaws.com/s3.image.smart/download/101-10-144.rar Vendor software + manuals]
* [http://www.sainsmart.com/zen/documents/20-010-731/DDS140_V6.rar Vendor software]
* [http://www.eevblog.com/forum/testgear/sainsmart-dds120-usb-oscilloscope-(buudai-bm102)/ EEVBlog forum thread]
* [http://www.eevblog.com/forum/testgear/sainsmart-dds120-usb-oscilloscope-(buudai-bm102)/ EEVBlog forum thread]
* [https://sourceforge.net/projects/logic140/ SourceForge Logic140 project]
* [https://sourceforge.net/projects/logic140/ SourceForge Logic140 project]

Latest revision as of 21:46, 26 September 2020

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