The Central mode API is accessible via Bluefruit.Central.*
and has the following public functions:
void begin(void); /*------------------------------------------------------------------*/ /* GAP *------------------------------------------------------------------*/ bool setConnInterval(uint16_t min, uint16_t max); bool setConnIntervalMS (uint16_t min_ms, uint16_t max_ms); bool connect(const ble_gap_evt_adv_report_t* adv_report); bool connect(const ble_gap_addr_t *peer_addr); bool disconnect(uint16_t conn_handle); bool connected (uint16_t conn_handle); // If connected to a specific peripheral bool connected (void); // If connected to any peripherals /*------------- Callbacks -------------*/ void setConnectCallback ( BLEGap::connect_callback_t fp); void setDisconnectCallback( BLEGap::disconnect_callback_t fp);
For examples of how to use the Central mode API, see the Central examples folder.
Text editor powered by tinymce.