16 bit signed int overflow brings air traffic control to standstill
bbc.co.uk
bbc.co.uk
In any case, max signed 16-bit integer is 32767. It's unsigned 16-bit integer to get to 65536, so this title is wrong.
This topic has come up a couple of times already here on HN, including https://news.ycombinator.com/item?id=7691583 and https://news.ycombinator.com/item?id=7694121 . The report is that the U-2 was flying at 60K feet, not 65K which might trigger the problem.
One commenter pointed to a page which point to http://www.barryschiff.com/high_flight.htm which says "The U-2's Mode C transponder, however, can indicate no higher than FL600."
Mode C can go slightly higher, but "commercially available Mode C transponders cannot currently report an altitude greater than 62,000 feet" says https://www.faa.gov/about/office_org/headquarters_offices/as... .
So of the limited information we do know, the U-2 should not have triggered an overflow, assuming that such a bug existed.
BTW, according to http://www.airsport-corp.com/modec.htm , the altitude encoder data has a higher range: -1200 to 126,700 ft. One of the reason for negative altitude is of course places below sea level, but another is that altitude when measured via barometric pressure depends on the weather. High pressure days give a lower measured altitude.
int32_t to the rescue!
Why would altitude ever be negative?
Just a thought.
"USAFE C-130J Practice negative Altitude Landing by the Dead Sea"