Apologies for asking a question that is quite similar to several that I've found on this forum, however none of the solutions has worked for me so I think something else must be up...
I'm trying to add TWI slave functionality to an existing ble project, and I'm basing it off the twi_master_with_twis_slave_pca10040 in the SDK 17.0.0.
I've added the following files to the nRF_Drivers folder: nrf_drv_twi.c, nrfx_twi.c and nrfx_twis.c.
In sdk_config.h, I have set NRFX_TWIS_ENABLED, NRFX_TWIS1_ENABLED, NRFX_TWI_ENABLED and NRFX_TWI1_ENABLED and have left the legacy drivers (TWI_ENABLED, TWIS_ENABLED) unchecked - this is what I understood to be correct for previous similar forum posts.
When I try to build the project, the following error is returned from the line
ret_code_t ret = nrf_drv_twis_init(&m_twis, &config, twis_event_handler);
main.c:959: undefined reference to `nrfx_twis_init'
When I look at the nrfx_twis.c file where nrfx_twis_init should be defined, everything below the line
#if NRFX_CHECK(NRFX_TWIS_ENABLED)
is greyed out, suggestion that NRFX_TWIS_ENABLED is not defined, although I have set it in sdk_config.h. This sounds similar to the problems previous users have discussed here regarding the legacy layers - however when I open apply_old_config.h, this whole file is greyed out also, which suggests that this is not the cause of the undefining of NRFX_TWIS_ENABLED.
Apologies for the longwinded question - just trying to ensure I've got all the details in here...
I'd very much appreciate some guidance, either on how to navigate this deeply confusing legacy layer, or how to set up a TWI slave using only the new non-legacy drivers (I did also attempt this but ran into all sorts of trouble, possibly because there are other legacy drivers already in use in the project?)
Thanks in advance!