This application is not modern since few computers have parallel ports. But you can use this circuit to control something using an old PC. The circuit suggested bellow is simulated in the NI MultiSIM as shown. The circuit can control relays, lamps or LEDs up to 50 mA, but replacing the transistor by a BD125 loads up to 500 mA can be controlled. Observe the adjustments for the function generator do apply a very low frequency square signal to the circuit making the lamp to blink.
To download the simulation files and Netlist - click here (ni0021.zip)