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

SDK13 can not find sdk_config.h

Hi,

I am trying to add saadc sample code to ble_blinky sample code. But I faced a problem. It seems that the sdk_config.h file is not recognized by the sample code. and I got this errors:

"TIMER_DEFAULT_CONFIG_FREQUENCY" is undefined "TIMER_DEFAULT_CONFIG_MODE" is undefined "TIMER_DEFAULT_CONFIG_BIT_WIDTH" is undefined "TIMER_DEFAULT_CONFIG_IRQ_PRIORITY" is undefined

I am using SDK13 sample codes, on nRF52840-PDK.

Could you please let me know about possible ways to solve the problem?

Thank you, Leila

Parents
  • Thank you. The problem is solved. Another question regarding to add saadc sample code to ble_blinky; do they have the same resource? I mean they both use the same timer or so on?

    Because finally I could Make it without any errors but doesn't work efficiently. It stocks at saadc_sampling_event_init() function and get me back ":ERROE:Fatal" on serial port.

    int main(void)
    {
        // Initialize.
        leds_init();
        timers_init();
        log_init();
        buttons_init();
        ble_stack_init();
        gap_params_init();
        gatt_init();
        services_init();
        advertising_init();
        conn_params_init();
          //*
        //---------SAADC----------
        //uint32_t err_code;
    //    err_code = nrf_drv_power_init(NULL);
    //    APP_ERROR_CHECK(err_code);
    
    //    ret_code_t ret_code = nrf_pwr_mgmt_init();
    //    APP_ERROR_CHECK(ret_code);
    
        NRF_LOG_INFO("SAADC HAL simple example.\r\n");
        saadc_init();
        saadc_sampling_event_init();
        saadc_sampling_event_enable();
        ////---------SAADC----------
        //*/
        // Start execution.
        NRF_LOG_INFO("Blinky BLE_ADC example started.\r\n");
        advertising_start();
    
        // Enter main loop.
        for (;;)
        {
          
            ///---------SAADC----------
          //*
            if(m_saadc_calibrate == true)
            {
                NRF_LOG_INFO("SAADC calibration starting...  \r\n");    //Print on UART
                while(nrf_drv_saadc_calibrate_offset() != NRF_SUCCESS); //Trigger calibration task
                m_saadc_calibrate = false;
            }
            //*/
    //        nrf_pwr_mgmt_run();
    //        NRF_LOG_FLUSH();
          
            ////---------SAADC----------
            
            if (NRF_LOG_PROCESS() == false)
            {
                power_manage();
            }
        }
    }
    
Reply
  • Thank you. The problem is solved. Another question regarding to add saadc sample code to ble_blinky; do they have the same resource? I mean they both use the same timer or so on?

    Because finally I could Make it without any errors but doesn't work efficiently. It stocks at saadc_sampling_event_init() function and get me back ":ERROE:Fatal" on serial port.

    int main(void)
    {
        // Initialize.
        leds_init();
        timers_init();
        log_init();
        buttons_init();
        ble_stack_init();
        gap_params_init();
        gatt_init();
        services_init();
        advertising_init();
        conn_params_init();
          //*
        //---------SAADC----------
        //uint32_t err_code;
    //    err_code = nrf_drv_power_init(NULL);
    //    APP_ERROR_CHECK(err_code);
    
    //    ret_code_t ret_code = nrf_pwr_mgmt_init();
    //    APP_ERROR_CHECK(ret_code);
    
        NRF_LOG_INFO("SAADC HAL simple example.\r\n");
        saadc_init();
        saadc_sampling_event_init();
        saadc_sampling_event_enable();
        ////---------SAADC----------
        //*/
        // Start execution.
        NRF_LOG_INFO("Blinky BLE_ADC example started.\r\n");
        advertising_start();
    
        // Enter main loop.
        for (;;)
        {
          
            ///---------SAADC----------
          //*
            if(m_saadc_calibrate == true)
            {
                NRF_LOG_INFO("SAADC calibration starting...  \r\n");    //Print on UART
                while(nrf_drv_saadc_calibrate_offset() != NRF_SUCCESS); //Trigger calibration task
                m_saadc_calibrate = false;
            }
            //*/
    //        nrf_pwr_mgmt_run();
    //        NRF_LOG_FLUSH();
          
            ////---------SAADC----------
            
            if (NRF_LOG_PROCESS() == false)
            {
                power_manage();
            }
        }
    }
    
Children
No Data
Related