Hydrofoil Flight Control Stability Using Arduino MPU6050 & Ultrasonic

Discussion in 'Stability' started by zstine, Jan 31, 2021.

  1. zstine
    Joined: Sep 2013
    Posts: 74
    Likes: 9, Points: 8, Legacy Rep: 10
    Location: New Jersey

    zstine Junior Member

    Hi, I've developed (developing) an Arduino based PID flight control software using MPR6050 accelerometers and an ultrasonic sensor. The foil configuration is a canard setup with an 80/20 balance. The boat is ~25ft LOA and 1100lb design weight. I'm making a 1/4 scale model to test the flight software in a creek, but my concern is the validity of such testing. The scale model will have much higher natural frequencies in pitch and roll. I believe PeriodModel = PeriodShip x scale^0.5 or in my case, the period will be 12.5% of the full size boat. But the model will also react quicker to control surface inputs. So do those 2 balance out? Are the PID gains for the model valid in any way for the full scale boat? Anyone with experience building hydrofoil active control software that can help?
    extra info: This is a bi-ped, T-foil design in a canard configuration. The main foil (slight anhedral to increase roll authority w/ aprox 6ft strut, 6ft span, 9in chord, 6412, take-off ~7.5knt, kite propelled = low overturning moment) has 30% flaperons that can be moved together to change lift and moved independently for roll control. There is a user input heel angle to allow the boat to heel into the wind to reduce side loads on the strut. Main foil lift changes are expected to be significantly damped (it is ride height trim or really pitch trim) as the canard foil will provide height control independently. Ultrasonic sensors will be mounted on a short bow sprit for the canard AOA control and mounted on the transom for main foil lift trim. MPU6050 provides roll angle to control surfaces on main foil and since roll is being determined from accelerometers, it should lean into a turn like a bike. Yaw is manual via rotating the whole canard T-foil and strut. I will add GPS speed to the full scale since I expect the control surface movement needs to be reduced as speed increases and I will also have a zero flap angle when below take-off speed to reduce drag hump. I also plan to use pairs of ultrasonic sensors to compare and ignore bad data as it seems sketchy. The MPU6050 data is currently averaged over 15 updates and seems stable.
    Thanks for your help.
     
  2. Kayakmarathon
    Joined: Sep 2014
    Posts: 43
    Likes: 14, Points: 8, Legacy Rep: 10
    Location: NewEngland

    Kayakmarathon Junior Member

    The fundamental problem of this control system is to hold the hull at a commanded angles of pitch and roll when above a certain speed and in waves. There is much more than meets the eye for this project. The pitch, roll, and yaw are actually coupled. As soon as the boat is heeled, the pitch accelerometer measures less pitching and begins to detect yaw. The pitch frame of reference needs to change with roll. The PID gains for the model and full size boat will be different. If you can tune the gains for the model, then you may or may not be able to tune them for the full size boat. GPS is an obvious choice, but is not the best. Foils need velocity relative to the medium in which they are submerged, not relative to land or satellites stationary relative to land. GPS will work in lakes the best, and oceans the worst. The next thing to consider is the sea condition the boat is anticipated to be operated. Waves have amplitude, frequency and length. The perceived frequency is greater when heading into waves. The sampling frequency of the accelerometers need to take into account the natural frequency of the boat, actuators, and waves. Sampling 10x the highest frequency of everything mentioned is a minimum. If the actuators respond too slowly (lag), the hydrofoil could attempt to plunge the bow into the waves instead of over them. If the sample frequency is too slow, then the bow will pop out of the water more than it needs to.
     
  3. philSweet
    Joined: May 2008
    Posts: 2,429
    Likes: 250, Points: 83, Legacy Rep: 1082
    Location: Beaufort, SC and H'ville, NC

    philSweet Senior Member

    So far, so good, but there is usually a problem with adequate control power to slew the control surfaces at rates commanded by the controller. So this has to be accounted for early on in the control design. The entire control scheme can be nondimentionalized for boat size. The model then has to have the correct mass and moments for the geosim. Propulsion moments usually have to be tinkered with as well, since the friction drag scales differently than the Froude scaling of the foil systems.

    Canard systems will be least pitch stable during transition to foiling, where you usually want a big stability cushion. I think you will need coordinated control of the canard to retain stability.

    Are you modelling the foiling arrangement with AVL?
     
  4. zstine
    Joined: Sep 2013
    Posts: 74
    Likes: 9, Points: 8, Legacy Rep: 10
    Location: New Jersey

    zstine Junior Member

    Thanks for this reply. I understand your point regarding the issue of moving the full scale flaps as quick as my little model servos will. Obviously mechanical advantage (gearing) can change the speed of the motor I use for actuation, but I'm not sure what my loads will be to move the flaps and those two figures go hand in hand. I'll have to look into that...
    I've used scaling ratios, so I think I have the correct mass. for example, the mass is 1/64th of full size for a 1/4 scale model (17.2lbs is pretty light for a model of an 1100lb boat! haha). So if I'm understanding your statement "the control scheme is nondimentionalized", then you mean the way the model reacts should be the same as the full scale, in theory anyway. That's great news. I didn't want to build a proof of concept that didn't prove anything! As far as drag goes, I will measure the tow forces of the model flying in the creek with a digital fish scale. I haven't learned how drag scales yet, but the model is too small to expect perfectly scaled foils, so I don't think drag data will be very useful beyond a 'ballpark' figure.
    Well, I just learned about AVL.. Thanks again! Something to learn. So far I've just done some hand calcs and used 'foil' to get coefficients for lift and drag. no dynamic modeling at this point. I guess I prefer the scale models over computer models, but they both have their place.
    Thanks for the advice on coordinated control. All the sensor processing is happeneing in the same Arduino, so it's only a software change to coordinate main wing flap angle and canard AOA. figuring out how they need to relate is another matter. That's something to play with on the model I guess.
     

  5. zstine
    Joined: Sep 2013
    Posts: 74
    Likes: 9, Points: 8, Legacy Rep: 10
    Location: New Jersey

    zstine Junior Member

    I have a working AVL model now. As a mechanical Eng some of this aero stuff is over my head, but I'm learning. I've attached a few screen shots of the Trefftz plots solving some pitch stability scenarios. I'm playing around with banked turn stability now. But I'm not really sure how to use this tool to make changes in my stability software or wing design.. I have some guesses.. I do see some weird things particularly with negative Alpha numbers... especially for a take-off trim set to a CL of 1.15... Anyway, thanks for any Advice!
     

    Attached Files:

Loading...
Forum posts represent the experience, opinion, and view of individual users. Boat Design Net does not necessarily endorse nor share the view of each individual post.
When making potentially dangerous or financial decisions, always employ and consult appropriate professionals. Your circumstances or experience may be different.