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

compiler warning: pointer from integer without a cast

Hello,

Would appreciate some understanding of a compiler warning. Developing for nRF52832 using SDK 15.3.0 plus S112.

This code compiles without warning:

ret_code_t err_code;
err_code = nrfx_ppi_channel_assign(chan_0, nrfx_gpiote_in_event_addr_get(COMPARATOR_PIN),nrfx_timer_task_address_get(&m_timer1,NRF_TIMER_TASK_START));
APP_ERROR_CHECK(err_code);

Then I switch from nrfx to sd calls:

ret_code_t err_code;
err_code = sd_ppi_channel_assign(chan_0, nrfx_gpiote_in_event_addr_get(COMPARATOR_PIN),nrfx_timer_task_address_get(&m_timer1,NRF_TIMER_TASK_START));
APP_ERROR_CHECK(err_code);

and the following warnings:

passing argument 2 of 'sd_ppi_channel_assign' makes pointer from integer without a cast [-Wint-conversion]

passing argument 3 of 'sd_ppi_channel_assign' makes pointer from integer without a cast [-Wint-conversion]

All seems to work, but would appreciate understanding the warnings.

Many thanks,

Tim

Related