Skip to content

Commit f656912

Browse files
authored
Merge pull request #285 from OpenBCI/264-test-signal-troubleshooting-doc
Add Information to Test Signal Commands for Troubleshooting
2 parents 09c5116 + b69f9e4 commit f656912

9 files changed

+44
-34
lines changed

website/docs/Cyton/04-OpenBCI_Cyton_SDK.md

Lines changed: 44 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -3,36 +3,19 @@ id: CytonSDK
33
title: Cyton Board SDK
44
---
55

6-
The OpenBCI Cyton boards communicate using a byte string (mostly ASCII) command protocol. This document covers command usage for the OpenBCI Cyton and 8-bit boards. Some of the commands are board-specific, where noted. Further, this document covers the commands needed to alter the radio system. There have been several iterations of the firmware: the 8-bit board runs `v0`, the Cyton runs `v1`, and boards shipped as of Fall 2016 run `v2.0.0`. `v3.0.0` began shipping with boards in August of 2017.
6+
The OpenBCI Cyton boards communicate using a byte string (mostly ASCII) command protocol. This document covers command usage for the OpenBCI Cyton boards. Some of the commands are board-specific, where noted. Further, this document covers the commands needed to alter the radio system. There have been several iterations of the firmware: the 8-bit board runs `v0`, the Cyton runs `v1`, and boards shipped as of Fall 2016 run `v2.0.0`. `v3.0.0` began shipping with boards in August of 2017.
77

8-
## Cyton Command Protocol Overview
9-
10-
Cyton boards have two powerful microcontrollers onboard and come pre-programmed with firmware. The RFduino radio link uses the Nordic Gazelle stack and library. The board-mounted RFduino is configured as a DEVICE. The microcontroller (PIC32MX250F128B or ATmega328P) has been programmed with firmware that interfaces between the ADS1299 (Analog Front End), LIS3DH (Accelerometer), micro SD (if installed), and RFduino (Radio module). The user or application controls the board by sending commands over a wireless serial connection. You should have received a Dongle with the OpenBCI board. The Dongle has an RFduino running the Gazelle library configured as a HOST and interfaces with your computer through a Virtual Com Port (FTDI).
11-
12-
On startup, the OpenBCI 8bit board (`v0`) sends the following text over the radio:
13-
14-
```
15-
16-
OpenBCI V3 8bit Board
17-
Setting ADS1299 Channel Values
18-
ADS1299 Device ID: 0x3E
19-
LIS3DH Device ID: 0x33
20-
$$$
21-
22-
```
8+
:::info
239

24-
the OpenBCI Cyton board with firmware `v1` sends the following text over the radio:
10+
The Cyton 8-bit boards have been deprecated and so has `v0` and `v1` of the Cyton firmware. It is recommended to use the `v3.0.0` or later of the Cyton firmware. To update your Cyton firmware, follow the steps [here](../Cyton/05-Cyton_Board_Programming_Tutorial.md)
2511

26-
```
12+
:::
2713

28-
OpenBCI V3 16 channel
29-
ADS1299 Device ID: 0x3E
30-
LIS3DH Device ID: 0x33
31-
$$$
14+
## Cyton Command Protocol Overview
3215

33-
```
16+
Cyton boards have two powerful microcontrollers onboard and come pre-programmed with firmware. The RFduino radio link uses the Nordic Gazelle stack and library. The board-mounted RFduino is configured as a DEVICE. The microcontroller (PIC32MX250F128B or ATmega328P) has been programmed with firmware that interfaces between the ADS1299 (Analog Front End), LIS3DH (Accelerometer), micro SD (if installed), and RFduino (Radio module). The user or application controls the board by sending commands over a wireless serial connection. You should have received a Dongle with the OpenBCI board. The Dongle has an RFduino running the Gazelle library configured as a HOST and interfaces with your computer through a Virtual Com Port (FTDI).
3417

35-
the OpenBCI Cyton board with firmware `v2.0.0` sends the following text over the radio:
18+
On startup, the OpenBCI Cyton board with firmware `v2.0.0` and later sends the following text over the radio:
3619

3720
```
3821
@@ -46,10 +29,16 @@ $$$
4629

4730
Device ID info is useful for general board health confirmation. The $$$ is a clear indication to the controlling application that the message is complete and the Cyton board is ready to receive commands. As of `v2.0.0`, there is an additional printout to indicate the exact firmware version.
4831

49-
Pay attention to timing when sending commands using `v0` and `v1` firmware. There must be some delay before and after sending a command character from the PC (controlling program or user running a terminal). As of `v2.0.0`, this is no longer the case—send as fast as you can!
50-
5132
## Command Set
5233

34+
To send a command to the Cyton board through the dongle wirelessly, you can use the Hardware Settings panel. But, you must turn on the Expert Mode in the OpenBCI GUI. To do this, connect to the Cyton board and then click on the Settings -> Turn Expert Mode On button as shown below.
35+
36+
![Turn on Expert Mode](../assets/CytonImages/TurnOnExpertModeSDK.png)
37+
38+
In the Hardware Settings panel, the Custom Commands box can be used to send SDK commands to the board. If successful, you will see a GUI message that the command was sent successfully.
39+
40+
![Send commands with Custom Commands Box](../assets/CytonImages/CustomCommandsBox.png)
41+
5342
### Turn Channels OFF
5443

5544
**1 2 3 4 5 6 7 8**
@@ -70,16 +59,37 @@ These ASCII characters turn the respective channels [1-8] on. The channel will r
7059

7160
**0 - = p [ ]**
7261

73-
Turn **all** available channels on and connect them to the internal test signal. These are useful for self-test and calibration. For example, you can measure the internal noise by sending **0**, which connects all inputs to an internal GND. If streaming, the stream will be stopped, the proper registers set on the ADS1299, and the stream will be resumed.
62+
These commands are useful for self-test and calibration. If you feel like your Cyton or Daisy boards are malfunctioning, these commands are a great way to make sure the ADS1299 is not damaged. For example, you can measure the internal noise by sending **0**, which connects all inputs to an internal GND. If streaming, the stream will be stopped, the proper registers set on the ADS1299, and the stream will be resumed.
63+
64+
- `0` Connect to internal GND (VDD - VSS)
65+
66+
When connected to Internal GND, the ADS1299 inputs are essentially shorted and measuring the internal or system noise. A normal working board will report 0.01% railed and 0.09-0.14 uVrms.
67+
![Connect to Internal GND](../assets/CytonImages/ConnectToInternalGND.gif)
68+
69+
- `-` Connect to test signal 1xAmplitude, slow pulse
70+
71+
A working Cyton or Daisy board will output square waves that are between 1855 - 1865 uVrms and 1.01% railed as shown below. To view the square waves properly, you will have to turn off all filters and set the scale to "Auto".
72+
![Slow Pulse, Square Wave, 1x Amplitude](../assets/CytonImages/TestSignal1xAmplitude.gif)
73+
74+
- `=` Connect to test signal 1xAmplitude, fast pulse
75+
76+
A working Cyton or Daisy board will output square waves that are between 1855 - 1865 uVrms and 1.01% railed as shown below. To view the square waves properly, you will have to turn off all filters and set the scale to "Auto".
77+
![Fast Pulse, Square Wave, 1x Amplitude](../assets/CytonImages/TestSignal1xAmplitudeFastPulse.gif)
78+
79+
- `p` Connect to DC signal
80+
81+
When connected to DC signal, the ADS1299 inputs are essentially measuring the DC Bias. A normal working board will report 2.01% railed and 0.13-0.16 uVrms.
82+
![Connect To DC Signal](../assets/CytonImages/ConnectToDCSignal.gif)
83+
84+
- `[` Connect to test signal 2xAmplitude, slow pulse
85+
86+
A working Cyton or Daisy board will output square waves that are between 3680 - 3715 uVrms and 2.01% railed as shown below. To view the square waves properly, you will have to turn off all filters and set the scale to "Auto".
87+
![Connect To DC Signal](../assets/CytonImages/TestSignalSlowPulse2xAmplitude.gif)
7488

75-
- **0** Connect to internal GND (VDD - VSS)
76-
- **-** Connect to test signal 1xAmplitude, slow pulse
77-
- **=** Connect to test signal 1xAmplitude, fast pulse
78-
- **p** Connect to DC signal
79-
- **\[** Connect to test signal 2xAmplitude, slow pulse
80-
- **]** Connect to test signal 2xAmplitude, fast pulse
89+
- `]` Connect to test signal 2xAmplitude, fast pulse
8190

82-
**Note: Not all possible internal test connections are implemented here.**
91+
A working Cyton or Daisy board will output square waves that are between 3680 - 3715 uVrms and 2.01% railed as shown below. To view the square waves properly, you will have to turn off all filters and set the scale to "Auto".
92+
![Connect To DC Signal](../assets/CytonImages/TestSignal2xAmplitudeFastPulse.gif)
8393

8494
**returns** If not streaming, returns `Success: Configured internal test signal.$$$`; if streaming, there is no confirmation.
8595

5.68 MB
Loading
968 KB
Loading
267 KB
Loading
5.66 MB
Loading
6.45 MB
Loading
5.15 MB
Loading
8 MB
Loading
306 KB
Loading

0 commit comments

Comments
 (0)