The idea of my simulation is to use to the triangular clamp to pick up number of balls and then place it in the stand (can hold up to six balls).
I was able to opening and closing of the clamp was working fine in the simulation (by just setting the corresponding signal to open and closing it in the MAIN). However, when I try to put it in a PROC and run it multiple times, the clamp would only open on the first time.
I am just wondering what causes this problem and if there is any way to get around it other than putting everything in the MAIN?
okay.. try checking onto the status of your digital IO "clamp"in the “IO simulator” in the “simulation” tab while running your program.. if it stays 1… there’s some problem with the program.. try using “Set clamp / Reset clamp” instead of “SETDO clamp, 1; or SETDO clamp, 0”.
I tried using both set/reset and SETDO 1/0, I observed that the signal from IO simulator changes, but the clamp itself isn’t showing the opening/closing.
Also, not sure if this would help. But when I try clicking the output signal manually on the IO simulator, the clamp does response to the signal and open/close.
Thanks for your advice megatool, so I am now using SET/RESET instead and I had to invert the signals so that signal is RESET at the end of the PROC and for some odd reason this works, i.e. SET=close and RESET=open… very strange…
Now that the problem with opening and closing of the clamp is fixed, I am having another problem with binding to child parts. For some reason whenever it is going to grab the balls that are created from “source” it gives me an error:
“Property Binding failed to set ‘Child’ (Value is not allowed)”
However, it doesn’t seem to have problem grabbing the ones that I created manually through “Modelling”. Also, the signals between the clamp and ball are passed on through dynamic property, so I don’t understand what is causing this problem.