Well you did say that the locomotive derailed on a switch, after you did have it running. That could have caused the program problem at that time.It is a Bachmann Spectrum, so Im guessing a Bachmann decoder. Could that still be the problem even if it did run a little as I mentioned?