Serial monitor infinite output

zer0_JuLz:
actually, im using a device which outputs digital signals...and it is connected in pin 12 of my arduino.
(it is an infrared device with a remote as its controller).

A link to the device please.

All this talk about "a device" when you could have specified a part number, and a link to it, is simply wasting time.