Where the Variable values are stored?
Hi,
I would like to analyze some data from laser scanner, which is just 1D array as defined below:
PERS num n_GI_Left_Array{n_NUM_SAMPLES_BW}
FOR i FROM 1 TO n_NUM_SAMPLES DO
n_GI_Left_Array{i} := GInput(gi_Sensor);
......
ENDFOR
I wonder if someone could tell me how I could find, save or retrieve the values in the array for analysis.
Much appreciated in advance!
Donald
I would like to analyze some data from laser scanner, which is just 1D array as defined below:
PERS num n_GI_Left_Array{n_NUM_SAMPLES_BW}
FOR i FROM 1 TO n_NUM_SAMPLES DO
n_GI_Left_Array{i} := GInput(gi_Sensor);
......
ENDFOR
I wonder if someone could tell me how I could find, save or retrieve the values in the array for analysis.
Much appreciated in advance!
Donald
0
Best Answers
-
Hello Donald,
Persistent can be defined with and without initial value.
If the initial values are not used, as in your case, the current values are only stored within the robot memory but not written back to the program.For persistent with an initial value, the current values are stored in the robot program and can be reused.
The initial values must be assigned to the data declaration and the number of data must correspond to the data field size "n_NUM_SAMPLES_BW".
PERS num n_GI_Left_Array{n_NUM_SAMPLES_BW}:=[0,0,0,0,0,0,0,...,0,0];0 -
Donald,
I don't know what system you are using or how it is set up, but in the old days, you could hook up a printer to print out this kind of thing using the serial port. Serial ports are becoming harder to find now days with networks so readily available. So, if you are on a network, you should be able to do the same thing digitally. If you are stand alone, then you will need to write some Rapid to tell the controller to save the data to a file by part, hour, shift, job, day. etc.... I would think this could be done using the service port, but if not, then the Lan port would be an option. Either way you will need to collect the data often and store in a different local or you will fill up your memory with clutter.0
Answers
-
Hi Micky and Elderwild , Thank you very much for your answers.
My problem was solved by defining them as System Global PERS to get around with the initial values sytex errors.
According to technical reference manual : "Since PERS can be declared in 3 different types: System Global, Task Global, and Local. The first one can be initialized with Omitted values, but not the later two. "
To used them after declaration, simply follow the arrayName{#} format.0
Categories
- All Categories
- 5.5K RobotStudio
- 394 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 249 ScreenMaker
- 2.7K Robot Controller
- 309 IRC5
- 59 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 785 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 4 Job listings