PreviousNext
Help > Software > The “RIDE” Operating Environment
The “RIDE” Operating Environment

RIDE (“Rationally Integrated Development Editor”) is where the user interacts with the system. In essence, it is a line text editor with built-in extra commands for file operations and system control.

When started, an access password is required in order to let the user to use the system. By default, there is no password, so a simple <Enter> key is all that is needed. The user is able to set their own password at a later stage later from within RIDE, if one is needed.

An important detail to start with - RIDE is not a typical editor but a line-based one. This means that what is shown on the screen is not necessarily how the text actually looks in the memory. Individual lines can be displayed, edited, and then other lines displayed below them in a non-sequential order. Using a line editor may seem confusing at first, especially to those who have never used one before, but also brings several benefits. First, it does not depend on the hardware in any way. The line editor will look the same way on a small 2-line LCD as it will look on a large terminal screen. Display height and width don’t matter. Another benefit is, once mastered, using a line editor actually could help make writing code easier.

For example, in a source of several hundred or several thousand lines of code, a developer might find themselves frequently scrolling up and down over large chunks in order to check and refer to different parts of code. In RIDE this is achieved by typing short one-character commands or sequences. In a short ‘dot-command’ line the developer could for example jump to a line and change something, then jump elsewhere change something else, and then jump back to the initial location. RIDE also supports repeating the same command defined number of times. This is useful when performing search and replace operations in the text.

Commands to the editor are entered starting with a ‘.’ character from the first position in a line. A single dot is sufficient for an entire command string. Spaces are in the command string are ignored.

Editing could be made in a script-like fashion by giving several commands at once to RIDE. For example, typing the command string “.S20 J55 C5” will tell RIDE to set line 20 as source from which lines can be copied or moved, then jump to line 55, and copy 5 lines there. In result lines 20, 21, 22, 23, and 24, will be copied starting from line 55 on, and lines which were originally following line 55, will be pushed further down.

There are several commands, such as those expecting a file name, which don’t allow more RIDE commands to follow on the same line, because the entire rest of the line is assumed as parameter.

A full help of all commands can be obtained by entering the .H command. Information about the current status of the editor can be seen by entering the ‘?’ command.

 

.h

 

>>> <Ctrl-Z> History             <Ctrl-N> Next line or add new

>>> <Ctrl-L> Clear full line  <Ctrl-Y> Clear to end of line

>>> <Ctrl-V> Clear screen    <Ctrl-U> Print line ruler

>>> '.' at start of a line marks a command line

>>> '@' represents the current line N     '#' source line N

>>> '!' is the number of lines incl current and to the end

.^ code    Set keyboard break code (default 3)

.N pw, ph  Page width and height (12-999 chars, 2+ lines)

.T width   TAB width (1-80)

.~         Equivalent to <Del>     .\  New line <Enter>

.* count   Repeat the following cmd for spec'd number times

.`text`    Insert txt at the cursor pos in the current line

.X [hpos]  Place cursor at spec pos within the current line

.[J] [< or >] [number]  Jump to line/prev/next; '.J' last N

.L [[P]count] List next N lines or until EOF [option Pause]

.P [[P]count] List previous N lines or from start   [Pause]

.I [count] Insert blank lines. One line if [cnt] is missing

.D [count] Delete lines. Only the current with no parameter

.S [line]  Set source line for copy and move ops     .H  .?

.C [count] Copy lines from source to current. Default num=1

.M [count] Move lines from source to current. Default num=1

.F [`text`]  Set text for find; w/o param, do find <Ctrl-F>

.R [`text`]  Set text for replace; w/o, find&repl  <Ctrl-R>

.E file    Execute command script from file

.= [file]  Run source in memory or from file

.O file    Open text file   .W file  Write  .A file  Append

./init drv:   Initialise drive  ./lock pwd   Lock access

./dir [path][mask]  List files. Accepted wildcards '?', '*'

./chdir [drv:][path]  Change drive and/or dir; Show current

./mkdir path  Make new dir      ./rmdir path  Remove empty

./del mask    Delete files             ./ren  mask_old , mask_new

./copy mask, mask   Copy files. Accepted wildcards '?', '*'

./list file   List text file    ./blist file  List bin file

./date YYMMDD Set date        ./time HHMMSS Set time :24h

./reset       System reset

 

In the text above, the parts enclosed in [] brackets are optional. Hence, a the most often used command ‘jump’ can be in the form of .J followed by an optional line number, or just a dot followed by the line number. A single .J command with no line number to follow will jump to the last line in the source.

As an example, the command ‘.JP’ will list the entire text from the start. The same effect could be achieved by executing ‘.1L’ too, with the difference being that in the first case the cursor will remain at last line in the source, whereas in the second, it will remain at the first. Adding one more ‘P’ to the form ‘.JPP’ will ensure the listing pauses properly at every page.

Commands for copy and replace require a ‘source’ line which marks the start of a block of one or more lines. The operation then takes from the source and copies or moves to the destination at the current line of the cursor.

Let’s write a very simple test program in C:

 

1: #include <stdio.h>

2: for (int i=0; i<3; i++) printf ("Hello, World!\r\n");

3: |

 

Let’s now execute it by typing the command ‘.=’, followed by <Enter>, in the current empty line:

 

  1: #include <stdio.h>

  2: for (int i=0; i<3; i++) printf ("Hello, World!\r\n");

.=

 

Hello, World!

Hello, World!

Hello, World!

 

  3: |

 

A program in the memory can be cleared with the command .1d!

Dissecting what the command actually does – it jumps to the first line, and then deletes the number of lines from there to the last one.

 

Other fundamental commands in RIDE are .o to open and load a file, and .w to write a file.

A file can be directly executed without loading into the editor with command .=

For example, .ohello.c will load the file “hello.c” in the editor, while typing instead .=hello.c will directly run the program.

 

To demonstrate some of the RIDE’s capabilities, here is another example.

Let’s consider writing this generic text:

 

 

  1: This is line 1

  2: This is line 2

  3: This is line 3

  4: This is line 4

  5: This is line 5

  6: |

 

Let’s to add ‘00’ in front of all numbers. This command will do the job: .1*!x6`00`>

After execution, the result will be

  6: 00|

 

This is a natural result of the execution. Just delete the excess characters by pressing Ctrl-L, and list the text: .p

 

  1: This is line 001

  2: This is line 002

  3: This is line 003

  4: This is line 004

  5: This is line 005

  6: |

 

If we now want to restore how it was before: .1*!x6~~>

RIDE is capable of executing complex command sequences and even have them executed as script from a file.