Home Forums Everything about everything else Triflight 0.7 Beta 2

Viewing 15 posts - 91 through 105 (of 155 total)
  • Author
    Posts
  • #38952
    Cshep70
    Participant

    Confirmed?: Static Tail Tune in .7B2 no worky for 3-wire non feedback servo

    I redownloaded the hex, reflashed, and reran the tail tune in B2. It completes up to the timing step. When you pull down on the right stick the servo throws left and everything hangs.

    Arming the ‘copter after this makes an AWFUL ruckus from the tail motor and it gets VERY HOT.

    I flashed back to .5 in Cleanflight and my belived Mini is back!

    lauka, Litterbug, (David): THANK YOU.

    #38964
    hsamuels
    Participant

    I’m trying to get 3D mode working on a tricopter – mini tri, but with long arms cut to 200m, and David’s F3Fc board. Triflight 0.7 Beta 2. I’ve made a couple of 3D quads, so I’m confident the ESCs and triflight settings are correct. It seems that the servo doesn’t change directions when the motors are reversed (below mid-throttle).

    Normal operation (slightly above mid-throttle, motors turning normally): Looking at the tricopter from the top, with the tail pointing at me, if I give it right rudder, the servo tilts towards the left, which is correct. And if I rotate the tricopter manually to the right (clockwise), the servo tilts toward the right, to correct the ‘error’, which is also correct.

    Inverted flight (slightly below mid-throttle, motors turning reverse): The servo does exactly the same thing as above. I believe the servo should be reversed when the motors are reversed.

    It seems that this has been considered. This code is from servo.c:

    // Reverse yaw servo when inverted in 3D mode
    if (feature(FEATURE_3D) && (rcData[THROTTLE] < rxConfig->midrc)) {
    input[INPUT_STABILIZED_YAW] *= -1;

    I don’t know enough about the code to be able to tell if this should do the right thing. But it appears not to work on my tricopter. I can post a video if the explanation isn’t clear.

    #38965
    lauka
    Participant

    3d mode won’t work on Triflight. The CW rotation on the tail motor hasn’t been implemented. I can give you pointers if you’re up to it.

    #38970
    hsamuels
    Participant

    Well, I’m familiar with C, and can probably figure out the github stuff.

    The tail motor is reversing, but the servo isn’t flipping sign when the tail motor reverses.

    If it isn’t too much trouble, I would appreciate some pointers so I can look at the code and see how big an effort it might be. Does 3D mode work in Betaflight?

    #38974
    lauka
    Participant

    The yaw output gain per a servo angle is precalculated to array yawOutputGainCurve[]. The formula is -k*cos(a)-sin(a). Where k is the thrust factor, a is servo angle (90 degrees being center), cos(a) is the thrust gain and sin(a) is the torque gain.

    When the motor direction is changed to CW, the sign of the sin(a) changes. Easy fix would be to recalculate the array, but it would take too much time to do on every motor rotation direction change. I think easiest way would be to take the torque part (sin(a)) out of the precalculated array and calculate it and add it separately every time a value is read from the array. This will create some CPU overhead, but might be doable. I would create a function that calculates the output gain on a given angle to simplify the implementation.

    On faster processors (F4 or F7) we could get rid of the precalculated array and just calculate it every time. There might be a way to solve the formula for the a without the binary search. Could look into it.

    #38975
    lauka
    Participant

    Actually there is a solve formula for a: https://www.wolframalpha.com/input/?i=solve+y%3D-k*cos(a)-sin(a)+for+a

    Could test implementing that, it might increase the CPU overhead a bit, but it’s much more neater and takes less memory.

    #38977
    hsamuels
    Participant

    If I understand correctly, reversing the motor direction means that a is -90 at center, correct? The cos term doesn’t care about the polarity of a.

    Where is the array yawOutputGainCurve[] located?

    I understand splitting the array into two, and adding or subtracting them every cycle depending on motor polarity. The solved function is conceptually cleaner, but the arctan may take some extra cpu cycles.

    #39175
    ianlh
    Participant

    Hi, I am trying to get the AUX2 working with the version 0.7, no matter what I try it wont recognize the command. It works in betaflight. I would like to assign the AUX2 to Angle mode.

    #39381
    dubadub425
    Participant

    Hey guys, I wanna build a baby with the Omnibus F4 PRO v3. I’ve found in the wiki where to solder servo and motor control wires (5+123), but what about the servo feedback wire. RSSI pin? And will I need any code for the CLI?
    Thanks!

    #39388
    biggestRCEfan
    Participant

    @lauka, a few questions for you regarding triflight 0.7:
    1. How mature is it to be used on the V4 (big tri stock electronics and motors)? I am still running 0.5 on Cleanflight and want to change to Betaflight but don’t want to do it if I am going to struggle to get it working properly (PIDs, servo feedback pin and other troubles I have been reading about).

    #39406
    lauka
    Participant

    @biggestRCEfan: I’d say the 0.7 is stable enough and you should have no problem getting it to work if you’re running the F3FC. The PID gains is something I haven’t worked on for V4, you would need to ask someone that has tuned it for the bigger tri.

    #39702
    Gruncle
    Participant

    Everytime I throttle down the tricopter yaws to the left. How can I correct that? Other than that, the tricopter flies good.

    Thanks in advance!

    #39827
    trent
    Participant

    Hi guys,
    Hoping you can help me out. I have a few tricopters, all running tri flight 0.5 on Naze32. I just built another and damaged the solder tab on output 1, so can’t connect the servo as normal.
    So I installed tri flight 0.7 in betaflight to allow me to do my own resource mapping.

    I’m running the stock hex file except:
    resource servo 1 a08
    resource servo 2 a11
    Where I swapped so servo 2 is a08. I have my servo connected to output 2 instead of output 1.

    Power up and servo works fine, can do tail tune on the bench. The servo needs to be reversed so I enter
    smix reverse 5 2

    Tail tune on the bench works fine.
    Now when I arm the servo goes crazy, it oscillates wildly about 30 degrees off centre back and forwards.

    I’m running virtual tail with 3 wire servo. Why does it go crazy when I reverse the servo?

    #39844
    skylimiter1
    Participant

    Wondering if someone could help me out. I haven’t been able to get my tricopter working for at least a year. Nobody seems to be interested anymore in them , or to help me out. I have an sp racing f3 with a HSG-5083mg digital servo. I’m thinking triflight is my last hope. Everything seems to work except the servo. I got the tail tune to work to the left, but thats it, it doesn’t respond after that. Running .7 beta2. Please help me anyone! Thanks

    #39848
    Dave Mak
    Participant

    I’ve got tf 0.7b2 installed on the large V4ish tricopter I have (RCESPF3, with feedback servo mod but with older, non-CF base plates, etc.), and did an intial flight with the following PID’s but haven’t really tuned it nor had a chance to fly it alot, but it’s pretty stable and responsive enough LOS:

    set p_pitch = 34
    set i_pitch = 40
    set d_pitch = 20
    set p_roll = 24
    set i_roll = 40
    set d_roll = 27
    set p_yaw = 84
    set i_yaw = 40
    set d_yaw = 50

Viewing 15 posts - 91 through 105 (of 155 total)
  • The forum ‘Everything about everything else’ is closed to new topics and replies.