Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mathieu2301/focusrite-control-api
Focusrite Control API
https://github.com/mathieu2301/focusrite-control-api
api automation focusrite focusrite-control focusrite-scarlett leds nodejs
Last synced: 2 months ago
JSON representation
Focusrite Control API
- Host: GitHub
- URL: https://github.com/mathieu2301/focusrite-control-api
- Owner: Mathieu2301
- Created: 2020-07-11T00:14:46.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-07-11T00:40:53.000Z (over 4 years ago)
- Last Synced: 2024-09-06T08:49:46.074Z (4 months ago)
- Topics: api, automation, focusrite, focusrite-control, focusrite-scarlett, leds, nodejs
- Language: JavaScript
- Homepage:
- Size: 4.88 KB
- Stars: 17
- Watchers: 7
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Focusrite Control API
Focusrite Control APINo dependencies 💪
___
## Installation```
npm install focusrite
```## Examples (test.js)
Start by importing the library
```javascript
const focusrite = require('focusrite');
```### Create a fake ControlServer
```javascript
focusrite.createFakeServer([
``,
` ... `,
...
], (data) => {
console.log(data);
});
```### Find the running ControlServer port
```javascript
focusrite.findServerPort((port) => {
console.log(`ControlServer port is : ${port}`);
});
```### Connect to the ControlServer as a fake client
```javascript
focusrite.createFakeClient(port, 'xxxxxxxx-0000-xxxx-xxxx-xxxxxxxxxxxx', (onData, clientWrite) => {
onData((data) => {
console.log(data);// These commands are compatible with the Scarlett SOLO (3rd gen) :
// To write a response
clientWrite(` ... `);// To change gain halos colors
clientWrite(focusrite.requests.MODE_COLOR); // First set in "color" mode
clientWrite(focusrite.colors.RED); // Availables colors : RED, AMBER, GREEN, LIGHT_BLUE, BLUE, LIGHT_PINK, PINK// To enable/disable AIR Mode
clientWrite(focusrite.requests.A1_PREAMP_TRUE); // Enable
clientWrite(focusrite.requests.A1_PREAMP_FALSE); // Disable// To enable/disable INST Mode
clientWrite(focusrite.requests.A2_INST_TRUE); // Enable
clientWrite(focusrite.requests.A2_INST_FALSE); // Disable
// To send a custom command
clientWrite(` ... `);// Model of a command :
/*
*/
});
});
```___
## ProblemsIf you have errors in console or unwanted behavior, just reload the page.
If the problem persists, please create an issue [here](https://github.com/Mathieu2301/Focusrite-Control-API/issues).