Create module using Webservice?
Jorge
✭✭
Hello, How Can I create a new module using WebService?. I found how to load, unload, delete, etc.
Thanks
Jorge Turiel
Tagged:
0
Answers
-
Hi Jorge,
I'm not sure about WebService, I have never used it,
but the standard Write instructions can be used in RAPID, e.g:VAR iodev iod_Dev; Open "HOME:", \File:="asdtest.mod", iod_Dev, \Write; ! Write Doc Header WriteString iod_Dev, ByteToStr(37, \Char) + ByteToStr(37, \Char) + ByteToStr(37, \Char) + ByteToStr(0x0A, \char) + ByteToStr(0x09, \Char) + "Version:1.0" + ByteToStr(0x0A, \char) + ByteToStr(0x09, \Char) + "Language:ENGLISH" + ByteToStr(0x0A, \char) + ByteToStr(37, \Char) + ByteToStr(37, \Char) + ByteToStr(37, \Char); ! Write Module Title WriteString iod_Dev, ByteToStr(0x0A, \char) + ByteToStr(0x0D, \char) + ByteToStr(0x0A, \char) + "MODULE asdtest" + ByteToStr(0x0A, \char) + "ENDMODULE"; Close iod_Dev;
If the file does not exist, the Open instruction creates it. In this case it writes a blank module afterwards.
Special characters need to be added using ByteToStr. It's not the most eloquent solution, but is there a way you can make a RAPID procedure call using webservice?
I hope this helps,
Regards,
Harry0 -
These days your modules don't need that header, btw.Lee Justice1
-
I'm curious, why is that? Or why did they ever need the header? I'd seen it in examples so I've been using it.0
Categories
- All Categories
- 5.5K RobotStudio
- 392 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 249 ScreenMaker
- 2.7K Robot Controller
- 307 IRC5
- 59 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 3 RobotStudio AR Viewer
- 779 RAPID Programming
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 4 Job listings