Coder Social home page Coder Social logo

ble-ble113a's People

Contributors

adkron avatar evansimpson avatar frijol avatar johnnyman727 avatar mfferreira avatar pmcote avatar rbobbins avatar tcr avatar tm-rampart 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

Watchers

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

ble-ble113a's Issues

Best way to send serial (with specified baud rate) to a connected slave.

I have connected to an Arduino based BLE Slave and am listening for serial commands on it right now. Can't seem to find a good way to explicitly write out and listen to it through the Tessel BLE api.

Here is the device (LightBlue Bean)

{
    "services": {},
    "rssi": -52,
    "advertisingData": [
        {
            "typeFlag": 1,
            "type": "Flags",
            "raw": {},
            "data": [
                "LE General Discoverable Mode",
                "BR/EDR Not Supported"
            ],
            "byteOrder": "BE"
        },
        {
            "typeFlag": 6,
            "type": "Incomplete List of 128-bit Service Class UUIDs",
            "raw": {},
            "data": [
                "a495ff10c5b14b44b5121370f02d74de"
            ],
            "byteOrder": "BE"
        }
    ],
    "address": "194.45.205.114.57.208"
}

No Events for Passkey entry

Without the passkey display and passkey entry events it is impossible to connect to a passkey enabled BLE device.

[Compat] Fails on Tessel 2

Here is the output from trying to run the example:

INFO Looking for your Tessel...
INFO Connected to doorman.
INFO Building project.
INFO Writing project to RAM on doorman (149.504 kB)...
INFO Deployed.
INFO Running ble.js...
Trace: <Buffer ef bf bd 0c 00 00 01 00 02 00 02 00 5d 00 03 00 01 06>
    at e.parseIncomingPackets (/tmp/remote-script/node_modules/ble-ble113a/lib/messenger.js:1:7049)
    at emitOne (events.js:77:13)
    at emit (events.js:169:7)
    at readableAddChunk (_stream_readable.js:146:16)
    at Readable.push (_stream_readable.js:110:10)
    at null.<anonymous> (/usr/lib/node/tessel-export.js:229:24)
    at emitNone (events.js:67:13)
    at Socket.emit (events.js:166:7)
    at emitReadable_ (_stream_readable.js:411:10)
    at emitReadable (_stream_readable.js:405:7)
[Error: No existing response creator for packet of class 0 and command id 93]
events.js:141
      throw er; // Unhandled 'error' event
      ^

Error: Unable to connect to module.
    at Error (native)
    at e.<anonymous> (/tmp/remote-script/node_modules/ble-ble113a/lib/messenger.js:1:524)
    at processImmediate [as _immediateCallback] (timers.js:368:17)

The first byte should be an 0x80, instead there are three nonsense bytes (0xef, 0xbf, 0xed) so there may be an issue with the UART peripheral in T2 firmware.

startAdvertising() does not work on iphone

I tried using your example by running it directly from the example directory and my iphone does not pick up on it.

npm init
npm i tessel --save
npm i 

Then in the ble-advertise.js

var tessel = require('tessel');
var blelib = require('ble-ble113a');

var ble = blelib.use(tessel.port['A']);
// var ble = require('../').use(tessel.port['A']); // Replace '../' with 'ble-ble113a' in your own code

var interval;

then

tessel run ble-advertise.js

I get started advertising... but with nothing showing on my iphone.

Add ability to change transmission power

The feature to change the transmission power has been requested on the forums.

To do this, a function needs to be added to messenger.js (the agent that sends and receives packages from the BLE113) to send the correct packet. To do that, call the bglib. hwSetTxPower function and pass in a value from 0 to 15 to sent the transmission power. 15 is the highest. Then, expose the function in index.js, where the BluetoothController will ask the messenger API to send the message and receive the response.

Add ability to change advertising rate

It would be nice to be able to set the advertising rate of a BLE module acting as a beacon.

To do that, we need to add a function to messenger.js which outlines the raw packet that is being sent over UART to the module. It will use the bglib.gapSetAdvParameters function. The function expects a 16 bit number describing the min interval, a 16 bit number specifying the max interval, and a bit mask to specify which advertisement channels are used. The interval argument can be between 0x20 and 0x400. The advertisement channel should probably be 0x07 to continue using all three channels.

Then, this messenger API function should be surfaced to the BluetoothController object in index.js.

Can't connect to iOS device

The connection_status event is not being fired when trying to connect to an iOS device. See more details and test code on this forum post.

Bonus points if you make example code that other people can use to integrate Tessel BLE with iOS and/or Android

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.