Using a Script to Simulate a Serial Device for VirtualBox

Recently I needed to simulate a serial device (a GPS, to be precise) for a Windows application I'm modifying for a client.

I don't use Windows on a regular basis, but I do have a license for it, and an original Windows XP CD from back in the day, so I loaded Windows in a VirtualBox virtual machine for the odd occasion I might need Windows, like when I build the Windows version of OpenLP 2.0.