Datasheet
For both Hardware and Software SPI, you'll want to set the CS (chip select) line, IRQ (interrupt
request) line and if you have a pin to spare, RST (Reset)
Software SPI Pins
If you don't have a hardware SPI port available, you can use any three pins...its a tad slower
but very flexible
Select the Serial Bus
Once you've configured your pin setup in the BluefruitConfig.h file, you can now check and
adapt the example sketch.
The Adafruit_BluefruitLE_nRF51 library supports four different serial bus options, depending
on the HW you are using: SPI both hardware and software type, and UART both hardware
and software type.
UART Based Boards (Bluefruit LE UART Friend & Flora BLE)
This is for Bluefruit LE UART Friend & Flora BLE boards. You can use
either
software serial or
hardware serial. Hardware serial is higher quality, and less risky with respect to losing data.
However, you may not have hardware serial available! Software serial does work just fine
with flow-control and we do have that available at the cost of a single GPIO pin.
// SHARED SPI SETTINGS
#define BLUEFRUIT_SPI_CS 8
#define BLUEFRUIT_SPI_IRQ 7
#define BLUEFRUIT_SPI_RST 4 // Optional but recommended, set to -1 if unused
// SOFTWARE SPI SETTINGS
#define BLUEFRUIT_SPI_SCK 13
#define BLUEFRUIT_SPI_MISO 12
#define BLUEFRUIT_SPI_MOSI 11
Refer to the table above to determine whether you have SPI or UART controlled
Bluefruits!
© Adafruit Industries https://learn.adafruit.com/adafruit-feather-m0-bluefruit-le Page 69 of 238










