iOS & OSX Bluetooth library for RxSwift
bartoszstelmaszuk Merge pull request #294 from Polidea/refactor/canSnadWriteWithoutResp…
…onse

move availability check inside getter for canSendWriteWithoutResponse
Latest commit 97fe2b6 Oct 5, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github/ISSUE_TEMPLATE Update issue templates Jun 22, 2018
ExampleApp Remove smart quotes from Podfile Sep 23, 2018
RxBluetoothKit.xcodeproj Change back to iOS deployment target 8.0 Jun 29, 2018
Source move availability check inside getter for canSendWriteWithoutResponse Oct 5, 2018
Templates Added documentation for `CBPeripheralManager` May 22, 2018
Tests move availability check inside getter for canSendWriteWithoutResponse Oct 5, 2018
docs version 5.1.4 Sep 21, 2018
scripts move availability check inside getter for canSendWriteWithoutResponse Oct 5, 2018
.gitignore Changes to documentation: (#203) Jan 15, 2018
.jazzy.yaml Moved documentation to docs, which is required for github pages Jul 3, 2018
.swift-version Updated swift-version file to reflect 4.0 version Oct 24, 2017
.swiftlint.yml - added all API for PeripheralManager May 18, 2018
.travis.yml Updated ios simulator version for travis ci builds Apr 10, 2018
CHANGELOG.md version 5.1.4 Sep 21, 2018
CONTRIBUTING.md Create CONTRIBUTING.md Jul 2, 2018
Cartfile Support Swift 4 and RxSwift4. Sep 26, 2017
Cartfile.private New testing architecture (#200) Jan 10, 2018
Cartfile.resolved updated version of RxSwift to 4.3.1 Oct 2, 2018
HOW_TO_RELEASE.md Version 5.1.2 Jun 21, 2018
LICENSE Changed license to Apache License, Version 2.0 (#221) Mar 13, 2018
Package.swift Swift Package Manager Support (#159) Oct 20, 2017
README.md Readme Typo Fix Aug 22, 2018
RxBluetoothKit.podspec version 5.1.4 Sep 21, 2018

README.md

RxBluetoothKit Swift

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

5.1.2

  • Updated RxSwift to 4.2 with support for XCode 9.4 (#268)

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!

Requirements

  • iOS 8.0+
  • OSX 10.10+
  • watchOS 4.0+
  • tvOS 11.0+
  • Xcode 7.3+

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