Comments (3)
I think this might be due to a noble restriction, but I already have a branch to try and address it, it's been waiting for other testers / complaints of the same symptom.
Can you try and let me know? Steps:
- clone the repo:
git clone https://github.com/andersonshatch/soma-ctrl
cd soma-ctrl
- Checkout the new branch:
git checkout discover-all-then-connect
- Install the dependencies:
npm install
from soma-ctrl.
this one is indeed working. Thanks!
I do see a lot of connects though and wonder if that is expected ... my screen is constantly scrolling with:
soma* scanning for 2 device(s) [ 'fdbdb47f4f7a', 'e2e48169e805' ] +0ms
soma* connected to fdbdb47f4f7a +916ms
soma* connected to fdbdb47f4f7a +28ms
soma* connected to fdbdb47f4f7a +7ms
soma* connected to e2e48169e805 +361ms
soma* all expected devices connected, stopping scan +0ms
soma* connected to e2e48169e805 +951ms
soma* connected to e2e48169e805 +13s
soma* connected to e2e48169e805 +5s
soma* connected to e2e48169e805 +300ms
soma* connected to e2e48169e805 +300ms
soma* connected to e2e48169e805 +300ms
soma* connected to e2e48169e805 +745ms
soma* connected to e2e48169e805 +8s
soma* connected to e2e48169e805 +4s
soma* connected to e2e48169e805 +5s
soma* connected to e2e48169e805 +188ms
soma* connected to e2e48169e805 +717ms
soma* connected to e2e48169e805 +16s
soma* connected to e2e48169e805 +25s
soma* connected to e2e48169e805 +4s
soma* connected to e2e48169e805 +8s
soma* connected to e2e48169e805 +2s
soma* connected to e2e48169e805 +200ms
soma* connected to e2e48169e805 +2s
soma* connected to e2e48169e805 +15s
soma* connected to e2e48169e805 +7s
soma* connected to e2e48169e805 +3s
soma* connected to e2e48169e805 +442ms
Also after some time I get multiple:
(node:6405) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 characteristicsDiscover listeners added. Use emitter.setMaxListeners() to increase limit
This doesn't seem to effect functionality though...
One other problem I got a few times is:
pi@soma-ctrl:~/soma-ctrl $ sudo node /home/pi/node_modules/soma-ctrl/index.js fdbdb47f4f7a e2e48169e805 --url mqtt:192.168.2.192:1883
soma* scanning for 2 device(s) [ 'fdbdb47f4f7a', 'e2e48169e805' ] +0ms
soma* connected to fdbdb47f4f7a +516ms
/home/pi/node_modules/soma-ctrl/src/SomaShade.js:147
this.positionCharacteristic.subscribe();
^
TypeError: Cannot read property 'subscribe' of undefined
at peripheral.discoverSomeServicesAndCharacteristics (/home/pi/node_modules/soma-ctrl/src/SomaShade.js:147:45)
at Peripheral. (/home/pi/node_modules/noble/lib/peripheral.js:101:13)
at Service. (/home/pi/node_modules/noble/lib/service.js:53:7)
at Object.onceWrapper (events.js:315:30)
at emitOne (events.js:116:13)
at Service.emit (events.js:211:7)
at Noble.onCharacteristicsDiscover (/home/pi/node_modules/noble/lib/noble.js:302:13)
at emitThree (events.js:136:13)
at NobleBindings.emit (events.js:217:7)
at NobleBindings.onCharacteristicsDiscovered (/home/pi/node_modules/noble/lib/hci-socket/bindings.js:339:8)
If you want me to open a new issue for one of the above let me know
Cheers
Ron
from soma-ctrl.
Connecting only to the first discovered device and the crash with Cannot read property 'subscribe' of undefined
should both be addressed by v1.3.0 which I just released.
I've looked into those MaxListenersExceededWarnings before, and most of them I can't do anything about, but they don't seem to affect stability.
from soma-ctrl.
Related Issues (11)
- TypeError: Cannot read property 'subscribe' of undefined HOT 5
- Latest Soma blinds not detecting HOT 17
- Hassio
- trying to make this work for HomeBridge... HOT 3
- Command Disallowed 0xc causes a device to become unresponsive HOT 9
- Issues installing - directory not created HOT 1
- Recurrent error HOT 6
- TypeError: Cannot read property 'valueHandle' of undefined HOT 3
- βstateβ does not update HOT 5
- Somactrl throwing MTU error, stops responding HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from soma-ctrl.