collapseos icon indicating copy to clipboard operation
collapseos copied to clipboard

Recover from EMP events

Open hsoft opened this issue 4 years ago • 16 comments

In the discussion around Collapse OS, many comments were about events that would massively destroy data stored on magnetic or electronic support (solar flare hitting earth directly for example).

The goal of this issue is to discuss how we could document a way to prepare for this, provided that a post-collapse user would still have access to functional chips.

My own idea is that manually punching data in a AT28 EEPROM through some kind of makeshift puncher should be feasible, but one would want to have thought of pre-printing some kind of punch card. Otherwise, the work of manually assembling Collapse OS source code to binary could be very very hard.

Because kernels are dynamic, we can't really assemble a ready-to-punch binary, but we could think of some kind of binary, printed in punch card form, with fill-in-the-blanks placeholders.

(By "printing a punch card", I don't mean using a specialized printer, just a regular printer with dots where we need to punch. Everyone has a puncher at home)

If that idea has merit, some tooling and documentation would have to be prepared.

That's just an idea I had in mind. Whatcha think?

hsoft avatar Oct 18 '19 15:10 hsoft

A bin lined in aluminum foil would be sufficient to protect any kind of electronics. I would suggest just keeping a kit in one with the data in an easy to use form if EM is a concern. Punch cards don't seem so easy to make use of. If you need to distribute many copies, I would say the most effective thing would be to flash a number of ROM chips with the necessary binary and put them in the box as well.

QuercusFelis avatar Oct 18 '19 15:10 QuercusFelis

I think even just a standard faraday cage is considered sufficient right?

I wonder in the advent of an EMP, how many electronics would be safe by an "accidental" faraday cage. (Just speculation and probably not too relevant, just a curious thought I felt like sharing)

keithstellyes avatar Oct 18 '19 15:10 keithstellyes

The faraday cage is evident, the problems are the holes in the faraday cages. Any wire is an antenna that will pick the EMP and induce voltage in the faraday protected electronic circuit.

So you need surge arrestors on any IO line that crosses the faraday line. The more you have, the best. This includes

Transil gas discharge arrestors etc

And while it's OK on a serial console line, it's harder to achieve on a high speed CPU bus because of capacitive effects, so the whole system has to be enclosed.

I'm working on the topic and will be able to present a prototype. Just not straignt compatible with CollapseOS, since what I found in my drawers are not Z80s, but 68HC11s, but the concept will be reusable.

In addition, it is of course best to get duplicates of any programmed rom and replacement for every chip.

f4grx avatar Oct 18 '19 16:10 f4grx

The only time of significant risk for an EMP (being the only time you may need a Faraday cage) would be the initial event causing the collapse of a society (solar flare, etc.), before which, Collapse OS is not going to be very useful. I see no reason to have a system run from inside a Faraday cage and thus no reason to put holes in one or have wires come out.

Keep it simple. Just put it in a box and forget about it until the apocalypse.

QuercusFelis avatar Oct 18 '19 16:10 QuercusFelis

At that point it wont work anymore, thanks to the Murphy law. One need regular testing :)

f4grx avatar Oct 18 '19 16:10 f4grx

I agree with @QuercusFelis, just store it in a Faraday Cage until such an event occurs. Especially since it makes little sense to use CollapseOS for non-toy/development purposes anyway so long as other chips and OS's are available

keithstellyes avatar Oct 18 '19 16:10 keithstellyes

Yeah I'm wondering why you intend to put holes in the Faraday cage, that seems to be a strange move. I'd say just make a bigger Faraday cage if you need to access the machine whilst it's inside one.

ghost avatar Oct 18 '19 17:10 ghost

If you want to have some fun with it, get some of those foil-lined sandwich bags that fast food restaurants use, and put a handful of chips in each that would be necessary for a minimal CollapseOS computer.

Honestly I might do this myself eventually.

QuercusFelis avatar Oct 18 '19 21:10 QuercusFelis

To be perfectly frank, the dangers of EMP are way overblown. Most electronics are naturally shielded, computer cases for example, act as farady cages. Then there's all the metal inside of a building, many modern buildings having their own internal Faraday cages in the form of chicken wire to hold up stucco.

Additionally, hard drives themselves have metal cases which also act as farady cages with the old school disk drives being more likely to survive an EMP unshielded than SSD.

I'd wager that most devices following an event such as described in the issue would be fine provided they were stored inside of a building, not connected to any external power source or ground (e.g. unplugged)

Anything inside of an underground bunker is almost certainly going to be okay.

NoahGWood avatar Oct 27 '19 07:10 NoahGWood

That's interesting and useful info, thanks. I agree with you that any metallic shielding will be enough to overcome problems, but as you say, the connections are still vulnerable.

So, apart from completely disconnecting the board, or having the whole system in the faraday cage, do you think that protection devices (probably in combination) on the IO lines would be enough? I'm talking about: -gas discharge cells (I have seen this on military RF lines, and also on GSM amplifiers that have to survive harsh weather conditions on elevated metallic places) -bidirectional transils -series resistors -zener diodes -for signals: optocouplers (probably not integrated ones but rather 5mm LED+phototransistors assemblies)

This would be quite big on a circuit board. So, probably, for a CollapseOS board, only for power and UART. Other lines should not cross the faraday cage.

No idea if that kind of protection devices would survive an average "apocalyptic EMP event".

f4grx avatar Oct 28 '19 08:10 f4grx

@f4grx It really depends on what you're preparing for. A single nuclear EMP? Most devices outside of major blast zones even without shielding are going to be just fine, if a bit glitchy.

A stellar nova from the sun during a magnetic shift of the earth? You've got much bigger problems to worry about than whether your Z80 survives, we're talking about enough energy to vaporize the ocean, and a not insignificant amount of the Earth's crust, etc.

In that scenario the only shielding that could begin to provide electrical protection would be going deep underground and hoping the after effects of such an event don't flood your bunker with water or lava.

NoahGWood avatar Oct 28 '19 23:10 NoahGWood

haha, yes, you are absolutely right and I know it :)

f4grx avatar Oct 29 '19 09:10 f4grx

Instead of manually punching the whole Collapse OS into EEPROM, maybe punch a smaller and even simpler bootstrapping OS into EEPROM that can accept hex listings as input and dump memory content to an output device. An OS like that would really only require two routines to be implemented by the user (getchar and putchar) for whatever makeshift or standard I/O device they have available. Steve Wozniak made such a program for the Apple I in 256 bytes. From there you can write a program to burn some RAM range to EEPROM and load Collapse OS more conveniently.

boomlinde avatar Oct 31 '19 14:10 boomlinde

old story...

PDP11s with CORE memory were used near nuke test side especially the underground ones. Why? well the blast with caus eenough of a ground heave theat the equipment trailer would be bounced around. Usually the systems were in pretty poor shape from that and EMP. They would go and pull the core planes and take them back and read them in another machine.

EMP disipated quickly with distance. Shielding as in metal cases with connector covers do work well to protect gear. Often just unplugging cables is enough.

FYI EMP is a rapidly moving magnetic field and that induces current in wires so shield even aluminum are sufficient to deflect that field. It works like the rotating coil in a motor just bigger. Also most cases if your close enough to suffer equipment damage the blast may be an issue.

Allison

Allisontheolder avatar Nov 12 '19 04:11 Allisontheolder

boomlinde: I have this exact idea for my hc11 collapseOS inspired system.

Allison: Thank you for the useful details. So in theory, there are no problems for anything offline and shielded. Shielding is an absolute requirement that calls no debate. For the sake of conversation, It is then more interesting to investigate possible protection methods for systems that shall stay online and connected during such an event.

Also this interesting article about radhard processors used in space hardware: https://arstechnica.com/science/2019/11/space-grade-cpus-how-do-you-send-more-computing-power-into-space/

Which reminds me that the only possible issue is not only a man-made EMP, but also an all-natural-organic powerful solar storm that will not just shoot voltage in wires :)

f4grx avatar Nov 12 '19 09:11 f4grx

Protecting on line system can be done but at migh cost and still requires the unit to have shielding and then adding protective devices at input and output lines.

I have experience with mountain/hill top commercial repeaters and it take a good effort to protect them from natural EMP (lightning) . Lots of grounding, arc gap devices, transzorb (type of transient absorber) and other tricks must be used. Sometime the best you can do is minimise the damage. An example, radio got hit no damage, antenna ok, coax fried.

The easy way is shielded box with wires disconnected, it unless needed to use it.

Allison

Allisontheolder avatar Nov 12 '19 15:11 Allisontheolder