I think you might want to add parentheses to make it look like this:
Code:
victor->Set((CIM->Get() > 5) ? 0 : 1);
Also, if you want to use encoders and victors on the same ports during teleop, you should create those objects in a single file called RobotMap.cpp and then pass them along to each subsystem, not inside a command. Things can get really messy when you start creating objects inside commands. Have a look at our
2016 kitbot code for how we usually do it (sorry it's really messy, things haven't been cleaned up). Also check out wpilib for more details and best practices for command based code:
http://wpilib.screenstepslive.com/s/...ed-programming