I think the advice @Alexab33 gave is really good! Maybe try charging it for a good amount of time ?
You can also try hitting the reset button (which is that tiny hole on the side. You can access it with a pin or paperclip).
Some questions to figure out what's happening:
When you say the Jewelbot wont take any code, are you pressing the button for 2 seconds while plugged in before hitting upload?
For the one that keeps turning off, do you see a charging light when you plug it in? When you unplug it, can you press the button once? After pressing it, do you see a single red light blink?