Long ago, I wrote a program called Overseer, which helped prompt and record the inspections of Fire Protection equipment. It helped make generating electricity safer in the small, and the process of extending and revising it lead me to quite a number of friendships. I wrote the whole thing in Turbo Pascal, back in the days of MS-DOS. I had databases, reports, and a handheld computer to talk to via a weird HDLC controller card. It was an interesting mix of technologies. In the end, we adapted it to a few other areas of application. It was quite rewarding to be able to help people actually keep the world going.
Once I wrote a Forth for OS/2 in Assembler out of spite... because it was Impossible to do so, you were supposed to only be able to write for OS/2 in C (which I hated). Brian Mathewson came along and wrote a manual for it after I open sourced it. Much fun was had by all.
One day, I was working away, and heard my co-worker talking to the owner of a light bulb company... and he was describing the need to "season" halogen lamps, and was wondering how to keep the filament from sagging while it was heated the very first time. I suggested they levitate the filament, and set up a demo with a thin wire the next day. I learned a lot about the manufacture of bulbs, and helped light the world. (The technology wasn't invented by me, GE had done something similar decades ago, but how was a trade secret)