I wanted to run a basic Python script to communicate with a MPL3115A2 chip on the I2C3 line from the I.MX6Q. Can anyone give me a basic example on how to do this? I am running Ubuntu on the SABRE SDB.
Hi Joseph
suggest to look at attached file and below appnote with SW examples
AN4519 AN4519, Data Manipulation and Basic Settings of the MPL3115A2
Sensor Drivers for Android, Linux and OS|Freescale
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hello igor,
Sorry for my ignorance when it comes to this. I'm new at using this processor with Linux. Do I need a .h file for this mpl3115.c file? I see on the app note that they have sample code, but they refer to many functions that I don't see. Example Below: Where can I find where IIC_Start() is defined?
IICC_TX = 1; // Transmit Mode
IIC_Start(); // Send Start
IIC_CycleWrite(address); // Send IIC "Write" Address
IIC_CycleWrite(reg); // Send Register
IIC_CycleWrite(val); // Send Value
IIC_Stop(); // Send Stop
Thanks,
Joseph