• Stars
    star
    1,408
  • Rank 33,405 (Top 0.7 %)
  • Language
    Swift
  • License
    Apache License 2.0
  • Created over 8 years ago
  • Updated 9 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

iOS & OSX Bluetooth library for RxSwift

RxBluetoothKit library logo

CI Status Platform Carthage Compatible

RxBluetoothKit is a Bluetooth library that makes interaction with BLE devices much more pleasant. It's backed by RxSwift and CoreBluetooth and it provides nice API, for both Central and Peripheral modes. All to work with and make your code more readable, reliable and easier to maintain.

Here is a sneak peek of what you can do with RxBluetoothKit:

manager.scanForPeripherals(withServices: [serviceId])
    .take(1)
    .flatMap { $0.peripheral.establishConnection() }
    .flatMap { $0.discoverServices([serviceId]) }
    .flatMap { Observable.from($0) }
    .flatMap { $0.discoverCharacteristics([characteristicId]) }
    .flatMap { Observable.from($0) }
    .flatMap { $0.readValue() }
    .subscribe(onNext: { print("Value: \($0.value)") })

With just 9 lines it started scanning, connecting to the peripheral, discovering service and characteristics and read charecteristic's value!

Central mode features

Peripheral mode features

  • Observing manager states
  • Advertising
  • Observing read & writes
  • Observing subscribe
  • Publishing L2CAP channels
  • And a lot more!

Recent Changes

6.0.0

  • Increased deployment target for iOS to 9.0 and for osx to 10.13 (#379, #380)
  • Added support for observing ancsAuthorized property on peripheral. (#370)
  • Added Bluetooth usage description to Info.plist in Example project (#369)
  • Added initial state improvement & a minor fix for BluetoothState methods. (#371)
  • Fixed problems with SPM support (#358, #368)
  • Updated RxSwift version to 5.1 (#376)
  • Updated project configurations to decrease build time on TravisCI (#376)
  • Updated scripts to fixed problems with generating mocks (#378)

All previous changes

Want to migrate from 4.x to 5.x? Check guidelines here.

Installation

CocoaPods

CocoaPods is a dependency manager for CocoaProjects. To integrate RxBluetoothKit into your Xcode project using CocoaPods specify it in your Podfile:

pod 'RxBluetoothKit'

Then, run the following command: $ pod install

Carthage

Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks. To integrate RxBluetoothKit into your Xcode project using Carthage specify it in your Cartfile:

github "Polidea/RxBluetoothKit"

Then, run carthage update to build framework and drag RxBluetoothKit.framework into your Xcode project.

Swift Package Manager

Versions >= 4.0 of the library integrate with the Swift Package Manager. In order to do that please specify our project as one of your dependencies in Package.swift file.

Getting Started

Check our Wiki with guidelines to (almost) all library functionalites.

Documentation & Support

Remember to follow Polidea's Blog blog to get all the news and updates!

Contact us

Learn more about Polidea's BLE services here.

Requirements

  • iOS 9.0+
  • OSX 10.13+
  • watchOS 4.0+
  • tvOS 11.0+
  • Xcode 11.4+

Swift versions

  • 3.0 version supports Swift 3.0 and 3.1
  • 5.0 version supports Swift 3.2 and 4.0
  • 5.1.2 version supports Swift 4.1
  • 5.2 version supports Swift 5.0 and 4.2

More Repositories

1

SiriusObfuscator

C++
467
star
2

cmake-nRF5x

cmake script for nRF5 series SoC
C
121
star
3

Cockpit

Easily define a set of parameters that can be accessed and changed by the developers via built-in compact UI at runtime.
Kotlin
119
star
4

android-hierarchy-viewer

HTML
113
star
5

Cellular-Data-Network-Simulator

Webapp to monitor network usage and simulate network link conditions
Shell
100
star
6

tree-view-list-android

Provide configurable tree view list for android devices
Java
82
star
7

android-zoom-view

Android zooming view
Java
76
star
8

blemulator_flutter

BLEmulator Flutter: the Flutter BLE peripheral simulator
Dart
73
star
9

android-coverflow

Simple implementation of android's cover flow widget.
Java
68
star
10

basset-ios

Converting vector based images to iOS-style PNG(s) tool that organizes them in XCode Assets
Python
53
star
11

state-machine-android

A lightweight state machine implementation for Android.
Java
24
star
12

SOCK

Simple Omitter of Conflicts Kit - tool that prevents some of merge conflicts in .pbxproj file in Xcode projects
Python
23
star
13

the-missing-android-xml-junit-test-runner

Test runner that produces standard junit XML output file
Java
22
star
14

PLVisualAttributeConstraints

Custom VFL (Visual Format Language) for creating NSLayoutConstraint's. Offers more readable and concise replacement for constraintWithItem:attribute:relatedBy:toItem:attribute:multiplier:constant: (NSLayoutConstraint, AutoLayout mechanism)
Objective-C
22
star
15

react-native-blemulator

BLE simulator for react-native-ble-plx
TypeScript
20
star
16

Health2Fitbit

Simple tool that exports steps from HealthKit (eg. from Apple Watch) to Fitbit
Objective-C
17
star
17

android-section-list

Provides implementation of list which is divided to sections
Java
15
star
18

AndroidImageCache

LRU based Bitmap cache for Android. In Addition WebImageView for loading images from web resources.
Java
15
star
19

Polithings

Set of drivers for Android Things
Kotlin
14
star
20

better-gesture-detector

Android gesture detector better than default one
Java
13
star
21

SiriusObfuscator-SymbolExtractorAndRenamer

C++
11
star
22

ResourceSweeper

Python
11
star
23

PLObservers

Small tool for fast implementation of multi-observer pattern in Objective-C
Objective-C
9
star
24

android-image-manager

Image manager for android applications.
Java
8
star
25

recycler-view-adapters

A set of RecyclerView adapters, that are adding some great new features.
Java
8
star
26

android-flip3d

Android widget that allows for 3D-flipping of alternate views
Java
7
star
27

PLCoreDataUtils

A set of helper methods for CoreData
Objective-C
6
star
28

PLImageManager

image manager/downloader for iOS
Objective-C
6
star
29

Shuttle-Backend

Shuttle makes easy, secure and fast mobile apps distribution possible. It allows delivering iOS and Android mobile applications to stakeholders from the very beginning of the cooperation with the app creators. To try out our solution, simply use our code and if you need frontend and mobile app β€” contact us directly!
Groovy
6
star
30

at_candle

Example of candle powered by Android Things
Kotlin
4
star
31

android-notification-utils

Small set of utilities used by Polidea to develop android notifications
Java
4
star
32

PLColors

Objective-C library to create UIColor/NSColor objects based on the HEX color representation.
Objective-C
4
star
33

SiriusObfuscator-FileExtractor

Ruby
4
star
34

SiriusObfuscator-VerificationSuite

Swift
4
star
35

PLXCoreBluetooth-RACExtensions

Reactive Cocoa Extensions to CoreBluetooth
Objective-C
4
star
36

PLXFrameLayout

AutoLayout on frames
Objective-C
3
star
37

android-menu-navigator

Build navigation from json menu description
Java
3
star
38

dag-checks

The dag-checks consist of checks that can help you in maintaining your Apache Airflow instance.
Python
3
star
39

PLXImageManager

Image manager/downloader for iOS
Objective-C
2
star
40

mce-heatmap

Heatmap from MCE
JavaScript
1
star
41

PIXIE

Firmware for beautiful PIXIE device.
C++
1
star
42

docker-101

Example Docker project to help you bootstrap your awesome apps.
CSS
1
star
43

PLXColors

Objective-C library to create UIColor/NSColor objects based on the HEX color representation.
Objective-C
1
star
44

FrameLayout

AutoLayout on frames. This repo has been moved to
Objective-C
1
star
45

PLXObservers

Small tool for fast implementation of multi-observer pattern in Objective-C
Objective-C
1
star
46

PLXVisualAttributeConstraints

Custom VFL (Visual Format Language) for creating NSLayoutConstraint's. Offers more readable and concise replacement for constraintWithItem:attribute:relatedBy:toItem:attribute:multiplier:constant: (NSLayoutConstraint, AutoLayout mechanism)
Objective-C
1
star