Skip to main content

EStim Systems 2B

Serial Communication

Cable Details

Rather than using an RS-232 cable, the 2B uses a TTL cable for serial communication. This means you cannot use a regular USB-to-Serial converter, as the voltage levels will be incorrect. Instead, you need a cable that goes from USB to TRS connector with TTL voltages, like the FTDI TTL-232R-5V-AJ.

To wire your own cable, use the following connections between the TTL serial chip and TRS connector:

  • Tip <-> TX
  • Ring <-> RX
  • Sleeve <-> GND

Port Settings

The 2B uses 9600/8/N/1 for port settings.

Protocol

Structure

Commands are sent as ASCII, delimited by either a '\r' (0x0D) or by filling up the 5 character serial buffer of the 2B.

All commands will receive a reply of the same format

AAA:BB:CC:DD:EE:F:G:H:II
  • AAA - Battery Level
  • BB - Channel A Level x2, i.e. value is twice what is set via commands and is displayed on the LCD
  • CC - Channel B Level x2
  • DD - Channel C Setting x2
  • EE - Channel D Setting x2
  • F - Current Mode
  • G - Power Setting (L or H)
  • H - Channel A/B Joined? (0 or 1)
  • II - Firmware Version

Commands

CommandDescription
AxxSets Channel A Power % to xx. Range is 0 to 100, i.e. A50 sets Channel A to 50%
BxxSets Channel B Power % to xx. Range is 0 to 100
CxxSets Channel C Setting to xx. Range is 2 to 100
DxxSets Channel D Setting to xx. Range is 1 to 100
ESet all Channels to defaults (A/B: 0%, C/D: 50, Mode: Pulse)
HSwitch to High Power Mode, turns A/B back to 0%
JJoin Channels A/B. A is master.
KSet A/B to 0%
LSwitch to Lower Power Mode, turns A/B back to 0%
MxxSet mode to xx (See mode table)
UUnlink Channels A/B

Modes

IndexNameChannel C EffectChannel D EffectDescription
0PulsePulse FrequencyPulse PWM Type?Channels turn on/off synchronously
1AlternatingPulse FrequencyPulse PWM Type?Channels turn on/off asynchronously
2ContinuousPulse PWM Type?N/AChannels on continuously
3A PatternPulse FrequencyPulse PWM Type?Channel A plays pattern, Channel B on
4B PatternPulse FrequencyPulse PWM Type?Channel B plays pattern, Channel A on
5Asymmetric Power RampRamp SpeedN/ARamps from 0 to channel power % limit, sets to 0 repeats
6Symmetric Power RampRamp SpeedN/ARamps from 0 to channel power % limit, then ramps back to 0
7Frequency RampFrequency LimitN/ARamps channel frequencies from 0 to limit, then ramps back down
8Alternative Frequency RampFrequency LimitN/ASame as 7, except Channel A/B alternate
9Saw WaveFrequency RangeN/APlays saw wave with varying frequencies
10Sine WaveFrequency RangeN/APlays sine wave with varying frequencies
11RandomRandom RangePulse PWM Type?Random output
12StepStep SizePulse PWM Type?Steps between values
13JumpJump SizePulse PWM Type?Jumps between values