This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Enable event lenght extension on sdk 1.7.0

Hi,

I am trying to enable event length extension on uart example provided on the sdk. I look for information on how to done it and i found links like that:

https://devzone.nordicsemi.com/f/nordic-q-a/22698/setting-gap-connection-event-length---ble-hrs-c-demo

https://devzone.nordicsemi.com/f/nordic-q-a/39787/verifying-connection-event-length-extension-and-data-length-extension

But on sdk 1.7.0 i am not able to do it because of there are many dependences that i can't find. On addition, is necessary to reproduce the code of links have an sttack declared and initialized on main.c, and this isn't occur on uart peripheral example.

Please if somebody could explain to me step by step what requirements i need to enable this event length extension? And there are some Kconfig to do it directly?? or is necessary to initialize the stack dinamically on main.c and pass the configuration necessary? 

I know that on nrf528xx-ble-throughput-demo this is done, butim not able to reproduce t on the actual sdk.

I will be very gratefull, 

regards.

Parents Reply
  • Hi,

    that was an usefull information, i appreciate it. But I am not able to implement a way to enable/disable extended connection events.

            sdc_hci_cmd_vs_conn_event_extend_t x={0};
    
            erri=sdc_hci_cmd_vs_conn_event_extend(&x);
            
            if(erri)printk("FALLO CON EVT LEN");
            else printk("OK EVT LEN");

    I am trying this, and the function is returning 0 always, inclusive when i pass a 2 on the argument.

    Could you tell me what is the propper way to 

    send the HCI command SDC_HCI_OPCODE_CMD_VS_CONN_EVENT_EXTEND from the BLE host to the BLE

    I am trying to follow this ticket:

    This ticket

    But on the actual ncs 1.7.0 i am not able to reproduce it. I am working with nrf52840.

    Thank you for the help and regards.

Children
  • Hi,

    I see a similar implementation on another example, could you check that this is correct?

    static int EvtLen(void)
    {       
            int err;
    	struct net_buf *buf;
    	sdc_hci_cmd_vs_conn_event_extend_t *evt_enable;
    
    	buf = bt_hci_cmd_create(SDC_HCI_OPCODE_CMD_VS_CONN_EVENT_EXTEND,
    				sizeof(*evt_enable));
    	if (!buf) {
    		printk("Could not allocate LLPM command buffer\n");
    		return -ENOMEM;
    	}
            evt_enable = net_buf_add(buf, sizeof(*evt_enable));
    	evt_enable->enable = 2;
    
    	err = bt_hci_cmd_send_sync(SDC_HCI_OPCODE_CMD_VS_CONN_EVENT_EXTEND, buf, NULL);
    	if (err) {
    		printk("Error enabling EVENT %d\n", err);
    		return err;
    	}
    
    	printk("EVENT mode enabled\n");
    	return 0;
    }

Related