From d0933f0b5608a5893310f9c27d25f034da844c40 Mon Sep 17 00:00:00 2001
From: Michiel Cottaar <michiel.cottaar@ndcn.ox.ac.uk>
Date: Fri, 22 Mar 2024 13:22:51 +0000
Subject: [PATCH] Fix oversample value (should be 1 not 0)

---
 src/sequence_io/pulseq.jl | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/sequence_io/pulseq.jl b/src/sequence_io/pulseq.jl
index 6dc7276..23535ff 100644
--- a/src/sequence_io/pulseq.jl
+++ b/src/sequence_io/pulseq.jl
@@ -245,7 +245,7 @@ function build_sequence(; scanner=nothing, B0=3., TR=nothing, definitions, versi
         end
         if !iszero(block.adc)
             proc = adc[block.adc]
-            push!(events, (proc.delay, ADC(proc.num, proc.dwell * 1e-6, proc.dwell * proc.num * 1e-6 / 2, 0.)))
+            push!(events, (proc.delay, ADC(proc.num, proc.dwell * 1e-6, proc.dwell * proc.num * 1e-6 / 2, 1.)))
             block_duration = max(proc.delay * 1e-3 + proc.dwell * proc.num * 1e-6, block_duration)
         end
         grad_shapes = []
@@ -299,6 +299,7 @@ function build_sequence(; scanner=nothing, B0=3., TR=nothing, definitions, versi
                 push!(amplitudes, 0.)
             end
         end
+        @show events
         extend_grad!.(grad_shapes)
         arrs = align_in_time(grad_shapes...)
         waveform = [(t, SVector{3, Float64}(gx, gy, gz)) for (t, gx, gy, gz) in zip(arrs...)]
-- 
GitLab