This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Mouse Script | |
After=network.target | |
[Service] | |
User=root | |
ExecStart=/bin/bash mouse.sh | |
WorkingDirectory=/root | |
Restart=on-failure |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Check if script is running as root | |
if [ "$EUID" -ne 0 ] | |
then echo "Please run as root" | |
exit | |
fi | |
# your personal machine running jacktrip | |
REMOTE_JACK_SERVER=nat.local |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// assumes your mouse is in relative mode https://docs.pikvm.org/mouse/?h=relative#relative-mouse-on-v2-platform-otg-hid | |
// You may want to set your pikvm to support dual mode, so you can switch between absolute and relative | |
const { PIKVM_HOST, PIKVM_USER, PIKVM_PASSWORD, MOUSE_MODE = 'normal' } = process.env | |
process.env["NODE_TLS_REJECT_UNAUTHORIZED"] = 0; | |
import fetch from 'node-fetch'; | |
import { path } from "ghost-cursor"; | |
import websocket from 'websocket'; | |
const WebSocketClient = websocket.client | |
let connection; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const pathParser = require("path"); | |
const { MODEL_PATH, HOME, YOUR_NAME, FILE_GLOB } = process.env; | |
console.log(MODEL_PATH, HOME, YOUR_NAME, FILE_GLOB); | |
const chokidar = require('chokidar'); | |
const vosk = require('vosk'); | |
const wav = require("wav"); | |
const { Readable } = require("stream"); | |
const { notify } = require('node-notifier'); | |
const TailingReadableStream = require('tailing-stream'); | |
const recordingsDir = `${HOME}/recordings/` |