Results 1 to 5 of 5
  1. #1
    150+ Forum Groupie



    Join Date
    May 2012
    Location
    Moore OK
    Posts
    157
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    AST-300 Attitude indicator success

    Time to sleep now, but thought I'd drop this quick little progress update.

    https://www.youtube.com/watch?v=w5UiE9yJfUA

    Matt

  2. #2
    25+ Posting Member
    Join Date
    Jul 2016
    Location
    Madrid
    Posts
    35
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: AST-300 Attitude indicator success

    great Work Matt!

    Im working with mine.
    I have fit the absolute encoder with a 3d print piece and two old servo gears.
    Absolute encoder reads the move perfect.



    But I have to fine tunning the programming. There is a noticiable delay in fast roll.
    It is good enough for non aerobatic flying. But I will try to improve it!
    I know It is posible because you did it!

    Attached Images Attached Images

  3. #3
    150+ Forum Groupie



    Join Date
    May 2012
    Location
    Moore OK
    Posts
    157
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: AST-300 Attitude indicator success

    Awesome!!!! Hey it's not bad at all, you're miles ahead of a lot of other attitude indicators, including some commercial offerings.

    I see we do our flight demos at about the same altitude....hehehe.

    I could really use a 3D printer, looks like that custom part really did the trick for mounting your encoder.

    Are you driving the roll motor with 12v? I found that 12v probably wouldn't quite keep up with a super-fast roll rate (like some jet fighters, and extreme aerobatic aircraft), but it handles general-aviation planes alright, and this is all the original instrument was designed for.

    Great work, I'm really glad my project could inspire you in some way. Some of my first inspirations were from going on the internet and seeing what other folks had accomplished.

    Matt

  4. #4
    25+ Posting Member
    Join Date
    Jul 2016
    Location
    Madrid
    Posts
    35
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: AST-300 Attitude indicator success

    Hi again! thanks for your words.

    Roll: 12v dc motor. I use a l298d driver to move it. I compare the roll in simulator with my actual roll position. So I know if I have to move it clockwise, or counterclockwise. The power is calculated with the difference in their position. More difference, more voltage. Near position, little voltage. Are you doing it in the same way? I think I have to fine tunning the equation difference->voltage.
    I think there are other ways to do it. Calculating not only the difference angle, but the speed/aceleration the roll position approaches or move away the simulator actual roll. I will try.

    Pitch: 6v dc motor. I have used a servo electronics mount in the side of this motor, and connect it with actual dc motor and pot. So, I only had to go with +6v, ground and signal lines. I only have to use three of the five brushes in the shaft. I program pitch with the servo arduino library. Fast, easy and clean.

  5. #5
    150+ Forum Groupie



    Join Date
    May 2012
    Location
    Moore OK
    Posts
    157
    Contribute If you enjoy reading the
    content here, click the below
    image to support MyCockpit site.
    Click Here To Contribute To Our Site

    Re: AST-300 Attitude indicator success

    Yep, I use the L298D as well, it's a great little H-bridge for our purposes.

    I'm more or less handling roll the way you described, but as they say, the devil is in the details. It took CONSIDERABLE experimentation to arrive at an algorithm that looked good. I'm doing software PWM (in the Arduino sketch), it was important to figure out a cycle scheme that allowed precise motor movement. It might be possible to do by modifying the Atmel's PWM cycles, but then you start messing with interrupts and such, and still don't have as much control as with soft PWM. I also have an error limit, beyond which the motor just gets full power (100% duty cycle). The important thing there, of course, is to ensure that the "variable" zone (from zero error to max error) in which power is ramped up in relation to magnitude of error, ends up at full power by the time it crosses the max error threshold, otherwise you get a sudden jump in roll rate when max error is reached. Sounds simple enough, except the algorithm I originally started with that adhered to this concept did not provide enough power at very small error levels. Of course, those tiny errors are the most important if you're flying IFR. It was....fun, to say the least.

    I considered looking at roll rate in X-Plane, but it ended up not being necessary. I dealt with this a little bit when I interfaced an already-built altimeter that used a single, large, dodgy potentiometer. Rate-based positioning is a can of worms I try not to open if I can help it.

    I just used the original parts for pitch. You can certainly put a servo in there, but with the existing pitch mechanism, you basically have a servo already. Only difference is you have to run the servo code on the Arduino. Seems like your solution works just as well, though. Call me lazy, I just hate doing extra mechanical engineering if I can avoid it.

    Matt