Skip to content

Commit

Permalink
fix example
Browse files Browse the repository at this point in the history
  • Loading branch information
ufechner7 committed Aug 26, 2024
1 parent 20d0a08 commit 5c54fd9
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions examples/parking_4p.jl
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,18 @@ end
using Timers; tic()

using KiteControllers, KiteViewers, KiteModels, ControlPlots
se().abs_tol=0.0000006
se().rel_tol=0.000001
set = deepcopy(load_settings("system.yaml"))
set.abs_tol=0.00000006
set.rel_tol=0.0000001

kcu::KCU = KCU(se())
kcu::KCU = KCU(set)
kps4::KPS4 = KPS4(kcu)
wcs::WCSettings = WCSettings(); wcs.dt = 1/se().sample_freq
fcs::FPCSettings = FPCSettings(); fcs.dt = wcs.dt
wcs::WCSettings = WCSettings(dt = 1/set.sample_freq)
fcs::FPCSettings = FPCSettings(dt = wcs.dt)
fpps::FPPSettings = FPPSettings()
ssc::SystemStateControl = SystemStateControl(wcs, fcs, fpps)
u_d0 = 0.01 * set.depower_offset
u_d = 0.01 * set.depower
ssc::SystemStateControl = SystemStateControl(wcs, fcs, fpps; u_d0, u_d)
dt::Float64 = wcs.dt

# result of tuning, factor 0.6 to increase robustness
Expand Down Expand Up @@ -133,5 +136,4 @@ on(viewer.btn_PARKING.clicks) do c; parking(); end

play()
stop(viewer)
plot(T, rad2deg.(AZIMUTH))

plot(T, rad2deg.(AZIMUTH); xlabel="Time [s]", ylabel="Azimuth [deg]")

0 comments on commit 5c54fd9

Please sign in to comment.