Skip to content

DCC-EX Serial Command List

The following list is dynamically built from the CommandStation-EX code. It contains all the serial commands with brief definitions. In many cases the parameters are self explanatory. For example a tSpeed will always be -1..127 where 0=stop and -1=emergency stop. (See the Overview for more information on this and other common elements.)

This list appears in the order in which the command parser will detect command patterns.

Clicking on a command pattern will search this web site for pages which describe or use that command.

Note: This list is easily, automatically, generated but the various links spread about the documentation take a lot of effort and will be built over time.

<!>

Emergency stop all locos

<! P>

ESTOP Pause layout

<! Q>

ESTOP Query paused status

<! R>

ESTOP Resume paused layout

<#>

Request number of simultaneously supported locos

<+>

Complex WiFi AT command interface (Not ESP32)

<->

Clear loco state and reminder table

<- loco>

Remove loco state and reminders

</>

Stream EXRAIL status

</ AMBER signal>

Set Signal to Amber/Yellow

</ FREE section>

Free reserve on section

</ FREEALL>

Free all reserves

</ GREEN signal>

Set signal to Green

</ KILL ALL>

Kill all EXRAIL tasks

</ KILL taskid>

Kill specific EXRAIL tasks

</ LATCH latch>

Set pin latch

</ PAUSE>

Pause all EXRAIL tasks

</ RED signal>

Set signal to Red

</ RESERVE section>

Flag section as reserved

</ RESUME>

Resume all tasks

</ START loco route>

Start an AUTOMATION or sequence with a loco

</ START route>

Start a route or sequence

</ UNLATCH latch>

Remove pin latch

<0>

Power off all tracks

<0 MAIN>

Power off MAIN track

<0 PROG>

Power off PROG track

<0 track>

Power off given track

<1>

Power ON all tracks

<1 JOIN>

JOIN prog track to MAIN and power

<1 MAIN>

Power on MAIN track

<1 PROG>

Power on PROG track

<1 track>

Power on given track

<=>

List track manager states

<= track AUTO>

Update track to auto reverse

<= track DC loco>

Set track to DC

<= track DC_INV loco>

Set track to DC with inverted polarity

<= track DCX loco>

Set track to DC with inverted polarity

<= track EXT>

Set track to use external sync

<= track INV>

Update track to inverse polarity

<= track MAIN>

Set track to MAIN

<= track MAIN_AUTO>

Set track to MAIN with auto reversing

<= track MAIN_INV>

Set track to MAIN inverted polarity

<= track NONE>

Set track no output

<= track OFF>

Set track power OFF

<= track PROG>

Set track to PROG

<@>

Request all virtual msgs to this client

<@ display row text>

Display text on virtual LCD at row

<^>

List consists

<^ leadLoco follower [ follower2..7]>

Creates a consist from up to 8 loco ids (negative for loco in reverse)

<^ loco>

Uncouples any consist containing this loco

<a address activate>

Send dcc accessory command to linear address
activate: 0=deactivate, 1=activate

<A address aspect>

Send DCC extended accessory (Aspect) command

<a address subAddr activate>

Send DCC accessory command activate: 0=deactivate, 1=activate

<a address subAddr activate onoff>

Send DCC accessory command with onoff control activate: 0=deactivate, 1=activate onoff: 0=off, 1=on, 2=toggle

<B cv bitPosition bitValue>

Write cv bit

<b loco cv bitPosition bitValue>

POM write cv bit on main track

<c>

Report main track current (Deprecated)

<C PROGBOOST>

Configure PROG track boost

<C RAILCOM OFF>

Disable Railcom cutout

<C RAILCOM ON>

Enable Railcom cutout

<C RESET>

Reset and restart command station

<C SNIFFER OFF>

Turn sniffer output off

<C SNIFFER ON>

Turn sniffer output on

<C SPEED128>

Set all DCC speed commands to 128 step (default)

<C SPEED28>

Set all DCC speed commands as 28 step to old decoders

<C WIFI AP ssid password>

Set WiFi to AP mode with given ssid and password (in quotes)

<C WIFI AP ssid password channel>

Set WiFi to AP mode with given ssid and password (in quotes)

<C WIFI DEFAULT>

Set WiFi to default credentials

<C WIFI HIDDENAP ssid password>

Set WiFi to hidden AP mode with given ssid and password (in quotes)

<C WIFI HIDDENAP ssid password channel>

Set WiFi to hidden AP mode with given ssid and password (in quotes)

<C WIFI HOSTNAME hostname>

Set WiFi hostname (in quotes)

<C WIFI OFF>

Disable WiFi

<C WIFI ON>

Enable WiFi

<C WIFI ssid password>

Set WiFi ssid and password (in quotes, like "mySSID" and "myPassword")

<C WIFI TEMP ssid password>

Set WiFi ssid and password temporarily (in quotes)

<D ACK LIMIT value>

Set ACK detection limit mA

<D ACK MAX value>

Set ACK maximum duration uS

<D ACK MAX value MS>

Set ACK maximum duration mS

<D ACK MIN value>

Set ACK minimum duration uS

<D ACK MIN value MS>

Set ACK minimum duration mS

<D ACK OFF>

Disable PROG track diagnostics

<D ACK ON>

Enable PROG track diagnostics

<D ACK RETRY value>

Set ACK retry count

<D ANIN vpin>

Display analogue input value

<D ANOUT vpin position>

same as

<D ANOUT vpin position profile>

see

<D CABS>

Diagnostic display loco state table

<D CMD OFF>

Disable command input diagnostics

<D CMD ON>

Enable command input diagnostics

<D EEPROM numEntries>

Dump EEPROM contents

<D ETHERNET OFF>

Disable Ethernet diagnostics

<D ETHERNET ON>

Enable Ethernet diagnostics

<D EXRAIL OFF>

EXRAIL diagnostics off

<D EXRAIL ON>

EXRAIL diagnostics on

<D HAL RESET>

Reset all HAL devices

<D HAL SHOW>

Show HAL devices table

<D LCN OFF>

Disable LCN diagnostics

<D LCN ON>

Enable LCN Diagnostics

<D RAILCOM OFF>

DIsable Railcom diagnostics

<D RAILCOM ON>

Enable Railcom diagnostics

<D RAM>

Diagnostic display free RAM

<D RESET>

Reset and restart command station

<D SERVO vpin position>

Test servo

<D SERVO vpin position profile>

Test servo

<D TT vpin steps>

Test turntable

<D TT vpin steps activity>

Test turntable

<D WEBSOCKET OFF>

Disable WebSocket diagnostics

<D WEBSOCKET ON>

Enable WebSocket diagnostics

<D WIFI OFF>

Disable WiFi diagnostics

<D WIFI ON>

Enable WiFi diagnostics

<D WIFI SHOW>

Show WiFi status

<D WIT OFF>

Disable WiThrottle diagnostics

<D WIT ON>

Enable WiThrottle diagnostics

<E>

STORE EPROM

<e>

CLEAR EPROM

<f loco byte1>

Set loco function group (Deprecated use F)

<F loco DCCFREQ freqValue>

Set DC frequency for loco

<F loco function onoff>

Set loco function ON/OFF

<f loco group byte2>

Set loco function group (Deprecated use F)

<I>

List all turntables

<I id>

Broadcast turntable type and current position

<I id ADD position value angle>

Add turntable position

<I id DCC home>

Create DCC turntable

<I id EXTT vpin home>

Create an EXTT turntable

<I id position>

Rotate a DCC turntable

<I id position activity>

Rotate an EXTT turntable

<J A>

List Routes

<J A id>

List automation details

<J C>

Get fastclock time

<J C mmmm nn>

Set fastclock time

<J G>

Report gauge limits

<J I>

Report currents

<J L display row>

Direct current displays to LCS/OLED

<J M>

List stash values

<J M CLEAR ALL>

Clear all stash values

<J M CLEAR ANY loco>

Clear all stash entries that contain loco

<J M CLEAR stashId>

Clear given stash

<J M stashId>

get stash value

<J M stashId loco>

Set stash value

<J O>

List turntable IDs

<J O id>

List turntable state

<J P id>

List turntable positions

<J R>

List Roster

<J R id>

Get roster for loco

<J T>

Get turnout list

<J T id>

Get turnout state and description

<K blockId loco>

Loco entering Block

<k blockId loco>

Loco exiting block

<L>

LCC/CBUS adapter introducing self

<L eventId>

LCC incoming event

<M ignore d0 d1 [d2 d3 d4 d5]>

Send up to 5 byte DCC packet on MAIN track (values in hex). The ignore value is for backward compatibility, use 0.

<m LINEAR>

Set Momentum algorithm to linear acceleration

<m loco accelerating braking>

Set momentum for loco

<m loco momentum>

Set momentum for loco (accel and braking)

<m POWER>

Set momentum algorithm to very based on difference between current speed and throttle setting

<N>

List current and alternate defines for SensorCam base vpins

<N cmd value>

execute SensorCam command with parameters

<N Q>

Lists full set of SensorCam sensor states

<o vpin>

Set neopixel on(vpin>0) or off(vpin<0)

<o vpin count>

Set multiple neopixels on(vpin>0) or off(vpin<0)

<o vpin r g b>

Set neopixel colour

<o vpin r g b count>

Set multiple neopixels colour

<P ignore d0 d1[ d2 d3 d4 d5]>

Send up to 5 byte DCC packet on PROG track (all d values in hex). The ignore value is for backward compatibility, use 0.

<Q>

List all sensors

<R>

Read driveable loco id (may be long, short or consist)

<R CONSIST>

Read consist id on PROG track

<R cv>

Read cv

<r loco cv>

POM read cv on MAIN track

<R LOCOID>

Read loco id (ignoring consist) on PROG track

<S>

List sensors

<s>

Command station status

<S id>

Delete sensor

<S id vpin pullup>

Create Sensor

<T>

List all turnouts

<T id>

Delete turnout

<T id addr subAddr>

Create DCC turnout (Deprecated use )

<T id C>

Close Turnout

<T id DCC addr subAddr>

Create DCC turnout

<T id DCC linearAddr>

Create DCC turnout

<T id SERVO vpin closedValue thrownValue>

Create Servo turnout

<T id SERVO vpin closedValue thrownValue profile>

Create Servo turnout profile: 1=Fast, 2=Medium, 3=Slow

<T id T>

Throw Turnout

<T id value>

Close (value=0) or Throw turnout

<T id vpin closedValue thrownValue>

Create SERVO turnout (Deprecated use )

<T id VPIN vpin>

Create pin turnout

<T id X>

List turnout details

<t loco>

Request loco status

<t loco tSpeed direction>

Set throttle speed(0..127) and direction (0=reverse, 1=fwd)

<V cv bitPosition bitValue>

Fast read bit with expected value

<V cv cValue>

Fast read cv with expected value

<W CONSIST loco>

write consist address on PROG track

<W CONSIST loco REVERSE>

Write consist address and reverse flag on PROG track

<W cv bitPosition bitValue>

Write cv bit on prog track

<W cv cValue>

Write cv value on PROG track

<W loco>

Write loco address on PROG track

<w loco cv cValue>

POM write cv on MAIN track

<y vpin EQ eq>

Set sound EQ

<y vpin FOLDER folder>

Switch to sound track folder

<y vpin PAUSE>

Pause sound

<y vpin PLAY trackNumber>

Play sound track with default volume

<y vpin PLAY trackNumber volume>

Play sound track with volume

<y vpin REPEAT trackNumber>

Repeat sound track with default volume

<y vpin REPEAT trackNumber volume>

Repeat sound track with volume

<y vpin RESET>

Reset sound module

<y vpin RESUME>

Resume sound

<y vpin STOP>

Stop playing sound

<y vpin VOL volume>

Set sound volume

<Z>

List Output definitions

<Z id>

Delete output

<Z id active>

Set output

<Z id pin iFlag>

Create Output

<z signedVpin>

Set pin. HIGH iv vpin positive, LOW if vpin negative

<z vpin analogue>

Write analogue device value

<z vpin analogue profile>

Write analogue device using profile number (Fade or servo movement)

<z vpin analogue profile duration>

Change analogue value over duration (Fade or servo move)

Build info:

Autogenerated from devel/DCCEXCommands.h at Sat Aug 22 03:54:14 UTC 2026