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 个)

类别

Help CenterFile 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!

Translated by