After you've built your PiDP-11 the question usually is: Ok, cool,
but what can I actually do with it?
As with vintage cars, you might not use it on a daily basis because, well,
more modern alternatives are just way faster and more convenient.
But once in a while you want to take the old thingy out for a ride so
it is doing something fun and/or useful. So let's discuss some ideas
here:
Today: Getting advance warning from NASA of a supernova in the Milky WayHere's what my PiDP-11 is doing at the moment: it will give me some
advance warning before the next galactic supernova (of a certain type) will
be visible in the sky. A few minutes to many hours before the optical supernova
event can be seen, my PiDP-11 will cause its host Raspberry Pi to play a
Klaxon sound so I can start to prepare my telescope and cameras.
Like this:
https://youtu.be/Ta87XFJVwf0With (say) the I/O extender kit, you could also switch on some lights in the
bedroom etc. to make sure the alarm isn't missed even at night.
Uhh...but...how??
Every time a star in the Milky Way has exhausted its stellar fuel and
collapses under its own gravity, it will produce a strong burst of subatomic
neutrino particles. After that the star will explode in a supernova.
Some of the neutrinos will be registered by neutrino-detectors on Earth, and
this detection will then be broadcast to astronomers around the planet via
a service called "GCN" that is run by NASA. Access to the GCN service is
public, so that amateur astronomers are also able to listen for the alert.
Depending on several factors like the size of the star, there will be a
significant time delay between the neutrino signal and the first visible
signal as the supernova "breaks thru" the star's surface, and this delay
could be as long as several hours, or even longer.
So this is a de-facto early warning system, and actually you can sign-up
for email-notifications via SNEWS, the "SuperNova Early Warning System".
But the faster and more "machine-readable" way to receive alerts is
via NASA's GCN.
There is a short demo C program available from NASA that implements a client
listening for GCN events, one of those events is the SNEWS alert described
above (most other event messages deal with so-called Gamma Ray Bursts).
http://gcn.gsfc.nasa.gov/gcn/voevent_client_demo.cThe messages and network protocol are explained here:
https://gcn.gsfc.nasa.gov/voevent.html The somewhat old-fashioned way the main function is defined
[...]
int
main(argc, argv)
int argc; // Number of cmdline arguments
char *argv[]; // Pointers to all the cmdline arguments
{
[..]
tells you that this code was written some time ago so running it on a
PDP-11/70 is not completely out of whack.
But it nevertheless took me some tweaking to get the code running under
2.11BSD on my PiDP-11 (add some include files, deal with ints that are
just 16 bits long, excessively long lines, taming memory usage,....).
It's easier when your 2.11BSD is patched all the way
up to > pl460 or higher so the C compiler is ANSI-compliant, but
it's also not too difficult to rewrite the short NASA code to K&R C.
Oh, one more thing! You might ask: how often do these supernova events happen
in our Milky Way? That's a good question, scientists estimate that such a
core-collapse supernova as described above, in our own galaxy, will happen
roughly a few times every century, say, once per 30 to 40 years on average.
So if you miss the unfolding in real-time of the next one, don't count on
getting another chance in your remaining life span ;-).
Clear Skies
and a long life
HBE
P.S.: The modern way to listen for GCN event would be using the Python
library PyGCN, found here:
https://github.com/lpsinger/pygcn and that's
what I do most of the time with a dedicated Raspberry Pi.
P.P.S.: No, the next galactic supernova will almost certainly not kill you
or any other earthlings, as it is very unlikely that it will happen close
enough to Earth to cause any damage. Space is big.