I am trying to use gcc to compile a c++ code for nRF52. I am using the TWI library and am getting the error below. Can anyone help me rewriting this macro so that it compiles normally ?
Compiling file: main.cpp
In file included from main.cpp:6:0:
../nRF5_SDK_11.0.0_89a8197/components/drivers_nrf/twi_master/nrf_drv_twi.h:91:1: error: invalid conversion from 'void*' to 'NRF_TWIM_Type*' [-fpermissive]
}
^
main.cpp:28:40: note: in expansion of macro 'NRF_DRV_TWI_INSTANCE'
static const nrf_drv_twi_t m_twi_GPS = NRF_DRV_TWI_INSTANCE(0);