MMA8451 MATLAB Arduino Interface

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MMA8451 MATLAB Arduino Interface

1,058 Views
sedtechnical
Contributor I

Hello! 

I am trying to develop a program in MATLAB that reads in data acquired from an MMA8451 accelerometer. The MMA8451 is connected to an Arduino Uno and the Uno is connected to MATLAB by USB. The MMA8451 is definitely functioning because I can run the demo code in the Arduino with no problems. If I move the MMA8451 around, the acceleration data will get displayed in real time in the Arduino interface. 

I need to get this real time data into MATLAB though and this requires that I use the I2C protocol at a lower level of abstraction. I am wondering if anyone had any suggestions on moving forward with this. 

Sincerely,

Stanley David

Labels (1)
0 Kudos
1 Reply

686 Views
david_diaz
NXP Employee
NXP Employee

Hello David,

In this case I recommend taking a look at our Freedom Sensor Toolbox, it is designed to evaluate our accelerometers out of the box. You can use the FRDM-KL25Z to evaluate the on-board MMA8451Q device.

With its USB connectivity feature, you can interface the acceleration board with your PC thru USB and export the logged data to an Excel sheet, then you could process that data in Matlab.

pastedImage_1.png

I hope this information helps.

Regards,

David

0 Kudos