Movement Script icon Movement Script Trigger direction-specific scripts when ARC movement panels change; assign scripts per direction/stop, access direction and speed (JS/Python/EZ). Try it →
Asked — Edited

Syntax Error In Ez Script. I Am Missing Something

Hey guys. I am just starting to write a script for my bot and I am trying to get data from a Parallax ping sensor and decide what to do with the data.

I think I have typed the script right but I am getting an error. Can you guys take a look and let me know where I messed up.

Thank you

User-inserted image


ARC Pro

Upgrade to ARC Pro

Elevate your robot's capabilities to the next level with Synthiam ARC Pro, unlocking a world of possibilities in robot programming.

#9  

Well thanks for trying it out. I just change it to a variable and the error is gone. So I'll try and run it tomorrow when I get home from work.

Then i am going to add more code. I am excited to learn more coding I like to code. That is why I like my job as an electrician and working with Fanuc robots and plc's in a manufacturing plant.

Author Avatar
France
#10  

Hello !

If you use parallax ping with 3 wires ,you can simply use "getADC" instead of "getping" , because your sensor have just an analog output . Getping is for sensor that need a trigger.

(sorry ,bad "frenchglish" eyeroll )

#11  

@FredoO

I never thought of using an ACD. Thanks for the idea I'll try it.

P.s your english is fine. Lol.