Tuesday, December 13, 2005

Altitude calculations

The cold turned out to be the flue of the year, so I haven't been able to do much on this project for some time. Now I'm out of the fever fog and have been able to do some research about the altitude calculations and such. This is something I have to work on, but I will get back with more details as I start to implement it.

Wednesday, December 7, 2005

Low alt warning

Headache, soar throat, a voice like James Earl Jones and some slight fever. The diagnosis is a cold. But nothing is going to stop me from working on this project.

I had planned to start working on the input into the flight computer, but we decided that we needed to get the low alt warning to work properly. After some research it seems like we will be able to make all the different low alt warnings work. AJ37 i a rather old plane so it had a rather simple system compared to modern aircrafts. All conditions for low alt warning are based on the current height and do not consider any obstacles in front of the aircraft, which would have been impossible or at least not feasible to do in Microsoft flight simulator since there is no functions or variables to get that information. The only ways around that would have been to either have our own set of terrain height data which would probably not match the terrain in the simulator good enough, or we would have to hack the terrain file format in the simulator and that would be a very big project. Luckily we don't have to that.

Apart from the warnings you get altitude hold and some special warnings at different weapon choices, which are not indicated in the HUD anyway, there are two conditions for low alt warning: bottenvarning and metspövarning (translates roughly to bottom warning and pole warning). The bottom warning is induced by the radar altitude falling below 150 m and at the same time is not less than half the altitude measured by air pressure. The pole warning is induced by the current sink rate predicting the aircraft to hit the ground within 7 seconds. There are also some extra conditions for these warnings.

Low alt warning is indicated in the HUD by the altitude pole package is blinking with a 5Hz frequency. This is now done for the pole and bottom warning except that the only extra condition I've implemented is that no low alt warning is induced under 50 m if the landing gears are out. To implement the rest of the conditions I need to do more research.

At the same time I put back the function that turns the HUD off at climb angles over 15 degrees or under -15 degrees. This function has a hysteresis, which means that it's not turned on until the climb angle are lower than 12 degrees or higher than -12 degrees. This function was implemented earlier, but was commented out when I did a restructuring of the program last summer.

I don't know if anyone is reading this programming diary, but if I sometimes am a bit to technical, use terminology you don't understand, I might not be technical enough or there is something you wonder about then feel free to tell me. Maybe some one would like to see some screenshots?

Now I'm returning to the bed so I can get rid of this cold.

Sunday, December 4, 2005

I got and idea...

Some early morning work. Woke up and had a slight feeling that it was actually possible to get an acceleration value from flight simulator. When you wake up in the morning and have an idea, you shouldn't stay in bed. It's imperative to act while the idea is still fresh. And quite right.... there is a value for acceleration over the X, Y and Z axis. Can't understand where I got the impression there wasn't. Then it was just half an hour work to make the time line for rotation order to move.

This means that start mode (or takeoff mode as you would probably call it in English) is 100% finished, and it's time to start working on input and output from the data panel. This is to be able to present navigational data in the other HUD modes.