Overview
A React Native SDK for connecting to and interacting with Omi devices via Bluetooth Low Energy (BLE). Build cross-platform mobile apps for iOS and Android.Cross-Platform
iOS and Android support
BLE Connection
Bluetooth Low Energy
Real-time Audio
Stream and transcribe
Features
- Scan for nearby Omi devices
- Connect to Omi devices
- Get device audio codec information
- Stream audio data from the device
- Monitor battery levels
- Handle connection state changes
- Real-time audio transcription using Deepgram
Installation
In Your Project
Platform-Specific Setup
- iOS
- Android
Add to your
Info.plist:Development Setup
1
Clone and Install
2
Set Up Example App
3
Install iOS Pods
This step is crucial. Without it, the app will fail to build with native module errors.
4
Run the App
- iOS
- Android
Quick Start
API Reference
OmiConnection Methods
| Method | Description | Returns |
|---|---|---|
scanForDevices(onDeviceFound, timeoutMs) | Scan for nearby Omi devices | Function to stop scanning |
connect(deviceId, onConnectionStateChanged) | Connect to an Omi device | Promise<boolean> |
disconnect() | Disconnect from current device | Promise<void> |
isConnected() | Check connection status | boolean |
getAudioCodec() | Get device audio codec | Promise<BleAudioCodec> |
startAudioBytesListener(callback) | Start receiving audio bytes | Promise<Subscription> |
stopAudioBytesListener(subscription) | Stop receiving audio bytes | Promise<void> |
getBatteryLevel() | Get battery percentage | Promise<number> |
Types
- OmiDevice
- DeviceConnectionState
- BleAudioCodec
Troubleshooting
Build fails with native module errors on iOS
Build fails with native module errors on iOS
- Ensure you’ve run
pod installin the ios directory - Try cleaning the build folder: Product → Clean Build Folder
- Make sure you’re opening the
.xcworkspacefile, not.xcodeproj
Device not found during scanning
Device not found during scanning
- Ensure Bluetooth is enabled on your device
- Check that you have the necessary permissions
- Make sure the Omi device is powered on and in range
- Bluetooth scanning doesn’t work in iOS simulators - use a physical device
Connection fails
Connection fails
- Try restarting the Omi device
- Ensure the device is not connected to another application
- Check the battery level of the Omi device
Audio data not received
Audio data not received
- Verify that the device supports the audio service
- Check that you’re properly handling the audio bytes in your callback
Transcription not working
Transcription not working
- Ensure you have a valid Deepgram API key
- Check that the audio listener is started before enabling transcription
- Verify your internet connection is stable
Keyboard overlaps input fields
Keyboard overlaps input fields
The example app includes padding at the bottom of the ScrollView to ensure input fields remain visible when the keyboard is open.