Products > Test Equipment
SainSmart DDS120 & DDS140 USB Oscilloscope
doctormord:
Nice!
Seems like someone messed up the DDS120 page at Sigrok (Hardware Section).
merbanan:
I think I figured out how to get something like an external trigger working. Pin PE2 is connected to the 1kHz calibration pulse output. If we change the direction to an input we can use that as a trigger signal. The trigger signal then needs to set PA7 when you get a trigger condition. For some reason PA7 is connected to the RDY0 pin and the RDY0 signal enables the configured GPIF program 0. So if it would be possible to only run the GPIF program 0 once and then fetch the samples then we could realize this feature.
doctormord:
Interesting find. :)
I somehow managed to implement a "PLL-loop" into the trigger, works quite good. (Actually not at full 48M speed)
I had a look into the original Software again, they got the same triggering problems from the scope data.
https://dl.dropboxusercontent.com/u/5641160/DDS120_OpenHantek_Trigger_V2-SOURCE.zip
https://dl.dropboxusercontent.com/u/5641160/DDS120_OpenHantek_Trigger_V2.zip
CHANGES:
- Markerslidersteps 0.2 -> 0.1 of DIV - DONE
- Move Waveform by Triggerpositionslider - DONE
- Select triggervoltage in < 0.05V steps - DONE
- Make trigger more solid - DONE
mmark:
--- Quote from: merbanan on April 04, 2016, 08:05:59 pm ---Coupling support in firmware and sigrok driver is implemented now.
--- End quote ---
Nice!
I got it finally working on OSX (my Macbook is at 10.10.5) after banging my head against the table for quite a while. The problem seems to be that the USB bulk transfer size must be a power of two. So I had to change the define of FLUSH_PACKET_SIZE in src/hardware/hantek-6xxx/protocol.h from 2600 to 2048 and replace the line:
--- Code: ---
data_left += MIN_PACKET_SIZE; /* Driver does not handle small buffers. */
--- End code ---
with:
--- Code: --- uint32_t i;
for (i = 512; i < data_left; i *= 2)
;
data_left = i;
--- End code ---
in src/hardware/hantek-6xxx/api.c in static uint32_t data_amount(const struct sr_dev_inst *sdi) around line 550.
After those changes, I can read valid data with sigrok-cli and pulseview. Changing the coupling seems to work as designed!
I'll try DrMords changes later tonight or tomorrow...
M.
merbanan:
--- Quote from: mmark on April 05, 2016, 02:17:07 am ---
I got it finally working on OSX (my Macbook is at 10.10.5) after banging my head against the table for quite a while. The problem seems to be that the USB bulk transfer size must be a power of two. So I had to change the define of FLUSH_PACKET_SIZE in src/hardware/hantek-6xxx/protocol.h from 2600 to 2048 and replace the line:
--- Code: ---
data_left += MIN_PACKET_SIZE; /* Driver does not handle small buffers. */
--- End code ---
with:
--- Code: --- uint32_t i;
for (i = 512; i < data_left; i *= 2)
;
data_left = i;
--- End code ---
in src/hardware/hantek-6xxx/api.c in static uint32_t data_amount(const struct sr_dev_inst *sdi) around line 550.
After those changes, I can read valid data with sigrok-cli and pulseview. Changing the coupling seems to work as designed!
M.
--- End quote ---
Can you send your changes as a github pull request so you get the proper attribution for this fix ?
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version