noobplans.blogg.se

Robotc mac
Robotc mac






  1. #Robotc mac full
  2. #Robotc mac code
  3. #Robotc mac plus

In order to see any of the data you just recorded, you’ll need to set the correct debugger window to show. The DataGroup start / end “bookends” do not take any arguments/parameters.In the example above, there will be a blank column at index 3, because I found it easier to look at the output with error, integral, and derivative right next to each other, and then a blank column, and then show the encoder counts in the 5th column (index 4). You can have blank columns if it helps you look at the output data.You can track up to 8 items the index for each follows the usual way of counting the position in a matrix, so the possible values are 0 to 7 (and not 1 to 8).You can include variables or stuff like joystick and sensor values, as shown in this example.

robotc mac

  • The datalogAddValue() function takes 2 parameters: the index of the thing you’re keeping track of, and the thing you’re keeping track of.
  • #Robotc mac code

    This block of code is inside the while loop I’m using to create my PID function, so that each time through the loop, it adds another row to the data with the current iteration’s values. To make it work, these calls have to be sandwiched in between a “start” and an “end” instruction, like so, with one “add” statement for each variable you want to track: datalogDataGroupStart() ĭatalogAddValue( 4, SensorValue ) The datalogAddValue() function does just what it says: it adds data to the output listing.

    #Robotc mac plus

    (There’s also datalogAddValueWithTimeStamp, which does the same thing with - duh - a time stamp, plus a few others I have not used.) So far I’ve only used the datalogAddValue function, which I’ll talk about here. There are not that many items to choose from. The RobotC functions for the datalog can be found in the left-hand column of the help page above. The datalog feature only works if you add code to your program to tell it to keep track of the stuff you want. Instead, as shown in the screenshot below, you’ll want to navigate to Command Library – VEX Cortex > ROBOTC > Datalogging. This is NOT the place to find datalog information (thanks a lot, RobotC). The confusing part of finding this datalog information is not done yet from the main help page, in the left-hand column is a table of contents, and one of the items at the top level of navigation says “ROBOTC Debugger”.

    #Robotc mac full

    I include the full path here instead of embedding the link because RobotC has various different wiki/help sections, and as shown in the URL, this one is specifically for VEX. So, start here on the RobotC help page for VEX. One thing that has prompted me to write this post is that I find the RobotC datalog documentation difficult to locate via Googling, so I wanted to make finding it easier for everyone else. The Help Page’s Secret Hiding Place Revealed

    robotc mac

  • Tuning a PID, and the mysterious kU and pU.
  • I happened to be working on writing a PID function, but you could use this feature any time you want to be able to look back through the execution of the program to see what *really* happened at each step. The way I’ve been using it so far is to track data during the execution of a while loop.

    robotc mac

    Since I’ve been using this for like a week, I’m sure I have only scratched the surface of what it’s capable of. RobotC’s datalog feature allows you to track up to 8 pieces of data (variables, sensor values, etc.) as the program executes, with super-easy, one-click exporting to a CSV file and automated, customizable graphs. With eas圜, you’re limited to either making good use of the LCD screen or having your robot tethered to your computer and doing a lot of print-to-screens, which zoom by at a million miles an hour, with data that’s really hard to get into a spreadsheet afterward. So what is the datalog? In short, it’s print-to-screen on steroids in the most helpful way. The datalog is one of the multitude of benefits I’m experiencing with RobotC over eas圜, which we have used up to this season. Thanks once again to the coaches on the VEX World Coaches Association Facebook group for guiding me along here.

    robotc mac

    🙂 This week I learned about RobotC’s datalog functionality. When I learn something new, all you readers get to learn it too.








    Robotc mac