Raspberry Pi Programming with MATLAB and Simulink

Build Raspberry Pi projects using high-level programming and block diagrams

Raspberry Pi™ programming usually involves working with images, videos, audio, and other sensor data.

MATLAB® and Simulink® help users quickly analyze and visualize this data and program their Raspberry Pi to respond accordingly. The products support two primary workflows:

Read, Write, and Analyze Data from Raspberry Pi Sensors and Cameras

MATLAB support package for Raspberry Pi lets you write MATLAB programs that communicate with your Raspberry Pi and acquire data from the board’s GPIO pins, cameras, and other connected devices. Because MATLAB is a high-level interpreted language, it is easy to prototype and refine algorithms for your Raspberry Pi projects. MATLAB includes thousands of built-in math and plotting functions that you can use for Raspberry Pi programming, covering domains such as image and video processing, optimization, statistics, and signal processing.

With MATLAB support package for Raspberry Pi, the Raspberry Pi is connected to a computer running MATLAB. Processing is done on the computer with MATLAB.

Using MATLAB for Raspberry Pi programming lets you:

Develop Algorithms That Run Standalone on the Raspberry Pi

Simulink Support Package for Raspberry Pi lets you develop algorithms in Simulink, a block diagram environment for modeling dynamic systems and developing algorithms, and run them standalone on your Raspberry Pi. The support package extends Simulink with blocks for configuring your Raspberry Pi, sending and receiving UDP packets, and reading and writing data from sensors. This includes writing data to the free ThingSpeak data aggregation service for Internet of Things applications.

After creating your Simulink model, you can simulate it, tune algorithm parameters until you get it just right, and download the completed algorithm for standalone execution on the device. With the MATLAB Function block, you can incorporate MATLAB code into your Simulink model.

With Simulink support package for Raspberry Pi, you develop the algorithm in Simulink and deploy to the Raspberry Pi using automatic code generation. Processing is then done on the Raspberry Pi.

Using Simulink for Raspberry Pi programming lets you:

In addition to using Simulink Support Package for Raspberry Pi, you can generate readable and portable C code from MATLAB algorithms and deploy it on a Raspberry Pi using Raspberry Pi support from MATLAB Coder. 

See also: Hardware for project-based learning, Model-Based Design, image processing and computer vision, control systems, Internet of Things, Arduino programming, LEGO MINDSTORMS programming, robotics, control logic videos, communicating with hardware and instruments

Soporte de MATLAB para la Raspberry Pi

Soporte de Simulink para la Raspberry Pi