You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/exrail/exrail-command-reference.rst
+26-15Lines changed: 26 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -26,6 +26,7 @@ See Also:
26
26
- :doc:`/exrail/examples`
27
27
28
28
.. warning::
29
+
:class: warning-no-clear
29
30
30
31
Do not waste your time asking ChatGPT, Copilot or Gemini to create EXRAIL scripts. They do not understand EXRAIL and will get it wrong 100% of the time.
31
32
@@ -626,6 +627,12 @@ Completes a Sequence/Route/Animation/Event handler, and any other automation def
626
627
*Parameters:* |BR|
627
628
|_| > none
628
629
630
+
.. Note::
631
+
632
+
You do not need to use ``DONE`` if you are using ``FOLLOW(id)`` or ``RETURN`` to end the sequence, as these also indicate the end of the sequence.
633
+
634
+
The currently selected loco will stop moving unless you have used a ``FOLLOW(id)`` or ``RETURN`` to pass control to another sequence. |BR| To prevent this use ``SETLOCO(0)`` before the ``DONE`` statement to deselect the current loco.
635
+
629
636
|hr-dashed|
630
637
631
638
.. _endtask:
@@ -647,7 +654,7 @@ Completes a Sequence/Route/Animation/Event handler, and any other automation def
647
654
``CALL( id )`` - Branch to a separate sequence
648
655
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
649
656
650
-
Branch to a separate sequence, which will need to RETURN when complete.
657
+
Branch to a separate sequence, which will need to `RETURN` when complete. The current sequence is paused until the called sequence has completed.
651
658
652
659
*Parameters:* |BR|
653
660
|_| > **id** - id for the sequence/route/automation to branch to
@@ -705,7 +712,9 @@ Return to the calling sequence when completed (no DONE required).
705
712
``FOLLOW( sequence_id )`` - Branch or Follow a specified sequence
Branch or Follow a specified sequence. This lets us do clever things like performing a different sequence depending on whether a turnout/point is CLOSED or THROWN, as well as simple things such as the example above where we keep looping through the same sequence.
715
+
Branch or Follow a specified sequence. The current sequence ends and control is passed to the specified sequence.
716
+
717
+
This lets us do clever things like performing a different sequence depending on whether a turnout/point is CLOSED or THROWN, as well as simple things such as the example above where we keep looping through the same sequence.
709
718
710
719
*Parameters:* |BR|
711
720
|_| > **sequence_id** - id for the sequence/route/automation to branch to
@@ -798,6 +807,21 @@ Starts a new task at the given route/animation/sequence and share the current lo
798
807
799
808
|hr-dashed|
800
809
810
+
.. _sendloco:
811
+
812
+
``SENDLOCO( loco, route )`` - Start route/sequence with a specified loco
Start a new task send a specified loco along a specified route/sequence.
816
+
817
+
The sequence is started in parallel to the current sequence, so the current sequence continues immediately after the SENDLOCO() command, without waiting for the new sequence to complete.
818
+
819
+
*Parameters:* |BR|
820
+
|_| > **loco** - DCC address of your loco |BR|
821
+
|_| > **route** - route to execute using the specified loco
822
+
823
+
|hr-dashed|
824
+
801
825
.. _delay:
802
826
803
827
``DELAY( delay )`` - Delay the sequence a number of milliseconds
@@ -2745,19 +2769,6 @@ Set the loco address for this sequence.
2745
2769
2746
2770
|hr-dashed|
2747
2771
2748
-
.. _sendloco:
2749
-
2750
-
``SENDLOCO( loco, route )`` - Start route/sequence with a specified loco
Copy file name to clipboardExpand all lines: docs/exrail/getting-started.rst
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -595,7 +595,7 @@ Following commands (e.g. ``SPEED (50)`` ) will be directed at the loco chosen.
595
595
Referencing Loco Functions
596
596
--------------------------
597
597
598
-
You can use ``FON( function_no )`` and ``FOFF( function_no )`` to activate and deactivate loco functions… eg sound horn. The loco that the command will be directed to will be the one previously chosen using ``SETLOCO( loco_dcc_address )`` or ``SENDLOCO( ( loco_dcc_address, route_id )``.
598
+
You can use ``FON( function_no )`` and ``FOFF( function_no )`` to activate and deactivate loco functions… eg sound horn. The loco that the command will be directed to will be the one previously chosen using ``SETLOCO( loco_dcc_address )`` or ``SENDLOCO( loco_dcc_address, route_id )``.
0 commit comments