A follow-up to lineskier's recommendation: print the
camera variable right after initializing it inside of robotInit().
Code:
public void robotInit() {
camera = AxisCamera.getInstance(); // get an instance of the camera
System.out.println( "Printing camera: " + camera );
cc = new CriteriaCollection(); // create the criteria for the particle filter
cc.addCriteria(MeasurementType.IMAQ_MT_AREA, AREA_MINIMUM, 65535, false);
}
If camera is indeed null, as it almost certainly is, you will see this:
Printing camera: null
I am not sure what would make this return null...other than having a misconfigured Axis camera. If you open a web browser and type in a url of 10.xx.yy.11 (where the xxyy is 3673, your 4 digit team number), do you connect to the Axis camera? If not, then you will need to reconfigure your camera. Here is the WPI page for configuring an Axis camera:
http://wpilib.screenstepslive.com/s/...an-axis-camera
Good luck and post again if this doesn't help. Once you get it fixed, let us know what fixed it so that the thread becomes a resource for others.