In the past versions of MATLAB you could use USB-camera block to acquire by raspberryPi but there was some lag, so acquisition was not real-time. With new Matlab version you can use matlab classes to control raspberry cameraboard:
http://www.mathworks.it/it/help/raspi/examples/working-with-raspberry-pi-camera-board.html
but you must set the duration of acquisition and it takes snapshot, etc...
I have followed this guide to use V4L2 camera block (usb-camera block) with cameraboard insted USB-camera:
http://www.raspberrypi.org/forums/viewtopic.php?f=43&t=67424
by remote execution of Linux command in matlab (like here):
[status, message] = h.execute(['sudo modprobe bcm2835-v4l2'])
but acquisition is not real-time (there is again lag that I told above) like USB-cameras.
Using the Linux cameraboard command, instead, with:
[status, message] = h.execute(['raspivid -o vid.h264 -t 20000'])
where 20000 is duration of acquisition in msec, it performs a real-time acquisition, so I was thinking to use that in a MATLAB Function block but I guess that class is not supported for code generation because it does not appear in this list and furthermore I must specify duration.
Is there someway to use that in a simulink block (working continuously) for real-time execution in this new matlab version?