diff options
author | Jakob Stendahl <jakob.stendahl@outlook.com> | 2021-06-08 00:53:25 +0200 |
---|---|---|
committer | Jakob Stendahl <jakob.stendahl@outlook.com> | 2021-06-08 00:54:14 +0200 |
commit | a8e95425b79df647587f7a68745802582ece068f (patch) | |
tree | 985df52a758249356b576ce0ee5c755b1bc6cf59 /src/js | |
parent | b050a73c37ee229b7639dfd2364367dc22dac721 (diff) | |
download | hoverbit-ble-a8e95425b79df647587f7a68745802582ece068f.tar.gz hoverbit-ble-a8e95425b79df647587f7a68745802582ece068f.zip |
:hammer: Small tweakscontroller
Diffstat (limited to 'src/js')
-rw-r--r-- | src/js/main.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/js/main.js b/src/js/main.js index 3d7f494..8ea0951 100644 --- a/src/js/main.js +++ b/src/js/main.js @@ -39,6 +39,8 @@ if (!navigator.bluetooth) { /* Define and initialize things */ let ubit = new uBitBLE(); let hoverControl = new hoverControlModule(); +window.ubit = ubit; +window.hoverControl = hoverControl; let joystickLeft = nipplejs.create({ zone: document.querySelector(".joystick-left"), @@ -116,6 +118,7 @@ ubit.onUartTx((text) => { elm.parentNode.replaceChild(newone, elm); /* Actually handle received text. */ + // console.log(`Received: ${text}`); if ((text).indexOf(":") != -1) { let parts = (text).split(":"); @@ -141,6 +144,6 @@ let intervalSendCommands = setInterval(async() => { "S0" + ":"; await ubit.sendUart(command); + // console.log(`Sent: ${command}`); } }, 100); - |