Live data from Hacker News

Ada holding up F-22 Raptor upgrades

defensenews.com

31–38 of 38 posts

Re: Ada holding up F-22 Raptor upgrades

#31
post #28

Earlier quoted context omitted.

> I'll bet that the F22 software is not actually that much more complicated than that controlling a modern car, yet Ford or whoever can spread the cost over a million units. I'll bet it is. A car is significantly simpler than a fighter plane (at all levels of resolution), even when you discount weapons and detection systems. Which you can't discount when you're building software for a plane. Furthermore, the risks in…

It's true there are no end-to-end 100% drive-by-wire cars. But there are certain drive-by-wire systems in many modern cars. Electronic throttle control[1] is widespread (or universal?) and brake-by-wire[2] is already used by Mercedes and Toyota. 1. http://en.wikipedia.org/wiki/Electronic_throttle_control 2. http://en.wikipedia.org/wiki/Brake-by-wire

Electric steering, too

http://en.wikipedia.org/wiki/Power_steering#Electric_systems

Several years ago, a friend bought a BMW M6 the year they came out. A few days later, he noticed when the tires were pointed straight forward, the steering wheel was not centered. He took it to the shop, and they told them "that's a software bug".

Re: Ada holding up F-22 Raptor upgrades

#32
post #7

Earlier quoted context omitted.

I have no idea about their overall code quality but there was a famous F-22 bug found a few years ago where it lost all navigation systems when crossing the international date line. http://www.defenseindustrydaily.com/f22-squadron-shot-down-b...

Date/Time code is notorious. It always seems simpler than it actually is. There are always corner cases you forgot about. None of it is rocket science. Instead, it's the stupid arbitrariness of it that gets you. (Commodity trading is often the same.)

My boss taught me that whenever the word date / time / etc creep into a spec double your estimation for completion.

He was trying to be funny to make a point... but there is definitely a nugget of truth to it. Time is hard. (I write embedded DVR software these days)

Re: Ada holding up F-22 Raptor upgrades

#33
post #2

OK, everyone here who codes in ADA, raise your hand. Atlas?

I write real-time avionics software for my day job. It's done almost entierly in Ada95.....I don't work on the F-22's.

So then what's your take on coding in Ada compared to other languages?

Re: Ada holding up F-22 Raptor upgrades

#34
post #30

Earlier quoted context omitted.

That's the result of a combination of two things: aircraft don't often have one of the major problems that cars have (dense traffic and other obstacles), and that the problem of dissimilar surfaces was solved, for aircraft, by making the surfaces more similar. Cars instead have to be able to negotiate a variety of terrain. So, safely automating cars is a harder problem, but not because the car itself is a more comple…

A harder problem requires more complex software, no? The complexity of the vehicle itself is actually not a factor.

Oh, you're right. Somehow I misread your earlier statement as being about the complexity of the machines themselves.

I agree totally with you then. Even accounting for avionics, control surfaces, target acquisition, and so on and so forth, automating cars is a much harder nut to crack, software-wise.

Re: Ada holding up F-22 Raptor upgrades

#35
post #15

What's used in place of Ada nowadays?

OCaml would be a great fit for this space, so would Haskell or Scala...

Oh hellz no! Most of the systems ADA is used for tend to be realtime stuff. The moment you utter the words "Garbage Collection" you throw your realtime guarantees down the toilet.

Re: Ada holding up F-22 Raptor upgrades

#36
post #35
post #15

Earlier quoted context omitted.

OCaml would be a great fit for this space, so would Haskell or Scala...

Oh hellz no! Most of the systems ADA is used for tend to be realtime stuff. The moment you utter the words "Garbage Collection" you throw your realtime guarantees down the toilet.

Tell that to Airbus: http://www.astree.ens.fr/

Re: Ada holding up F-22 Raptor upgrades

#37
post #29

Earlier quoted context omitted.

I've played with it, it's a nice language. Don't see why people hate on it, it's not especially verbose, and the static types are actually helpful (like, you can cleanly loop over the extent of an enumerated type, for example) as well as more than usually protective (like, you can type define "inches" and "centimeters" as kinds of integer, and it won't let you mix them by accident).

F# has units of measure too.

It goes a bit deeper than that.

Most static typed languages - C, Java, Haskell, etc are memory representation centric in their primitive types. Ada is usage centric.

You see that two ways.

First, in most languages any item with underlying implementation X can represent any legal value of X, even if it makes no sense. If you want to represent a quantity whose maximum value is one million, putting it in anything shaped like a 32-bit int will let it contain the illegal value "one million and one". Contrast Ada which will let you cap its legal range.

Second, in most languages any item with underlying implementation X can contain anything else with the same implementation. Your typedef'd int can be put into anything else int-sized. Contrast Ada, which won't permit you to mix apples and oranges if they are defined as distinct types with int storage.

Re: Ada holding up F-22 Raptor upgrades

#38
post #36
post #35

Earlier quoted context omitted.

Oh hellz no! Most of the systems ADA is used for tend to be realtime stuff. The moment you utter the words "Garbage Collection" you throw your realtime guarantees down the toilet.

Tell that to Airbus: http://www.astree.ens.fr/

Hardly the same thing though. Astrée is a static analyzer used to help prove avionics code written in C, it's not used in any onboard avionics systems. So its lack of real-time processing is not important.

If you're writing real-time avionics software, your choices are really only Ada, C and C++. Most companies I know of, including Airbus, are using C. Typically, avionics software has to be qualified to DO-178B/ED-12B standards which specifies certain development, testing and proofing requirements. Software verification tools like Astrée are also governed by DO-178B/ED-12B, though they are subject to a lighter verification process.

Post reply on HN