Conditional Statement

All questions related to the configuration tool and groundstation

Moderator: lukasz

Conditional Statement

Postby spinner » Sat Aug 17, 2013 3:03 pm

Hi,

I've had a look through and these seem to be the conditional operators available.

<opcode>UNTIL_NE</opcode>
<opcode>UNTIL_GR</opcode>
<opcode>UNTIL_EQ</opcode>
<opcode>UNTIL_SM</opcode>

<opcode>IF_NE</opcode>
<opcode>IF_GR</opcode>
<opcode>IF_EQ</opcode>
<opcode>IF_SM</opcode>

What I'd like to have is a block that contains a CIRCLE at a certain height and then when the aircraft has gone down to that height and when it's at a certain bearing go into a flare so as the flare direction is into the wind.

I've tried putting in two conditional statements one after another, the next thing I could try is putting in two CIRCLE statements with the two different conditionals after each separate one. What I'm really looking for is some boolean operator so as both of these conditions could be put into one UNTIL conditional statement.

Thanks,
Tim.
spinner
 
Posts: 19
Joined: Sat Jul 06, 2013 8:24 pm

Re: Conditional Statement

Postby Tom » Sun Aug 18, 2013 2:57 pm

Hi Tim,

I assume you are refering to auto-landing?
For this I introduced the variable "Absolute altitude & heading error [m * °]".
To be used as:
CIRCLE
UNTIL(Absolute altitude & heading error [m*°] < 15)
FLARE_TO


This will circle until the altitude error is "OK" and the directions towards the next waypoint is also "OK".
In the case the altitude error and heading error should be below 15. So if the altitude is still 10m too high, and the heading is only 4 degrees off, it will jump to the flare waypoint.

TOm
User avatar
Tom
Site Admin
 
Posts: 1016
Joined: Fri Nov 13, 2009 6:27 pm
Location: Belgium


Return to Software

Who is online

Users browsing this forum: No registered users and 4 guests

cron