Re: Why can you install software incorrectly on an aircraft?
the problem wasn't that the software is buggy. Rather, someone in the final assembly process installed the software incorrectly.
Having worked for a defense contractor, let me translate: The software was buggy.
You never, ever admit fault to your customer, ever, as this can and will affect your ability to get new contracts and also scuttle the contractor's stock price. If pressed you only admit to human error (which is impossible, see below).
To make this more clear, the final assembly process is the most solid part of the process. The final code is complied, after which it is run through an automated code check which can take hours. In final assembly, or rather when the code is loaded into each computer, a series of diagnostic tests and simulations are run to verify both HW and SW operation. These are composed of test vectors simulating actual operating conditions. These are all Go/NoGo tests as simple as a green light means pass and a red light means fail.
Upon power-up (here, before each flight) all systems run some built-in self-test (BIST) diagnostics. They are not just standalone tests, they depend upon inputs from other systems on the plane that share the same parameters. A failure locks the system and prevents operation. See how this can't be an isolated failure?
For a failure such as this I have seen two reasons for failure: either the software was buggy, or somehow the system was tricked (hacked or accident) into running the factory test simulation code. In one case (not a plane) the operator accidentally pressed a secret key combination (holding down 3 keys simultaneously, released, then pressing one key within three seconds) that forced the system into diagnostic mode, with tragic consequences.
Maybe things are different with non-U.S. contractors, as the above process is extremely expensive.