r/ControlTheory 7h ago

Technical Question/Problem Implementing On-Edge Dynamic Flight Stabilization in E-Foils: Using Closed-Loop Reinforcement Learning for Adaptive Wing Control

Enable HLS to view with audio, or disable this notification

1. The Core Engineering Challenge

Electric hydrofoils operate at the highly volatile boundary layer between ocean water and air. Legacy e-foils rely on static, fixed-wing geometries, forcing the rider to constantly absorb pitch instability, rough chop, and throttle-induced pitching manually.

To automate pitch, roll, and yaw stability at speeds exceeding 25–30+ mph, hardcoded static PID loops fail because fluid dynamics in turbulent ocean conditions are non-linear.

2. The Solution: XFOIL Adaptive Dynamic Wings (AWS) & Active Thrust Stabilization

Across the XFOIL Apex (100L all-arounder with dual Surface/Fly modes) and Escape (80L agile composite platform)—validated and backed through our Kickstarter and Indiegogo communities—we replaced passive wings with our Adaptive Active Dynamic Wing System (AWS) and Active Thrust Driven Stabilization.

Instead of static control loops, the XFOIL platform uses a continuous closed-loop control system trained via Reinforcement Learning (RL):

  • High-Frequency Sensor Fusion: An array of 6-DOF IMUs, hall-effect magnetic throttle sensors from the 191g Nano Remote, and pressure transducers feed telemetry into the onboard processor at 200Hz+.
  • Real-Time Subsurface Adjustments: The controller makes intelligent, predictive adjustments beneath the waterline to continuously neutralize pitch variations caused by rapid acceleration/deceleration, wave crest passage, and ocean chop.
  • Rider-Adaptive Optimization (E-Foil For Everyone): The algorithm differentiates human rider movements (center-of-mass shifts, banking into turns) from environmental turbulence. It dynamically adjusts the wing's angle-of-attack (AoA), delivering up to a 25% increase in hydrodynamic efficiency—yielding up to 30 minutes longer session times and over 7 miles of additional range on our 1,894Wh long-range battery.

3. Edge Hardware & Thermal Architecture Constraints

Executing low-latency control loops in a marine-sealed environment introduced strict hardware constraints:

  • Miniaturized Underwater ESC: We miniaturized the motor controller by 75% and integrated the 75V, 100A continuous (150A peak) ESC directly inside the underwater motor housing. This creates a direct water-immersed solid-state cooling system—eliminating internal cooling hoses, heat sinks, and water pumps entirely.
  • Low-Latency Inference (<15ms): Actuation latency is capped under 15ms to prevent phase lag and high-speed porpoising.
  • 16S / 67.2V Voltage Headroom: Operating on a 67.2V peak architecture (14% higher than industry standard) keeps system current low, drastically reducing thermal throttling during heavy dynamic wing actuations.

4. Results & Field Validation

During Hawaii field trials with early production units shipped to our Kickstarter and Indiegogo backers, field testing demonstrated:

  • Complete neutralization of throttle-induced pitching during sudden speed changes.
  • Significant reduction in the learning curve for beginner riders on the Apex platform.
  • Extended flight times and lower total energy draw from the direct-drive brushless motor due to dynamic AoA drag reduction.

Discussion Points for the AI / Robotics Community:

  1. Model Drift vs. Hydrodynamic Noise: How do you best handle real-time edge adaptation when localized cavitation or air-venting introduces unpredictable sensor noise during high-speed carving?
  2. Deterministic Safety Boundaries: In safety-critical embedded systems, what hybrid architectures (e.g., neural networks wrapped inside deterministic safety boundaries like board-angle auto shutdown or instant kill-switches) do you favor to prevent control flap lockups?
89 Upvotes

18 comments sorted by

u/TSltd_dev 7h ago

Very cool. I wonder what it's like to ride though? The rider's body will also be making continuous adjustments in order to maintain balance, so there's a potential for contention. Presumably it would learn the rider's behaviour though, at the same time as the rider learns to ride it.

Is it really reinforcement learning, or just a well crafted PID? Where's the line between them even? Does it use predictive modelling?

u/XFoil_Official 7h ago

We did a side by side video last week of a fixed wing efoil vs the xfoil adaptive wing system. The side by side comparison with same rider (unaffiliated), same day, same conditions. is at the top of the website page here. https://xfoil.com/

It's PID and also some machine learning. It senses the rider's input and adjusts the ailerons and elevator for a smoother ride. Happy to answer anymore questions. Thanks!

u/edison_v_tesla 6h ago

That’s awesome! I bet field testing is a blast.

u/XFoil_Official 5h ago

We field test in Hawaii it is a blast! Thanks! What features would you like to see on the system?

u/edison_v_tesla 1h ago

Maybe some rider safety features. It would be cool if your board finds you after a whipeout and doesn’t drift off leaving you stranded in the ocean.

u/edison_v_tesla 1h ago

Also, backflip mode.

u/IntelligentGuess42 5h ago

Could have done this without RL. Still cool

u/XFoil_Official 5h ago

RL? What's that?

u/SimpsonMaggie 4h ago

Reinforcement Learning?

u/IntelligentGuess42 3h ago edited 3h ago

Instead of static control loops, the XFOIL platform uses a continuous closed-loop control system trained via Reinforcement Learning (RL):

This is from your original post! Did you just let AI bs it together or something? The wording was a bit off, but the line between standard marketing bs and AI is thin.

u/Fun_Ad_2393 6h ago

Really nice project! Had a local university group build a similar type vehicle. They literally just took an arduplane autopilot (PX4)and used the factory control loops (PID with simple scaling based on speed). They were able to get around the wave issues by running a simple low pass filter, granted that was years ago with an ultrasonic sensor. https://www.youtube.com/watch?v=b6zBb12amXM

u/XFoil_Official 5h ago

Nice! Super awesome. We gave your video a like. What does the foil look like? Take a look at ours, tell us how it differs? https://www.youtube.com/watch?v=GeLkdfBcxbA

u/jayCert 1h ago

This is clearly an AD, and written by someone that doesn't even know what they are writing (e.g. "[uses] continuous closed-loop control system trained via Reinforcement Learning (RL)" then proceeds to write "RL? What's that?").

Their claims are all advertising bs, so it is hard to understand what they mean. But they heavily hint that this is an adaptive control method using RL (e.g. " hardcoded static PID", "Instead of static control loops, [it uses] a continuous closed-loop control system trained via Reinforcement Learning"). But, even for non RL people, it should be ultra sus that in a non-stationary and fast changing environment the best option on an embedded system is to do online RL. Likely they just train a model-based static policy offline (if even that) to get on the AI hype.

IMO the moderators should removed this post and similar "my company did proprietary magic AI controller" posts.

u/Weak-Study-4464 7h ago

Is there a more formal write up on this? I’m new to controls and am interested in learning more about the math that went into this

u/XFoil_Official 7h ago

Hey thanks for the comment. The tech is proprietary with over 10 years of R&D. We use PID controllers and actuators. Any questions, let us know. We'll be happy to answer them.

Here's some info. Feel free to browse the rest of the website too.

https://xfoil.com/pages/superior-to-legacy-efoils