Event Manager Calls VSTA Macro Twice
in RobotStudio
Hello,
I am developing a simulation of a robot picking products from an external axis and adding them to a pallet. I have created a macro that can import a library file representing the product and attaches it to the external axis.
When I run the macro from RobotStudio -> Add-In tab, right-click -> Macro_ImportFile - > click Run Macro button, it works perfectly and calls the macro only once, and attaches only one product to the external axis. It does this everytime I push the button, no problems.
When I create a station signal Digital1 that calls the VSTA Macro when Digital1 goes high, the Macro is called twice, thus attaching two products to the station. This is the only event in the event manager, and nothing else should be calling the Macro. There is also only one Macro_ImportFile() call within the VSTA code.
Any ideas anyone?
Thanks,
Matt.
0
Comments
-
Just to note, this only happens in this particular project station. i.e. When the same macros are called from the event manager in another project, the macros are only called once.0
-
HiI had the same problem in one of my stations. It turned out that my VSTA Add-In was loaded twice. It was loaded under "VSTA Station Add-Ins" and "VSTA User Add-Ins".I unloaded it from "VSTA User Add-Ins" (so it was colored gray insted of blue) and it worked fine.Hope this may help.?yvind Birkeland
Systemdeveloper
Frekhaug Vinduet AS0 -
Hi Oyvind,I realised this after a while and noted how it reloads the VSTA Add-Ins every time that the code is recompiled.Thanks,Matt.0
-
Yes, it does that in my application also. It reloads the VSTA Add-Ins under "Station Add-ins" AND "User Add-ins" every time I compileVery annoying....?yvind Birkeland
Systemdeveloper
Frekhaug Vinduet AS0 -
Maybe we are doing something wrong? Anyone care to comment??yvind Birkeland
Systemdeveloper
Frekhaug Vinduet AS0 -
Hi Oyvind,I created a new Add-In and immediately after saving added this new Add-In to my station. From here it ony appears under the "VSTA Station Add-Ins" and no longer duplicated in the "VSTA User Add-In" lists. From here I copied my code over to the new Add-In. This is worth doing if you have a lot of debugging to do.Good luck,Matt.0
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)
- 786 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 5 Job listings