Hello, engineering teacher here trying to figure out how to teach students to use the new VCS C++ programming language. I have very little background in programming, but in talking with coworkers who are CS majors, it seems like there are a few bugs:
- Printing a percent symbol (%) does not work like expected. The VCS Command Reference site has the following sample code:
Brain.Screen.printAt(1, 20, “Battery Capacity: %d%%”, Brain.Battery.capacity());
But I had to use four % symbols in a row to get it to print to the brain screen. So my code looked like:
Brain.Screen.printAt(1, 20, “Battery Capacity: %d%%%%”, Brain.Battery.capacity());
Next, and probably the more important one, I realized that you don’t need to write out the full hierarchy for the different classes/functions (sorry, don’t know correct terminology) for most lines of code. For example, you can write:
LeftMotor.spin(directionType::fwd, 50, velocityUnits::pct);
or…
LeftMotor.spin(fwd, 50, pct);
Both worked. The second might be easier to teach students, but unfortunately you can’t always delete that first part with the double colon after it. I noticed it doesn’t work with:
task::sleep(1000); //so you can’t just write “sleep(1000);”
or
Sonar1.distance(distanceUnits::mm) //can’t remove “distanceUnits::”
Thoughts? Any other “bugs” you’ve noticed?