We have tons of examples that will get you going with the Bluefruit, and its really easy! Since we have one library for both wearable and non-wearable Bluefruit's, the example code is the same but may require some minor tweaks to adjust for Flora.
Most importantly, the flora bluefruit is for use with Hardware Serial only and does not have flow control pins. Also, we expect you will not use the mode pad so you can keep the switch set to CMD and then change into Data mode by sending +++ .
Configuring for Flora
For all of the examples, look near the top for a line like this:
//#define BLUEFRUIT_HWSERIAL_NAME Serial1
and remove the // comment marks. Do the same for:
//Adafruit_BluefruitLE_UART ble(BLUEFRUIT_HWSERIAL_NAME, BLUEFRUIT_UART_MODE_PIN);
Next, remove the code for the SoftwareSerial type, find these lines and delete them:
/* Create the bluefruit object, either software serial... */ SoftwareSerial bluefruitSS = SoftwareSerial(BLUEFRUIT_SWUART_TXD_PIN, BLUEFRUIT_SWUART_RXD_PIN); Adafruit_BluefruitLE_UART ble(bluefruitSS, BLUEFRUIT_UART_MODE_PIN, BLUEFRUIT_UART_CTS_PIN, BLUEFRUIT_UART_RTS_PIN);
Finally, unless you happen to be using the MODE pad, make sure BLUEFRUIT_UART_MODE_PIN is set to -1
#define BLUEFRUIT_UART_MODE_PIN -1 // Not used with FLORA
Same with RTS and CTS, find these lines and set both to -1
#define BLUEFRUIT_UART_CTS_PIN -1 // Not used with FLORA #define BLUEFRUIT_UART_RTS_PIN -1 // Not used with FLORA
Text editor powered by tinymce.