mirror of https://github.com/m-labs/artiq.git
manual: update example to use DMA handle API
This commit is contained in:
parent
e8f7f8ef9c
commit
badbd72beb
|
@ -228,8 +228,11 @@ Try this: ::
|
||||||
def run(self):
|
def run(self):
|
||||||
self.core.reset()
|
self.core.reset()
|
||||||
self.record()
|
self.record()
|
||||||
|
# prefetch the address of the DMA buffer
|
||||||
|
# for faster playback trigger
|
||||||
|
pulses_handle = self.core_dma.get_handle("pulses")
|
||||||
self.core.break_realtime()
|
self.core.break_realtime()
|
||||||
while True:
|
while True:
|
||||||
# execute RTIO operations in the DMA buffer
|
# execute RTIO operations in the DMA buffer
|
||||||
# each replay advances the timeline by 50*(100+100) ns
|
# each playback advances the timeline by 50*(100+100) ns
|
||||||
self.core_dma.replay("pulses")
|
self.core_dma.playback_handle(pulses_handle)
|
||||||
|
|
Loading…
Reference in New Issue