String to number conversion and checking the reachability in RAPID
pion3k
✭
in RobotStudio
Hello,
I need some help with the following problems:
1) Is it possible to somehow convert a string (in my case received through a socket) to the equivalent data but in a number type in RAPID? I have tried with StrToByte but the problem is that I'm significantly limited by the range of the byte type (0 - 255 without negative values). What I need is to send by the socket the position of the robotic arm and, as you know, the position of the effector can quite a bit exceed the limit (255). I thought about multiplying the values but in this case I would lose a possibility of reaching intermediate points. And still, what about negative values?
2) How can I check a reachability of a specified point by a RAPID code? Generally, my program crashes now when the coordinates of the demanded point are exceeding the robot's workspace limit.
0
Best Answers
-
hello,
1. you can use strtoval for converting string to numbers
2. you can use CalcJointT for checking reach, if it gives an error ERR_ROBLIMIT then you know the robot cannot reach the position
BR
Peter
5 -
i have found the error it was in the format of using StrToVal5
Answers
-
Hello,i have the same problem , i have this variableVAR string Fx_S1:=0.784184821186377;i have imported from C# addin , and when i use the commandVAR strtoval Fx_S1;it gives me the following error :IRB4400_60kg_1.96m_245/RAPID/T_ROB1/MainModule(3,2): Name error(49): Variable name x_S1 ambiguous. 10/14/2013 8:40:28 PM GeneralChecked: IRB4400_60kg_1.96m_245/RAPID/T_ROB1: 1 semantic errors. 10/14/2013 8:40:28 PM RAPIDany help is really appreciated0
Categories
- All Categories
- 5.5K RobotStudio
- 396 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 249 ScreenMaker
- 2.7K Robot Controller
- 310 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