编辑代码

-- test.lua
simion.workbench_program()
adjustable electrode_voltage = 500 -- voltage cycle magnitude
adjustable switch_time = 2.0       -- change time (microseconds)
 
-- electrode voltage control

function segment.fast_adjust()
   -- start undulating at time switch_time
    if ion_time_of_flight < switch_time then
        adj_elect01 = electrode_voltage
        * cos(1 + ion_time_of_flight/10)
    else
        adj_elect01 = 0
    end
end