This circuit is from the 1972 Linear Data Book of RCA, but it can be made with more modern equivalent comparators and for solenoid currents up to 2 A, the TIP32 can be used. For currents ta 500 mA the BD136 can be used.