Git Product home page Git Product logo

win-ble-cpp's Introduction

win-ble-cpp

PoC for BLE on Windows using WinRT APIs

A proof-of-concept code for controlling a Bluetooth Low Energy Light Bulb using Windows RT APIs.

This project was created in hope to push forward the implementation of Web Bluetooth for Windows 10.

License: MIT.

What does it do?

  1. Scans for BLE devices with a 0xffe5 Primary Service
  2. Connects to any matching device
  3. Writes to Characterstic number 0xffe9 and changes the color of the bulb every second (alternates between red and yellow)

Note: This only works on Windows 10 Creators Update. Prior Windows 10 versions did not support BLE connections with unpaired devices.

win-ble-cpp's People

Contributors

urish avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

win-ble-cpp's Issues

Help reading from device

Hi,
I am having a hard time trying to add a function to read from device. It supposedly works with the function bellow, but I am getting an empty buffer. Any suggestions ?

auto result = co_await characteristic->ReadValueAsync();
std::wcout << "Read result: " << result->Status.ToString()->Data() << std::endl;

Thank you.
P.S: I have full control of my device using the Serial Bluetooth Application on Android.

Error on compile

Hello,

I downloaded this code and opened it in Visual Studios 2017. I received this error when building:

1>c:\program files (x86)\microsoft visual studio\2017\community\vc\tools\msvc\14.11.25503\include\collection.h(15): fatal error C1189: #error: collection.h requires the /ZW compiler option.

I tried to enable the /ZW compiler option but it did not work. After searching online I believe this may be an issue caused by having an older IDE version. What development environment did you use, and did you need to change any compiler settings?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.