Introduction
Welcome to the BluetoothSerial library documentation. This library offers an effortless method to establish Bluetooth connections between your Arduino project and your iOS app. In this documentation, we'll guide you through the initial setup, provide a comprehensive overview of the library's capabilities, and assist you in achieving seamless communication between devices.
Getting Started
Before diving into the implementation details, ensure you have the following prerequisites:
Prerequisites
- Arduino IDE: Make sure you have the Arduino IDE installed.
- BluetoothSerial Library: Download the latest release of the BluetoothSerial library from our GitHub repository.
- iOS App: Ensure your iOS device has our companion app installed (link provided).
- Compatible Bluetooth Module: While a comprehensive list of compatible modules can be found here, common modules include the HC-05, HC-06, and ESP32.
Installation
- Open the Arduino IDE.
- Navigate to Sketch > Include Library > Add .ZIP Library...
- Locate and select the downloaded
BluetoothSerial.zip
file. - Ensure the library has been added by checking Sketch > Include Library for the
BluetoothSerial
entry.
Library Overview
The BluetoothSerial
library consists of two primary classes:
- BluetoothSerial: Manages the Bluetooth communication, handling tasks like reading/writing messages, sending alerts, and managing connected devices.
- BluetoothSerialJoystick: Represents a joystick's state, with functionalities to retrieve joystick position and rotation in various formats.
For detailed explanations and examples of each class and function, navigate to the API Reference section.
Next Steps
- Hello World Tutorial: Start with the Hello World tutorial to establish a basic connection and send "Hello, World!" from your Arduino to the iOS app.
- Compatible Bluetooth Chips: Check out our list of known supported Bluetooth chips and modules. Note: it is not an exhaustive list, and many more chips likely work as well.
- API Reference: Dive deep into each class, function, and method available in the library in our API Reference section.
We hope this documentation provides clarity on using the BluetoothSerial library. Happy coding!