{"id":21586160,"url":"https://github.com/mmmagiccoder/bluetoothpulse","last_synced_at":"2026-02-25T23:33:39.751Z","repository":{"id":232818956,"uuid":"785268980","full_name":"MMMagicCoder/BluetoothPulse","owner":"MMMagicCoder","description":"📲 BluetoothPulse is a versatile and powerful tool designed to simplify Bluetooth integration in SwiftUI applications. Developed with a focus on usability and flexibility, this module empowers developers to seamlessly incorporate Bluetooth functionality into their SwiftUI projects across various Apple platforms.","archived":false,"fork":false,"pushed_at":"2024-04-20T16:44:48.000Z","size":94,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-03T21:32:43.058Z","etag":null,"topics":["ble","bluetooth","bluetooth-low-energy","cbcharacteristic","cbperipheral","cbservice","centralmanager","characteristics","core-bluetooth","ios","library","peripheral","service","swift","swift-package-manager","swift-ui","swiftui","xcode"],"latest_commit_sha":null,"homepage":"","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MMMagicCoder.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-04-11T14:43:52.000Z","updated_at":"2024-08-09T04:31:46.000Z","dependencies_parsed_at":"2024-11-24T18:00:36.799Z","dependency_job_id":null,"html_url":"https://github.com/MMMagicCoder/BluetoothPulse","commit_stats":null,"previous_names":["mmmagiccoder/bluetoothpulse"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MMMagicCoder%2FBluetoothPulse","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MMMagicCoder%2FBluetoothPulse/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MMMagicCoder%2FBluetoothPulse/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MMMagicCoder%2FBluetoothPulse/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MMMagicCoder","download_url":"https://codeload.github.com/MMMagicCoder/BluetoothPulse/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252308171,"owners_count":21727136,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ble","bluetooth","bluetooth-low-energy","cbcharacteristic","cbperipheral","cbservice","centralmanager","characteristics","core-bluetooth","ios","library","peripheral","service","swift","swift-package-manager","swift-ui","swiftui","xcode"],"created_at":"2024-11-24T15:12:50.118Z","updated_at":"2026-02-25T23:33:34.725Z","avatar_url":"https://github.com/MMMagicCoder.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"# BluetoothPulse\n\n ![](https://img.shields.io/badge/platform-iOS-d3d3d3) ![](https://img.shields.io/badge/iOS-15.0%2B-43A6C6) ![](https://img.shields.io/badge/Swift-5-F86F15)\n\nThis library contains a SwiftUI Bluetooth Module designed to facilitate Bluetooth connectivity within SwiftUI apps. Whether you're building an iOS, macOS app, this module provides a comprehensive solution for integrating Bluetooth functionality seamlessly into your SwiftUI project.\n\n#### Features:\n  - Connection Status Tracking: Monitor the status of Bluetooth connections with clear and concise enums, facilitating easy handling of various connection states.\n  - Peripheral Discovery: Discover nearby Bluetooth peripherals and retrieve relevant information such as local name, advertisement data, and signal strength.\n  - Peripheral Connection: Establish connections with Bluetooth peripherals and handle connection events seamlessly.\n  - Service and Characteristic Discovery: Discover services and characteristics of connected peripherals for data exchange.\n  - SwiftUI Integration: Designed for use within SwiftUI applications, ensuring a smooth and native-like user experience.\n\n## Table of contents\n   - [Requirements](#requirements)\n   - [Installation](#installation)\n     - [Swift Package Manager (SPM)](#spm)\n   - [Usage](#usage)\n   - [Contribution](#contribution)\n   - [License](#license)\n\n## Requirements\n\u003ca id=\"requirements\"\u003e\u003c/a\u003e\n   - SwiftUI\n   - iOS 15.0 or above\n\n## Installation\n\u003ca id=\"installation\"\u003e\u003c/a\u003e\nYou can access Tabfinity through [Swift Package Manager](https://github.com/apple/swift-package-manager).\n### Swift Package Manager (SPM)\n\u003ca id=\"spm\"\u003e\u003c/a\u003e\nIn xcode select:\n```\nFile \u003e Swift Packages \u003e Add Package Dependency...\n```\nThen paste this URL:\n```\nhttps://github.com/MMMagicCoder/BluetoothPulse.git\n```\n\n## Usage\n\n\u003ca id=\"usage\"\u003e\u003c/a\u003e\n\n- Initialization: Create an instance of BluetoothModule to start managing Bluetooth connections.\n\n```swift\nlet bluetoothModule = BluetoothModule()\n```\n\n- Scan for Peripherals: Start scanning for nearby peripherals using the startScan() method.\n```swift\nbluetoothModule.startScan()\n```\n\n- Connect to a Peripheral: Initiate a connection to a discovered peripheral by calling connectPeripheral(_:) method with the selected peripheral.\n```swift\nbluetoothModule.connectPeripheral(selectedPeripheral)\n```\n\n- Access Connected Peripheral: Access the currently connected peripheral through the connectedPeripheral variable.\n```swift\nlet connectedPeripheral = bluetoothModule.connectedPeripheral\n```\n\n- Discover Peripherals, Services, and Characteristics: Access the discovered peripherals, services, and characteristics through the corresponding variables.\n```swift\nlet discoveredPeripherals = bluetoothModule.discoverPeripherals\nlet discoveredServices = bluetoothModule.discoverServices\nlet discoveredCharacteristics = bluetoothModule.discoverCharacteristics\n```\n\nOther useful functionalities include:\n\n- Stop Scanning: Halt the scanning process for nearby peripherals using the stopScan() method.\n```swift\nbluetoothModule.stopScan()\n```\n\n- Disconnect from a Peripheral: Terminate the connection with the currently connected peripheral using the disconnectPeripheral() method.\n```swift\nbluetoothModule.disconnectPeripheral()\n```\n\n## Contribution\n\u003ca id=\"contribution\"\u003e\u003c/a\u003e\nIf you encounter any challenges, please feel free to [open an issue](https://github.com/MMMagicCoder/bluetoothPulse/issues/new). Additionally, we welcome and appreciate pull requests for any improvements or contributions.\n\n## License\n\u003ca id=\"license\"\u003e\u003c/a\u003e\nbluetoothPulse is under the terms and conditions of the MIT license.\n```\nMIT License\n\nCopyright (c) 2024 Mohammad Mahdi Moayeri\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmmagiccoder%2Fbluetoothpulse","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmmmagiccoder%2Fbluetoothpulse","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmmmagiccoder%2Fbluetoothpulse/lists"}