Comments (2)
It seems to disconnect here too, but seems like there is no error:
Create Controller
10.0.2.2 - - [17/Dec/2021 20:50:56] "GET /socket.io/?EIO=4&transport=polling&t=NtAANWw HTTP/1.1" 200 278 0.004319
10.0.2.2 - - [17/Dec/2021 20:50:56] "GET /socket.io/?EIO=4&transport=polling&t=NtAAHvX HTTP/1.1" 200 278 0.00423410.0.2.2 - - [17/Dec/2021 20:50:56] "POST /socket.io/?EIO=4&transport=polling&t=NtAAOGB&sid=wfBH8qzXEb814a3bAAAX HTTP/1.1" 200 219 0.003689
(1400) accepted ('10.0.2.2', 54947)
10.0.2.2 - - [17/Dec/2021 20:50:56] "GET /socket.io/?EIO=4&transport=polling&t=NtAAOGD&sid=wfBH8qzXEb814a3bAAAX HTTP/1.1" 200 213 0.000311
10.0.2.2 - - [17/Dec/2021 20:50:56] "GET /socket.io/?EIO=4&transport=polling&t=NtAAOGU&sid=wfBH8qzXEb814a3bAAAX HTTP/1.1" 200 181 0.000180
10.0.2.2 - - [17/Dec/2021 20:50:56] "POST /socket.io/?EIO=4&transport=polling&t=NtAAOGT&sid=wfBH8qzXEb814a3bAAAX HTTP/1.1" 200 219 0.014735
Disconnected
10.0.2.2 - - [17/Dec/2021 20:50:56] "GET /socket.io/?EIO=4&transport=websocket&sid=YzMa6J338Twl50JmAAAV HTTP/1.1" 200 0 252.563556
from nxbt.
Until this gets actually fixed, you could try something like this.
let statusIndicator = document.getElementById('status-indicator-text');
function watchForDisconnect() {
let intervalId = window.setInterval(() => {
if(statusIndicator.innerText !== 'CONNECTED') {
restartController();
watchForReconnect();
window.clearInterval(intervalId);
}, 100);
}
function watchForReconnect() {
let intervalId = window.setInterval(() => {
if(statusIndicator.innerText === 'CONNECTED') {
watchForDisconnect();
window.clearInterval(intervalId);
}
}, 100);
}
Or you can try what I'm currently doing.
let statusIndicator = document.getElementById('status-indicator-text');
function restartAndRunMacro() {
restartController();
let intervalId = window.setInterval(() => {
if(statusIndicator.innerText === 'CONNECTED') {
window.clearInterval(intervalId);
sendMacro();
}
}, 100)
}
Less Techy People:
If you don't know how to run those, just F12 and go to the console tab and paste the code. Also, don't run code random people on the internet give you unless you know what the code does. I'm not going to explain this code to you. If you don't understand it, you shouldn't run it, even if I tell you exactly what it does.
from nxbt.
Related Issues (20)
- Macro's '#' comments do not work HOT 2
- How to change keyboard mapping? HOT 2
- vagrant setup issue
- Bluetoothctl issue HOT 5
- LS PRESS RS PRESS not working HOT 1
- What distro of linux does this really work on? HOT 1
- Please include a more detailed installation guide for Linux
- Got this working but got issues HOT 1
- Adress already in use HOT 1
- test
- Webapp not working HOT 6
- Script works sometimes
- Other devices show my laptop as Pro Controller after uninstall HOT 1
- How to hold down one button, then pressing another while still holding down the first button? HOT 2
- Ability to hold down one button throughout runtime of NXBT macro HOT 3
- sudo nxbt demo / sudo nxbt test / sudo nxbt webapp not doing anything HOT 3
- How to change keyboard mapping?
- Can't properly install NXBT HOT 8
- Webapp still not working
- VBoxManage not installed when it is installed HOT 1
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 nxbt.