Arduino keeps locking up/freezing

So I have connected a coil over a 4v battery as a dummy load - it draws about 1.5amps at 4 volts. I have decoupling capacitors and a diode (1n4004) over the battery terminals (where I connect the dummy load) however whenever I disconnect the dummy load, the arduino freezes or sends garbled text to the LCD then locks up.

Any ideas?

That is from the inductive voltage spike. Leave the diode connected across the coil terminals (banded end connected to the + side).

jremington: That is from the inductive voltage spike. Leave the diode connected across the coil terminals.

Ok, I understand that much. but I leave the diode connected and the arduino still freezes

Why do you have an Arduino at all?

Use separate power supplies for the coil and the Arduino, but connect the grounds.