diff --git a/src/interface_implementations/ballandbeam.jl b/src/interface_implementations/ballandbeam.jl index db014af26b1858f5769459e5722bf9bbe1a5dbcd..a1dc73fd966f8195d58fe87e2e55a13fd63c41af 100644 --- a/src/interface_implementations/ballandbeam.jl +++ b/src/interface_implementations/ballandbeam.jl @@ -11,6 +11,19 @@ export Beam, BeamSimulator, AbstractBeam, BallAndBeam, BallAndBeamSimulator, AbstractBeamOrBallAndBeam +# @with_kw allows specification of default values for fields. If none is given, this value must be supplied by the user. replaces many constructors that would otherwise only supply default values. +# Call constructor like Beam(bias=1.0) if you want a non-default value for bias +""" + Beam(;kwargs...) +Physical beam process + +#Arguments (fields) +- `h::Float64 = 0.01` +- `bias::Float64 = 0.0` +- `stream::LabStream = ComediStream()` +- `measure::AnalogInput10V = AnalogInput10V(0)` +- `control::AnalogOutput10V = AnalogOutput10V(1)` +""" @with_kw struct Beam <: PhysicalProcess h::Float64 = 0.01 bias::Float64 = 0.0 diff --git a/src/interface_implementations/eth_helicopter.jl b/src/interface_implementations/eth_helicopter.jl index 71bf494750efbe07f8c64383744bd7e6a133fdfa..aab34a8a4e192b700a2d6855b2c5ea6c9b411dbf 100644 --- a/src/interface_implementations/eth_helicopter.jl +++ b/src/interface_implementations/eth_helicopter.jl @@ -7,6 +7,20 @@ export ETHHelicopter, ETHHelicopterSimulator, AbstractETHHelicopter +# @with_kw allows specification of default values for fields. If none is given, this value must be supplied by the user. replaces many constructors that would otherwise only supply default values. +# Call constructor like ETHHelicopter(bias=1.0) if you want a non-default value for bias +""" + ETHHelicopter(;kwargs...) + Physical ETH helicopter process +# Arguments (fields) +- `h::Float64 = 0.05` +- `bias::Float64 = 0.0` +- `stream::LabStream = ComediStream()` +- `measure1::AnalogInput10V = AnalogInput10V(0)` +- `measure2::AnalogInput10V = AnalogInput10V(1)` +- `control1::AnalogOutput10V = AnalogOutput10V(0)` +- `control2::AnalogOutput10V = AnalogOutput10V(1)` +""" @with_kw struct ETHHelicopter <: PhysicalProcess h::Float64 = 0.05 bias::Float64 = 0.0