How to create a callback function in MATTLAB that calls a routine everytime it receives a data frame from an external sensor ?
2 次查看(过去 30 天)
显示 更早的评论
Dear all,
I am attempting to write a callback function in MATLAB; a routine that calls a function every time a condition is satisfied, i.e. an event driven routine running in real-time. The condition, in my case, is receiving a meaningful frame from a sensor, i.e. Leap Motion controller.
Matlab has built-in callback functions that are associated with GUIs, e.g. 'WindowButtonMotionFcn' that can be used in the format "set (gcf, 'WindowButtonMotionFcn', @mouseMove)". My objective is to have an event driven routine similar to 'WindowButtonMotionFcn', but the event that calls my function, e.g. @FrameArrival, is the arrival of a data frame from my sensor rather than moving the mouse cursor over the current figure !
Could I possibly write such a call back function that is not attached to a graphic object or GUI ?
Regards,
Bashar
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Specifying Target for Graphics Output 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!