npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

node-red-contrib-emotiv-bci

v2.1.5

Published

EmotivBCI Node-RED to get data from Emotiv Cortex V2

Downloads

35

Readme

EmotivBCI Node-RED toolkit V2

Only compatible to Emotiv Cortex Version 2

About

The EmotivBCI Node-RED toolkit V2 is a custom library of nodes for Node-RED which will allow you to interface EMOTIV wearable brain sensing technology with Node-RED and create brain-computer interface (BCI) integrations. More information can be found in our User Guide.

EmotivBCI Node-RED Toolbox works on MacOS and Windows.

Requirements

  • Install and use the EmotivBCI application to create your Training Profile for Mental Commands and Facial Expressions in the cloud.
  • Accept EMOTIV’s Developer’s License Agreement by installing and opening Cortex App and following the instructions.
  • Install NodeJS and Node-Red. NodeJS LTS 8.x or later versions is recommended.
  • Get your client id and client secret from https://www.emotiv.com/my-account/cortex-apps/, put them in bci-config.js file.

Install

To install EmotivBCI Nodes, run this command on Node-RED installation directory (~/.node-red by default). If the .node-red folder doesn't exist, run node-red program on Windows Command Prompt/MacOS Terminal to create it.

$ npm install node-red-contrib-emotiv-bci

Note:

  1. On the first run, you will need to approve access via EMOTIV app.
  2. Before deploying a flow using EmotivBCI Node-RED Toolbox, you need to be logged into and connected to our Cortex Service via EMOTIV applications.
  3. You may need to uninstall previous version of node-red-contrib-emotiv-bci before installing the latest version and delete previous node-red flows (inside ~/.node-red directory) Or after updating node-red-contrib-emotiv-bci to new version. It's recommended to backup your flows by exporting them, then delete those flow files.
  4. If you have trouble while running the Emotiv nodes (e.g. unable to load profile, nodes stuck at Connecting... status), you should check the websocket's messages. The most simple way is adding console.log(msg) within node.socket.on("message") function at ~/.node-red/node_modules/bci-node-red/emotiv-bci-node-red/emotiv-bci/bci-emotiv.js#line-59 (line 59 in bci-emotiv.js file), then check the output in Windows Command Prompt/MacOS Terminal. Please also send the output log to Customer Support if you need additional assistance.

EmotivBCI node feature

EMOTIV

The EMOTIV node allows you to authenticate and connect to a logged-in EmotivID via Node-RED. This node is required for all EmotivBCI nodes and should be placed at the beginning of the EmotivBCI node sequence.

Input:

N/A

Output:

Authorization token

Note:

You must login with your EmotivID via one of EMOTIV’s Cortex-based applications (e.g. Cortex App, EmotivBCI).


Profile Name

This node allows you to select a Training Profile that you created in the EmotivBCI application and that is associated with your EmotivID. This Profile will then be used in downstream Mental Commands or Facial Expression nodes.

Input:

Authorization token

Output:

Array contains authorization token and profile name

Properties:

Profile name: String

Note:

This Profile name must match one associated with the EmotivID logged in to Cortex and Node-RED. Do not include this node if you want to use the Training Profile currently open in EmotivBCI.


Mental Commands

This node will output the value of a Mental Command that you have trained in our EmotivBCI application. In the node, you can select which Mental Command you would like to use (e.g. “Push”, “Pull” or “Lift”).

Input:

Array contains authorization token and profile name

Output:

Integer [0-100] at a frequency rate of up to 8 Hz

Properties:

Sensitivity: Int [1-10]

Note:

You can set the sensitivity for the command. Low values will make the command harder to be triggered (resulting in fewer false positives), and vice versa. The selected Training Profile must contain training data for the selected Mental Command in this node, and the profile must be synced to the cloud in order to function. For example, if you select "Push" in the node, your Training Profile must have at least 1 training session accepted for "Push" in EmotivBCI app.


Facial Expressions

This node will output the value of our Facial Expression detection and allows you to choose the expression you would like to use (e.g. “Smile”, “Blink” or “Frown”). You can use the default Facial Expression detections or your trained Facial Expressions. To use the trained detections, place the Profile node in front of the Facial Expressions node. To use the default detections, connect this node directly to the EMOTIV node.

Input:

Array contains authorization token and profile name OR Authorization token

Output:

Integer [0-100] at a frequency rate of up to 16Hz

Properties:

Action: String
Threshold: Int [0-1000]

Note:

You can also set the threshold for the expression. Low values will make the expression harder to be triggered (resulting in fewer false positives), and vice versa. If you are using trained expressions, the Training Profile that you have selected must have training data for the specific Facial Expression that you select in this node and your profile must be synced to the cloud in order to function. For example, if you select "Smile" in the node, your Training Profile must have at least 1 training session accepted for "Smile" in EmotivBCI.


Performance Metrics

This node outputs the value of our Performance Metrics detection and allows you to select which metric you would like to use (from choices: excitement, interest, engagement, stress, focus, relaxation). This node does not require input from a Profile node.

Input:

Authorization token

Output:

Integer [0-100], at a frequency rate of 0.1 Hz

Properties:

Action: String | N/A


Frequency Band

This node outputs Frequency Band Power at a frequency rate of 8Hz and allows you to select which band (e.g. alpha) you would like to use.

Input:

Authorization token

Output:

Integer, at a frequency rate of 32, 64 or 128 Hz (depending on headset and configuration)

Properties:

Band: String | N/A


Motion Sensors

This node outputs the value from your headset Motion Sensors and allows you to select motion data stream you would like to use.

Input:

Authorization token

Output:

Integer, at a frequency rate of 32, 64 or 128 Hz (depending on headset and configuration)

Properties:

Sensor: String