LibrePilot Forum

Development => Firmware General => Topic started by: sky59 on December 06, 2015, 10:07:44 pm

Title: arming - save conditions
Post by: sky59 on December 06, 2015, 10:07:44 pm
hi,
i always have problem at last step when i want to save "always armed"

is anybody able to quote ALL conditions i have tu fulfill to be able to save without cross in red circle?
Title: Re: arming - save conditions
Post by: f5soh on December 06, 2015, 10:32:38 pm
After you set arming setting to  "always armed" nothing can't be saved for safety reasons.

Welcome.
Title: Re: arming - save conditions
Post by: sky59 on December 07, 2015, 07:49:24 am
After you set arming setting to  "always armed" nothing can't be saved for safety reasons.

Welcome.

this is clear, but I can not save the last "alwaysArmed", when I click SAVE only red circle with cross comes...
Title: Re: arming - save conditions
Post by: f5soh on December 07, 2015, 11:58:52 am
If you save the "Always Armed" arming setting, that true the button has a red cross.

But after reboot the "Always Armed" still here, so its saved.
Title: Re: arming - save conditions
Post by: sky59 on December 07, 2015, 10:33:45 pm
If you save the "Always Armed" arming setting, that true the button has a red cross.

But after reboot the "Always Armed" still here, so its saved.

Thanx God you are first person to have the same problem I coul find!
But sometimes I get green check OK but I do not know how i did it....
Can sw guys explain conditions to regularly save alwaysarmed?
Title: Re: arming - save conditions
Post by: f5soh on December 08, 2015, 12:26:24 am
The "Always armed" is a good bad idea, sometimes users set like this to allow arming without fixing issues in SystemHealth.

Another point to consider : by default Gyros are zeroed while arming, a good thing to avoid bad gyro initialization while connecting the battery.
Title: Re: arming - save conditions
Post by: TheOtherCliff on December 08, 2015, 03:47:20 am
Yes, "Always Armed" should really only be used with fixed wing aircraft where you might legitimately use any combination of controls combined with throttle off.
Title: Re: arming - save conditions
Post by: sky59 on December 08, 2015, 03:38:21 pm
Yes, "Always Armed" should really only be used with fixed wing aircraft where you might legitimately use any combination of controls combined with throttle off.

Yes, i speak about fixed wing. No matter if i used for arming any other combination i can not mostly save witout error.
I do not see any problem zeroing gyros while connecting battery. Cc3d boots almost 2 seconds and it is software issue that happens only after boot, am i right?
Title: Re: arming - save conditions
Post by: TheOtherCliff on December 08, 2015, 08:33:07 pm
CC3D (more accurately, using Basic Attitude Estimation, called Complementary Filter sometimes) gives you a few seconds before it starts gyro calibration at power on.  You can see that it is doing the calibration because the LED's blink fast.

For a test, make sure the quad stays very still while you plug a battery in and don't move it.  See how long it takes before the LEDs start blinking fast.  That is how long you have to get motionless after plugging the battery in.  Also there is a safety feature.  If it detects motion it starts over, but it can only detect larger motions since it is assuming the quad is motionless and any motion it sees is coming from uncalibrated gyros.  The worst that can happen is that it is moves slowly during calibration.
Title: Re: arming - save conditions
Post by: sky59 on December 10, 2015, 09:22:30 am
Thank everybody for answers, but I still do not know the answer...

For me it seems that throttle stick must be in a "special" condition (what it is?) to be able to save arming conditions correctly..

But it is not a lowest level..... it seems.....nor highest level....

any answer on this? from programming guys...
Title: Re: arming - save conditions
Post by: f5soh on December 10, 2015, 03:51:29 pm
In Throttle channel there is a neutral point set around 4% from whole range .

Throttle PWM values received are translated on -1, 0, 1 range

Bellow "neutral" point value is negative, and positive above.
To allow arming the throttle need to be close to -1
Title: Re: arming - save conditions
Post by: sky59 on December 11, 2015, 09:56:25 pm
In Throttle channel there is a neutral point set around 4% from whole range .

Throttle PWM values received are translated on -1, 0, 1 range

Bellow "neutral" point value is negative, and positive above.
To allow arming the throttle need to be close to -1

yes, for arming yes, close to -1

but to save arming condition semms not to be like this, if i have stick completely down i get red cross when click on save button
Title: Re: arming - save conditions
Post by: sky59 on December 16, 2015, 10:12:40 am
Hi programmers.... !

I do not know why my question is so difficult to answer? IS it deliberatly bot answered?

I try again:
- configuring and using for airplane CC3D
- everything OK, no alarms no errors no warnings anywhere in system
- last step is to configure arming:   I decide to use "AlwaysArmed"
                                                   TX running, throttle minimum (-1  in variables in data area in LiPi)
                                                  i click on SAVE button and redcross comes out instead of green confirmation sign

W H Y ?    what conditions must be fulfilled that arming is saved correctly?
Title: Re: arming - save conditions
Post by: f5soh on December 16, 2015, 02:19:13 pm
Are you crying ? Really ?

Whats the arming status after you saved and reboot ?
When i save Always armed here, i got a red cross and setting is saved.

Post your UAV setting file here.
Title: Re: arming - save conditions
Post by: sky59 on December 17, 2015, 02:08:08 pm
Are you crying ? Really ?

Whats the arming status after you saved and reboot ?
When i save Always armed here, i got a red cross and setting is saved.

Post your UAV setting file here.

I do not understand crying? What do you mean?

If there is a red cross there is something wrong. It should be confirmed by green sign?!

I only want to know what must be the setting around to save Arming with green sighn. Easy question?
Title: Re: arming - save conditions
Post by: f5soh on December 17, 2015, 03:27:16 pm
I do not understand crying? What do you mean?
http://allwomenstalk.com/12-netiquette-rules-to-remember/2/

Quote
If there is a red cross there is something wrong. It should be confirmed by green sign?!
I only want to know what must be the setting around to save Arming with green sighn.


The red cross maybe appears because is triggered just after the setting "Always Armed" is saved and generally it do not allow any saving while the board is armed.
But whats the goal : Is the setting "Always Armed" finally saved ? In my case the answer is yes.
I asked for some more info in previous post.

Quote
Easy question?

Well the answer for red cross is into the code (ground side), i don't know all code base... sorry for that.


Laurent
 

Title: Re: arming - save conditions
Post by: sky59 on December 17, 2015, 10:39:24 pm
OK, you mean shouting not crying :)
No, I am not writing shouting, but abbreviations are normally in capital letters

If it is a big problem the engine can convert all Capitals to Small letters and no problem :) /artificial problem/

The main point: yes i want answer from programmers about SAVE problem
Title: Re: arming - save conditions
Post by: f5soh on December 18, 2015, 12:07:55 am
Except the Red cross that cause trouble to you, please can you answer some of my previous questions ?

Quote
Whats the arming status after you saved and reboot ?
Post your UAV setting file here.


Title: Re: arming - save conditions
Post by: f5soh on December 18, 2015, 02:01:15 am
Assuming:
- when board is armed nothing can be saved and a red cross is displayed.
- the arming state can be done only if Throttle is low (<0)

Three cases:

Board is powered and receiver is active
If you save the "AlwaysArmed" setting while your throttle (RcRadio) is above neutral (positive value), the setting is saved without a red cross because the Armed status still to "Disarmed".
Since the Throttle is above zero, board still disarmed and you can still save setting you want. If you move Throttle bellow neutral (<0), the Armed status go to "Armed"

If you save the "AlwaysArmed" setting while your Throttle is bellow neutral (negative value), the AlwaysArmed setting is saved and just after the board go instantly in "Armed" state and next the status go to OBJECTPERSISTENCE_OPERATION_ERROR: Red cross is displayed.

Board is powered with USB only, or RcInput is not configured

Board is in Failsafe state because Input is wrong (no input signal) and failsafe values are applied, where the default Throttle level is -1.
Board go instantly in "Armed" state and Red cross is displayed, same as above.

Hope this helps.
 





Title: Re: arming - save conditions
Post by: sky59 on December 18, 2015, 05:21:42 pm
I do not know, I have found magic sequence how to write it without red cross, but I would like to know the WHOLE :) truth, is it deliberatly like this to prevent people from using software or any other reason? just some poeple to know......?

edit: surprisingly previous message appeared after i sent mine

YES i confirm, everythi g is like that

originally i always had throttle logically down (-1), so always red cross
now i put throttle to +0.02 and it works, i read value in data tab, so it works then
Title: Re: arming - save conditions
Post by: f5soh on December 18, 2015, 05:37:36 pm
In any case the setting you want to save is saved, red cross or not.

If you want to learn more, search for armhandler.c and systemmod.c in codebase.
Title: Re: arming - save conditions
Post by: TheOtherCliff on December 18, 2015, 07:38:06 pm
The one thing to know is that it will not let you save any setting if it is armed.  This is for safety.

If you use "always armed" you must set to "always disarmed" before making changes.  If arming is done with sticks, you must disarm first.
Title: Re: arming - save conditions
Post by: daveapplemotors on January 04, 2016, 04:40:05 pm
I avoid most of the arming / saving troubles with:  armed with throttle zero (TH switch) and "pitch aft" on my helis.

I arm and set the gyros with heli on level ground and I am not wiggling it. I can work all the controls without arm. And it is a good anti someone-else-flying-my-bird device. I dis-arm with throttle off and pitch forward. 

I believe "always disarmed" is worthless and "always armed" dangerous.  Why isn't something else default?
Title: Re: arming - save conditions
Post by: TheOtherCliff on January 04, 2016, 10:58:17 pm
A simple partial answer is that always disarmed is useless by design to make you decide and select the value that you want, including safety issues.  :)

If it had another default, someone would get hurt, blame LP, and cause bad publicity.  :(

Helis and powered fixed wing (powered gliders in particular) have good reasons to use zero throttle with full "some other control" and thus are a problem that requires an RC Tx switch to do it really right.

Helis in particular are something that needs time from a devoted dev and FTT.  I've even got a 400 size CP heli that I threaten to get out and fit with a Revo when this issue comes up, but my plate is full of stuff that I prioritize higher than that and I must realize that it will fall off the end of my list for a long time.  :)
Title: Re: arming - save conditions
Post by: cato on January 24, 2016, 11:09:14 am
Maybe time to ask people who can help developping that stuff?

I would love to do, but like cliff, my schedule is already stuffed and I am happy to do the testing, an dreaming of doing some dev work some day, again :)