Releases: cronelab/bci2k.js
Releases · cronelab/bci2k.js
No build pipeline, just tsc
3.0.1 Added declarationMap
2.1.7
fixed webpack/websocket external
2.1.6
fixed webpack/websocket external
2.1.5
fixed webpack/websocket external
2.1.4
two getter methods
2.1.3
stateListen method
2.1.2
new data conn example and entry point
2.1.1
bci2k.js
A javascript connector for BCI2000
bci2k.js relies on a binary server called BCI2000Web, which allows browsers to communicate with Operator using the Operator Scripting language and stream data in to the browser using websockets.
Install
npm install --save @cronelab/bci2k
Usage
Connect to BCI2000
const BCI2K = require( 'bci2k' );
const bci = new BCI2K.bciOperator();
bci.connect("127.0.0.1")
.then(() => console.log("Connected"))
.catch(err => console.log(err)
Execute system commands
bci.showWindow();
bci.hideWindow();
bci.resetSystem();
bci.start();
bci.getVersion();
bci.execute("args"); //args are any BCI2000 Operator commands
Tap data from part of the signal processing chain
const connectToSockets = async () => {
let sourceConnection = await bci.tap("Source");
try{
sourceConnection.onStateFormat = data => console.log(data);
sourceConnection.onSignalProperties = data => console.log(data);
sourceConnection.onGenericSignal = data => console.log(data);}
}
catch(err){
console.log(err);
}
//or
let bciDataConnection = new BCI2K.bciData();
bciDataConnection.connect("127.0.0.1:12345")
let signal = bciDataConnection.signal;
See more in the examples folder
Development
npm run build
npm run dev
License
2.1.0
bci2k.js
A javascript connector for BCI2000
bci2k.js relies on a binary server called BCI2000Web, which allows browsers to communicate with Operator using the Operator Scripting language and stream data in to the browser using websockets.
Install
npm install --save @cronelab/bci2k
Usage
Connect to BCI2000
const BCI2K = require( 'bci2k' );
const bci = new BCI2K.bciOperator();
bci.connect("127.0.0.1")
.then(() => console.log("Connected"))
.catch(err => console.log(err)
Execute system commands
bci.showWindow();
bci.hideWindow();
bci.resetSystem();
bci.start();
bci.getVersion();
bci.execute("args"); //args are any BCI2000 Operator commands
Tap data from part of the signal processing chain
const connectToSockets = async () => {
let sourceConnection = await bci.tap("Source");
try{
sourceConnection.onStateFormat = data => console.log(data);
sourceConnection.onSignalProperties = data => console.log(data);
sourceConnection.onGenericSignal = data => console.log(data);}
}
catch(err){
console.log(err);
}
//or
let bciDataConnection = new BCI2K.bciData();
bciDataConnection.connect("127.0.0.1:12345")
let signal = bciDataConnection.signal;
See more in the examples folder
Development
npm run build
npm run dev
License
2.0.10
bci2k.js
A javascript connector for BCI2000
bci2k.js relies on a binary server called BCI2000Web, which allows browsers to communicate with Operator using the Operator Scripting language and stream data in to the browser using websockets.
Install
npm install --save bci2k
Usage
Connect to BCI2000
const BCI2K = require( 'bci2k' );
const bci = new BCI2K.bciOperator();
bci.connect("127.0.0.1")
.then(() => console.log("Connected"))
.catch(err => console.log(err)
Execute system commands
bci.showWindow();
bci.hideWindow();
bci.resetSystem();
bci.start();
bci.getVersion();
bci.execute('args') //args are any BCI2000 Operator commands
Tap data from part of the signal processing chain
const connectToSockets = async () => {
let sourceConnection = await bci.tap("Source");
try{
sourceConnection.onStateFormat = data => console.log(data);
sourceConnection.onSignalProperties = data => console.log(data);
sourceConnection.onGenericSignal = data => console.log(data);}
}
catch(err){
console.log(err);
}
//or
let bciDataConnection = new BCI2K.bciData();
bciDataConnection.connect("127.0.0.1:12345")
let signal = bciDataConnection.signal;
See more in the examples folder
Development
npm run build
npm run dev