Binary Transfer with DMA on 125-14

Applications, development tools, FPGA, C, WEB
Post Reply
chris@ner.com
Posts: 7
Joined: Thu Apr 18, 2024 4:34 pm

Binary Transfer with DMA on 125-14

Post by chris@ner.com » Tue Apr 30, 2024 6:52 pm

System Version: 2.00-35 (aff683518)
Board ID: 2
Board Name: STEMlab 125-14 v1.1

My current system is using DMA to acquire Ch 1, using an external (DIO_0) Trigger via the SCPI server.

All is well, and I am very happy with the results so far.

I have sped up acquisition considerable by switching from VOLT units to RAW (in my case, a decrease of about 0.5 seconds for 65k samples at 125 MHz).

Code: Select all

# UNITS selection may be VOLTS or RAW.  RAW takes 1/2 the time, but numbers come back as COUNTS.
        # self.com.tx_txt('ACQ:AXI:DATA:UNITS VOLTS')
        self.com.tx_txt('ACQ:AXI:DATA:UNITS RAW')
I am wondering if there is also the possibility of making the cycle time faster by implementing Binary transfers like one can with the normal acquisition mode.

Normal Acquisition Mode from the python EXAMPLES:
https://redpitaya.readthedocs.io/en/lat ... ode-python

Code: Select all

rp_s.tx_txt('ACQ:DATA:FORMAT BIN')
rp_s.tx_txt('ACQ:DATA:Units RAW')
...
rp_s.tx_txt('ACQ:SOUR1:DATA?')
buff_byte = rp_s.rx_arb()
What I'm doing now with AXI / DMA:

Code: Select all

# *** Read the data in ***
        # Get write pointer at trigger location
        pos_a = int(self.com.txrx_txt('ACQ:AXI:SOUR1:Trig:Pos?'))

        # There doesn't seem to be a BINARY ("arb") transfer mode when using DMA.  
        # Perhaps that would be even faster?
        self.com.tx_txt(f"ACQ:AXI:SOUR1:DATA:Start:N? {pos_a},{self.ts.num_samples}")
When I do a "SYSTem:Help?" request, "ACQ:AXI:DATA:Units" is listed, but not a similar ACQ:AXI:DATA:FORMAT command.

So, is there an equivalent binary transfer strategy for AXI / DMA acquisitions?

I'll be really happy to nail this down, if possible, and be ready to move on...

Many thanks,
Chris

33dnp
Posts: 11
Joined: Fri Jul 17, 2020 6:00 am

Re: Binary Transfer with DMA on 125-14

Post by 33dnp » Thu May 02, 2024 3:38 am

Hi.
Command rp_s.tx_txt('ACQ:DATA:FORMAT BIN') also suitable for AXI mode. This is a common command.
If in AXI mode the data is not transmitted in binary format, then this is most likely my fault.

chris@ner.com
Posts: 7
Joined: Thu Apr 18, 2024 4:34 pm

Re: Binary Transfer with DMA on 125-14

Post by chris@ner.com » Thu May 02, 2024 6:38 pm

@33dnp: Excellent. Works as expected, though it seems any speedup is lost in my other transactions. However, 'ACQ:DATA:FORMAT BIN' seems to function fine with AXI mode.

Thanks for the help.
Chris

Post Reply
jadalnie klasyczne ekskluzywne meble wypoczynkowe do salonu ekskluzywne meble tapicerowane ekskluzywne meble do sypialni ekskluzywne meble włoskie

Who is online

Users browsing this forum: No registered users and 5 guests