This error is an indirect error message. It tells you that your program broke somewhere. What you want to post is the actual error message with actual line numbers that tell you exactly where it all went wrong. (It's called the stack trace. Use a try-catch block to print it.)
At the moment, I don't have a bot to test this code on, but it seems highly likely that this is a nullpointerexception error. The timer code looks okay, so if I were you, I would check if the motors are all plugged in right and if the camera is setup to the exact IP address you're querying (10.40.64.11).
Also, is that space deliberate between the 640 and x480 in line:
Code:
camera.writeResolution(AxisCamera.ResolutionT.k640 x480);