Info
This question is closed. Reopen it to edit or answer.
Help newbie with timer functions.
1 view (last 30 days)
Show older comments
Hi Guys, I’m currently working on a project to identify RGB components (Legos) on a moving conveyor using a webcam, and hence sort them into corresponding bins using pneumatic cylinders. The image analysis section is working well, and positively identifies the colour of the Legos every time.
I am currently controlling the cylinders through an Arduino and some low trigger relays.
The issue I have is,at this moment I’m using pause commands to delay the actuation of the cylinders until the Lego block has moved from the camera to the push location on the conveyor, this creates an issue as the code pauses for the duration of the pause command and no more Lego blocks can be added to the conveyor until the code continues.
can I fix this with a timer? is there a way to queue the cylinder commands?
kind regards,
Jordan.
0 Comments
Answers (1)
Sai Bhargav Avula
on 29 Jul 2019
temporalCount() function gives you the elapsed time in milli seconds in each state. Using this the execution of commands can be organized in the state flow. Refer to the following link for better understanding of temporalCount().
You can refer to the below link to check other MATLAB functions that can allow you to organize the command execution.
0 Comments
See Also
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!