I am a beginner Java programmer and I want to see how a URCap was constructed.
I have a Cognex .urcap file. I extracted the .urcap file and imported these files into eclipse, but I don’t see any code for the GUI or communication with the robot. The example URCaps have their code in src/main/java. Is it possible to view other developers URCaps code?
The URCap I am trying to look at can be downloaded here: https://support.cognex.com/en/downloads/detail/in-sight/4004/1033
Sometimes yes you can just change the .urcap extension to .jar (or pull the .jar out of the robot via command line) and read the code. However, the software should be copyrighted and viewing another company’s proprietary software with the intention of seeing how they did something has potential to open you up to legal ramifications. It’s also possible they’ve obfuscated their CAP, or else use XML-RPC calls through a python file so you can’t see exactly what’s running in Java anyway.
The example CAPs are provided by UR for the sole purpose of being copied/learned from to help us create what we want, so that’s why those are easy to view.
1 Like
Is there a way to see the XML-RPC python files so you know what types of device functions you can use?
I mean maybe? You’d have to dig in to the linux terminal but honestly if you’re just trying to figure out what kinds of functions you have access to you’re WAY better off contacting them and asking for documentation.