This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Interfacing GY-68 with nrf52840

Hello,I am new to this field.I dont know how to interface GY-68 with nrf52840 and read the temperature,pressure and altitude readings.

Parents Reply Children
  • Hi,I have gone through datasheet of the sensors(LM75B and BMP180).In twi_sensor code,I have done the following changes:

    #define BMP180_ADDR (0x77U >> 1)

    #define BMP180_REG_OUT_XLSB     0xF8
    #define BMP180_REG_OUT_LSB        0xF7
    #define BMP180_REG_OUT_MSB       0xF6
    #define BMP180_REG_CTRL_MEAS   0xF4
    #define BMP180_REG_SOFT_RESET  0xE0
    #define BMP180_REG_ID                      0xD0
    #define BMP180_REG_CALIB_START 0xAA


    /* Mode for BMP180. */
    #define STD_MODE 1U.

    From the above defined,I used  BMP180_REG_CTRL_MEAS in the place of LM75B_REG_TEMP and BMP180_REG_OUT_XLSB in place of LM75B_REG_CONF.I have used standard mode with value 1U. Is this correct???

    After modification,I can able to build the application but while loading,shows "ERROR FLASH DOWNLOAD FAILED".

    Can anyone help me out

     

  • That could work, I have not tried this sensor so I can't really answer that. If you are able to build but not flash, please try erasing the board using nrfjprog or nRF Connect Programming app.

Related