{"id":28615516,"url":"https://github.com/siliconlabssoftware/web-bluetooth-spp-application","last_synced_at":"2025-06-12T02:09:16.342Z","repository":{"id":277145038,"uuid":"930286367","full_name":"SiliconLabsSoftware/web-bluetooth-spp-application","owner":"SiliconLabsSoftware","description":"Web Bluetooth Serial Port Profile (SPP) example application.","archived":false,"fork":false,"pushed_at":"2025-02-12T10:50:05.000Z","size":691,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-02-12T11:46:02.064Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SiliconLabsSoftware.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2025-02-10T11:43:29.000Z","updated_at":"2025-02-12T10:48:53.000Z","dependencies_parsed_at":"2025-02-12T11:46:11.518Z","dependency_job_id":"af75e4ee-5259-403b-82ac-13f7222382bc","html_url":"https://github.com/SiliconLabsSoftware/web-bluetooth-spp-application","commit_stats":null,"previous_names":["siliconlabssoftware/web-bluetooth-spp-application"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/SiliconLabsSoftware/web-bluetooth-spp-application","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SiliconLabsSoftware%2Fweb-bluetooth-spp-application","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SiliconLabsSoftware%2Fweb-bluetooth-spp-application/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SiliconLabsSoftware%2Fweb-bluetooth-spp-application/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SiliconLabsSoftware%2Fweb-bluetooth-spp-application/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SiliconLabsSoftware","download_url":"https://codeload.github.com/SiliconLabsSoftware/web-bluetooth-spp-application/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SiliconLabsSoftware%2Fweb-bluetooth-spp-application/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259382323,"owners_count":22848842,"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":[],"created_at":"2025-06-12T02:09:10.731Z","updated_at":"2025-06-12T02:09:16.308Z","avatar_url":"https://github.com/SiliconLabsSoftware.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Web Bluetooth - Serial Port Profile (SPP) Example\n[![Version Badge](https://img.shields.io/badge/v1.0.0-green)](https://github.com/SiliconLabsSoftware/web-bluetooth-spp-application/releases)\n\n## Overview\n\nThis example application implements the client-side device for the [Bluetooth - Serial Port Profile (SPP)](https://github.com/SiliconLabs/bluetooth_applications/tree/master/bluetooth_serial_port_profile) and [Bluetooth - Secure Serial Port Profile (SPP)](https://github.com/SiliconLabs/bluetooth_applications/tree/master/bluetooth_secure_spp_over_ble) application examples and provides an example to communicate Silicon Labs wireless microcontrollers using the BLE protocol from the Web Bluetooth API [compatible browsers](https://developer.mozilla.org/en-US/docs/Web/API/Web_Bluetooth_API#browser_compatibility).\n\n\n![Overview](./docs/overview.png)\n\nThe application runs in the browser as a Single Page Application (SPA) without requiring any server-side connection. \n\n![Screenshot](./docs/screenshot.png)\n\n\u003e [!TIP]\nCheck out the live demo online: [https://siliconlabssoftware.github.io/web-bluetooth-spp-application/](https://siliconlabssoftware.github.io/web-bluetooth-spp-application/)\n\n## Compatible Bluetooth SPP Application Examples\n- [Bluetooth - Serial Port Profile (SPP)](https://github.com/SiliconLabs/bluetooth_applications/tree/master/bluetooth_serial_port_profile)\n- [Bluetooth - Secure Serial Port Profile (SPP)](https://github.com/SiliconLabs/bluetooth_applications/tree/master/bluetooth_secure_spp_over_ble)\n\n## Requirements\n- Install [Nodejs \u003e= v22.14.0 LTS](https://nodejs.org/en/download) \n- Prepare and flash a development kit with one of the [supported application examples](#compatible-bluetooth-spp-application-examples).\n\n## Getting Started: Run the Application Locally\n\n 1. Go to [project-root-folder]\n 2. Open a Terminal/Cmd/PowerShell/Bash there\n 3. Install the dependencies and run the application with the following commands\n    ```bash\n    # install all dependencies\n    $ npm install\n\n    # development\n    $ npm run dev\n\n    # production mode\n    $ npm run build\n    $ npm run preview\n    ```\n 4. Open the application in a web browser\n\u003e [!NOTE]  \n\u003e The local address of the application is displayed in the console once the server is up and ready to process the requests.\n     \n## Features\n\nThis example application comes with the following features:\n\n- [React](https://react.dev/)\n- [Mantine](https://mantine.dev/)\n- [PostCSS](https://postcss.org/) with [mantine-postcss-preset](https://mantine.dev/styles/postcss-preset)\n- [TypeScript](https://www.typescriptlang.org/)\n- [Vitest](https://vitest.dev/) setup with [React Testing Library](https://testing-library.com/docs/react-testing-library/intro)\n- ESLint setup with [eslint-config-mantine](https://github.com/mantinedev/eslint-config-mantine)\n\n## npm scripts\n\n### Build and dev scripts\n\n- `dev` – start development server\n- `build` – build production version of the app\n- `preview` – locally preview production build\n- `deploy` - deploys the application to the GitHub pages\n\n### Testing scripts\n\n- `typecheck` – checks TypeScript types\n- `lint` – runs ESLint\n- `prettier:check` – checks files with Prettier\n- `vitest` – runs vitest tests\n- `vitest:watch` – starts vitest watch\n- `test` – runs `vitest`, `prettier:check`, `lint` and `typecheck` scripts\n\n### Other scripts\n\n- `prettier:write` – formats all files with Prettier\n\n## Troubleshooting\n\nSometimes, when the application runs in Chrome Android and tries to pair and connect to a new device, the application cannot retrieve the GATT Service. To solve this issue, try to Unpair/Pair/Unpair the device in the Bluetooth settings. \n\n\u003e [!IMPORTANT]  \n\u003e The device should be unpaired first to pair and connect via the application.\n\n\n## Reporting Bugs/Issues and Posting Questions and Comments\n\nTo report bugs in the Application Examples projects, please create a new \"Issue\" in the \"Issues\" section of this repo. Please reference the board, project, and source files associated with the bug, and reference line numbers. If you are proposing a fix, also include information on the proposed fix. Since these examples are provided as-is, there is no guarantee that these examples will be updated to fix these issues.\n\nQuestions and comments related to these examples should be made by creating a new \"Issue\" in the \"Issues\" section of this repo.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiliconlabssoftware%2Fweb-bluetooth-spp-application","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsiliconlabssoftware%2Fweb-bluetooth-spp-application","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiliconlabssoftware%2Fweb-bluetooth-spp-application/lists"}