The word "function'" is used a lot below. If you're not sure what this word means, click here.
- Open XBasic
- Be careful not to have any part of an XBasic window go
off the edge of the screen. XBasic doesn't handle this well and text in
the window will be smeared. Re-sizing XBasic windows, however, works
fine.
- In the main window,
click File,
Text-load and open S215-XB-PIC-simulation-template.x by double clicking on it.
- Save the program using another file name by first clicking File, Save, but don't hit ENTER yet.
- In the Select File
window that comes up, go to the upper right-hand corner and change the
file name; then, hit ENTER.
- Type in your
program (main routine) inside the Entry
function.
- Click the
single-floppy icon and save your program.
- Click File, Load and open your program.
- Text-load is
for viewing and modifying your program with all functions being visible
at once. You cannot run a program that has been loaded with Text-load. You must first save the program and reload it using Load (as opposed to Text-load).
- Once you've done a Load, you can only see one function at a time.
- Notice that only the
Prolog
appears.
- The Prolog is that
part of the program where all the functions you'll be using are listed. The Prolog itself is treated the same was as are functions. In other words, it's one of the things you can view when you've done a Load.
- To run your program,
click the red exclamation mark at the left on the third toolbar.
- Input and output will
take place in the Console
window.
- When doing input, be
sure the Console window is the
active window. (The active window has a dark
blue title bar.)
- If the Console
window isn't active, click anywhere on it.
- To modify a function
in your program, click the word Prolog
on the right side of the main window's title bar area.
- Next, double click
the function you'd like to modify.
- To modify other functions, click the same area where the
word Prolog
used to be. Then, double click the function you wish to modify.
- To make modifications
while viewing all the functions, click File,
Text Load
on the menu bar.
- When you're done
with the modifications, click the single floppy icon to save your
program.
- Then, click the
yellow folder below Edit.
- Open your program.
- Run your modified
program by clicking on the red exclamation mark.
|