- Open Simulink
- Create a new model
- Add a new block, 'I2C Read,' to the model
- Add a display block and connect it to the output of the 'I2C Read' block
- Open the model configuration parameters and set the hardware board property under the Hardware Implementation Pane to Arduino. For more information, refer to the documentation page Set Model Configuration Parameters for a Model
- Save the model
Reading data from BMX160 sensor to Simulink
6 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I have an Arduino Uno connected to the DFRobot BMX160+BMP388 sensor.
I need to pull data from the sensor to the Simulink eventually on the Airspeed indicator, Horizon indicator and Heading indicator. I never used simulink before and I have been trying to do it using I2C Read block but I am not sure how to connect it or get any data from it.
0 Kommentare
Antworten (1)
Anil Kumar
am 21 Mär. 2024
Hi,
I understand that you are trying to read data from a sensor connected to an Arduino into Simulink. You can follow the steps below:
For reading data from a specific I2C slave address or the I2C slave register address, refer to the documentation page I2C Controller Read
I would also recommend you using MATLAB version R2015a or newer
Regards,
Anilkumar V
0 Kommentare
Siehe auch
Kategorien
Mehr zu Arduino Hardware finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!