Add Robot_JoyIt driver

This commit is contained in:
2026-01-17 16:50:07 +01:00
parent e9e50acf5f
commit 0cfb4d5a95
15848 changed files with 570836 additions and 268976 deletions

2
node_modules/wss/.npmignore generated vendored Normal file
View File

@@ -0,0 +1,2 @@
*.DS_Store
npm-debug.log

61
node_modules/wss/index.js generated vendored
View File

@@ -1,54 +1,7 @@
const {Server} = require('ws')
Server.prototype.listening = false
Server.prototype.listen = function (...args) {
return this._server
.listen(...args)
.once('listening', () => {
this.listening = true
})
}
Server.prototype.close = function (fn = Function.prototype) {
if (this.clients) {
for (const client of this.clients) client.terminate()
}
this._ultron.destroy()
this._ultron = null
return this._server.close((...args) => {
this.listening = false
fn(...args)
})
}
module.exports = Server // v 1
module.exports.createServerFrom = createServerFrom
module.exports.createServer = createServer
function createServerFrom (server, connectionListener, options = {}) {
if (typeof server === 'undefined') throw new Error('must provide server')
const wss = new Server(Object.assign(options, {server}))
return connectionListener
? wss.on('connection', connectionListener)
: wss
}
function createServer (options = {}, connectionListener) {
if (typeof options === 'function') {
connectionListener = options
options = {}
}
const server = createServerFor(options)
return createServerFrom(server, connectionListener) // v 2
function createServerFor (options) {
return options.key && options.cert || options.pfx
? require('https').createServer(options, requestListener)
: require('http').createServer(requestListener)
}
function requestListener (req, res) {
const {STATUS_CODES: {'426': status}} = require('http')
res.writeHead(426, {
'content-length': status.length,
'content-type': 'text/plain'
})
res.end(status)
}
}
module.exports = require('ws').Server
module.exports.createServer = function (options, connectionListener) {
var server = new module.exports(options)
if (typeof connectionListener === 'function')
server.on('connection', connectionListener)
return server
}

26
node_modules/wss/package.json generated vendored
View File

@@ -1,9 +1,8 @@
{
"author": "Ivo von Putzer Reibegg <ivo.putzer@gmail.com>",
"name": "wss",
"version": "3.3.4",
"description": "wrapper built upon ws module that provides standard server api only.",
"author": "Ivo von Putzer Reibegg <ivo.putzer@gmail.com> (https://github.com/ivoputzer)",
"homepage": "https://github.com/ivoputzer/wss#readme",
"description": "Wrapper made upon the well known ws module that provides server API only.",
"version": "0.0.2",
"keywords": [
"Hixie",
"HyBi",
@@ -19,27 +18,18 @@
"url": "git://github.com/ivoputzer/wss.git"
},
"scripts": {
"version": "echo $npm_package_version",
"test": "m.test",
"pretest": "standard",
"coverage": "node --require ./node_modules/m.test/global.js ./node_modules/istanbul/lib/cli.js cover --print detail test/.istanbul.js"
},
"optionalDependencies": {
"istanbul": "^0.4.5"
},
"engines": {
"node": ">=6"
"node": ">=0.4.0"
},
"dependencies": {
"ws": "^2.3.1"
"ws": "*"
},
"devDependencies": {
"standard": "^8.6.0",
"m.test": "0.0.57",
"pem": "^1.9.4"
},
"license": "MIT",
"bugs": {
"url": "https://github.com/ivoputzer/wss/issues"
}
}
},
"homepage": "https://github.com/ivoputzer/wss"
}

73
node_modules/wss/readme.md generated vendored
View File

@@ -1,71 +1,2 @@
wss
===
[![travis](https://img.shields.io/travis/ivoputzer/wss.svg?style=flat-square)](https://travis-ci.org/ivoputzer/wss)
[![dependencies](https://img.shields.io/badge/dependencies-none-blue.svg?style=flat-square&colorB=44CC11)](package.json)
[![linter](https://img.shields.io/badge/coding%20style-standard-brightgreen.svg?style=flat-square)](http://standardjs.com/)
[![coverage](https://img.shields.io/coveralls/ivoputzer/wss.svg?style=flat-square)](https://coveralls.io/github/ivoputzer/wss?branch=master)
[![node](https://img.shields.io/badge/node-6%2B-blue.svg?style=flat-square)](https://nodejs.org/docs/v6.0.0/api)
[![version](https://img.shields.io/npm/v/wss.svg?style=flat-square&colorB=007EC6)](https://www.npmjs.com/package/wss)
[![license](https://img.shields.io/badge/license-MIT-blue.svg?style=flat-square&colorB=007EC6)](https://spdx.org/licenses/MIT)
wrapper built upon [ws](https://www.npmjs.org/package/ws) module that provides standard server api only.
#### usage with server creation
```javascript
const {createServer} = require('wss')
createServer(function connectionListener (ws) {
ws.send('welcome!')
ws.on('message', (data) => {
ws.send(data.toString()) // echo-server
})
})
.listen(8080, function () {
const {address, port} = this.address() // this is the http[s].Server
console.log('listening on http://%s:%d (%s)', /::/.test(address) ? '0.0.0.0' : address, port)
})
```
#### usage with existent server
```javascript
const {createServer} = require('http')
const {createServerFrom} = require('wss')
const http = createServer()
createServerFrom(http, function connectionListener (ws) {
ws.send('welcome!')
ws.on('message', (data) => {
ws.send(data.toString()) // echo-server
})
})
http.listen(8080)
```
### wss
the `ws.Server` object is inherited from [ws](http://npmjs.org/ws)
### wss.prototype.close([callback])
stops the server from accepting new connections.
### wss.prototype.listen(handle[, callback])
the `handle` object can be set to either a server or socket (anything with an underlying _handle_ member), or a `{fd}` object. This function is asynchronous. callback will be added as a listener for the `listening` event.
### wss.prototype.listen(path[, callback])
start a unix socket server listening for connections on the given path. this function is asynchronous. callback will be added as a listener for the `listening` event.
### wss.prototype.listen([port[, hostname[, backlog[, callback]]]])
begin accepting connections on the specified port and hostname. if the hostname is omitted, the server will accept connections on any ipv6 address (::) when ipv6 is available, or any ipv4 address (0.0.0.0) otherwise. omit the port argument, or use a port value of 0, to have the operating system assign a random port, which can be retrieved by using server.address().port after the `listening` event has been emitted.
to listen to a unix socket, supply a filename instead of port and hostname.
backlog is the maximum length of the queue of pending connections. The actual length will be determined by your OS through sysctl settings such as `tcp_max_syn_backlog` and somaxconn on linux. The default value of this parameter is `511`. This function is asynchronous. `callback` will be added as a listener for the `listening` event.
Note: The server.listen() method may be called multiple times. Each subsequent call will re-open the server using the provided options.
### wss.createServerFrom(server=http.Server|https.Server)
returns a new `ws.Server` based on given web server object.
throws if no server is given.
### wss.createServer([options[, connectionListener]])
returns a new `ws.Server` based on given options and connectionListener. underlaying `https` server is created when `tls` options have been provided as of`tls.createServer()`, otherwise it will fallback to a `http` implementation. the connectionListener is a function which is automatically added to the `connection` event.
# wss
Wrapper made upon the well known [ws module](https://www.npmjs.org/package/ws) that provides server API only.