Vs1838B break beam problem
IR receiver modules like you have typically reject continous 38kHz signal. You need to send for example a 500 microsecond burst of 38 kHz signal and then pause for some time - optimum value depends on how the AGC is tuned to allow optimum reception of certain kinds of common IR remote protocols. The datasheet of your module says it is tested with a signal of 600 microseconds of 38 kHz burst following a 900 microsecond pause, so it is a reasonable starting point for transmitting your signal.