2015-04-11 09:07 AM
Hi everybody,
Using IAR for ARM v7.40.8472.
I just purchased a STM32F401C-DISCO (also called 32F401CDISCOVERY or MB1115B).When using the demonstration code provided by ''STM32F401 discovery firmware package (UM1660)'', the LSM303DLHC is working and I can get sensor values.However, when I use the demonstration code provided by ''STM32CubeF4 v1.5'', the LSM303DLHC won't return the I_AM_LMS303DLHC register.Needless to say that I have not modified the code at all.I am really interested in using the STM32F4CUBE HAL driver but I have no experience yet.I was wondering if anybody had the same issue and fixed it, or if another code exists that uses the LSM303DLHC sensor and the STM32F4CUBE HAL driver with the STM32F401C-DISCO?Please let me know if you need additional information?Eric #stm32f401c-disco-lsm303dlhc-hal2015-04-11 10:56 AM
Do the two demonstration code examples use the same microprocessor pins?
Cheers, Hal2015-04-11 06:44 PM
The pinout to the accelerometer is the same on both demo code.
Again, I have not touched the code, so I am really surprised...I will be running the board on the oscilloscope tomorrow to find out.2015-04-21 01:35 AM
Hi,
I think you can compare the working codes with the non-working one so that it is faster to find out the cause. If LSM303DLHC is not responding that means the I2C communication is not properly setup or the device address is wrong.