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

scheduler and struct

Hi,

I would like to save some data from characteristic into the Flash. Due to this fact I decided that I will use scheduler. When the value of actual characteristic is changed the writing event handler triggers the following event handler

static void name_write_handler(ble_infs_t *p_infs,  ble_srv_utf8_str_t name)
{		
	
	app_sched_event_put(&name, sizeof(name),scheduler_name_flash_handler);
	
	
}

which is defined in one of my service. Then the scheduler is called by scheduler_name_flash_handler function which is defined as

void scheduler_name_flash_handler(void *p_event_data, ble_srv_utf8_str_t name)
{
}

Maybe it is worth mentioning that ble_srv_utf8_str_t is structure by the following body

typedef struct
{
    uint16_t  length;                                   /**< String length. */
    uint8_t * p_str;                                    /**< String data. */
} ble_srv_utf8_str_t;

I do not know why i get warning incompatible pointer type. I will be really grateful for any help.

Best regards

Samo

Related