Personal Robotics
Learn About
Microcontrollers
This does take a bit of getting
used to, but it does work well once
you get the hang of it. One potential
drawback of this method is synchronization to other hardware that operates at a different (or even variable)
period than the IsoPod. This has been
overcome by adding data buffers to
the serial lines, for instance. The
buffer stores the data transparently in
the background, and presents it to
you when you ask for it. The one
exception here is that the CANbus
does not have a buffer like this in the
classical sense, but it does receive
eight bytes of data at a time. Since
the implementation of the buffers, I
have not been troubled by the synchronous nature of IsoMax.
This brings me to another point.
IsoMax, currently at V0.6, is a language in flux. While I believe it is finished, it is not fully accessorized to
the level that New Micros wants it to
be. This means that improvements
will happen and, in fact, have happened through the versions, but the
net effect is always a better platform
to work from.
Because the sheer volume of registers for hardware access is mind
numbing at times, IsoMax incorporates very high-level object-oriented
words. I like to call them template
words. They are great for the beginner, and can help you get something
up and running quickly, but some of
them are notoriously slow. The reason for their slowness is that every
time you use them, they have to
"pave the way" for themselves. They
make no assumptions; they configure
each and every register that is
required, each and every time they
are called. I usually start out with
them, and then if things show signs of
slowing up, I go through and replace
them with lower level code. They are
also handy for seeing how registers
get configured when you use them.
This makes them ideal as a teaching
tool.
Interestingly enough, IsoMax also
provides words called trinaries for
working with numbers at the bit level
that are lightning fast. Trinaries allow
FEBRUARY 2004
you to read, test, and set registers or
other memory locations at the bit
level. They are great for reading buttons or registers, or changing a regis-ter's contents rapidly.
Another unique thing about
IsoMax is the way it handles flow control. While its FORTH underpinnings
are available for stodgy FORTH
users, IsoMax prohibits the use of
loops in procedural sections entirely.
IsoMax allows you to have running
indexes to track how many times
things have been run, which is really
the essence of using a loop. In
IsoMax™, if you put an endless loop
inside the procedural portion of a
Virtual Machine, I guarantee you the
system will crash.
Another interesting addition to
IsoMax is finite state machine flow
control, or FSM. This is a novel
approach to programming embedded
systems, and has real applications in
the fields of control and robotics.
State machines perform a function
similar to if-then-else statements, but
the end result is a direct line to the
output you are interested in, not a
rat's nest of multiple nested conditionals. This results in easier programming and faster program execution,
because you only test inputs related
to a particular state, instead of all
possible inputs and computations
every time.
In IsoMax, a Mealy model of state
machine is used, as they tend to be
more efficient in the number of states
required. But Moore model machines
can also be simulated in the language. State machines are close in
concept to inference engines used in
expert systems and Artificial
Intelligence, and some are implemented that way. Today, state
machines are seeing wide usage in
the video game industry, and are particularly useful for communications
protocols, and compiler design.
Overall, the IsoPod is an extremely flexible system on a board. To illustrate this point, I have shelved my
PICs, 68332s, and 68HC11s in favor
of the IsoPod. It's the micro I like to
reach for first! NV
With theAthena
$6.95ea
•Basic Language
•I2c/SPI
• 15 IO Ports
•Hardware Serial IO
•No External Components
•Free Development Software
•Several Carrier Boards
•Super High Speed Version Available
•Educational Kits Available
•Upgrade Path to Dios
•Online Forums
•Tutorial
Athena Carrier Boards
Starting At $5.95
Educational Package
Athena Microcontroller
Athena EDU board
Bread Board
Wire Kit
LED’s
Capacitors
Resistors
Buttons
Software
$49.95
Free Software
Software has built-in
command wizard.
It contains syntax and
code examples for
each command.
Kronos Robotics
and Electronics
www.kronosrobotics.com
703-779-9752
fax 703-779-9753
You won’t believe this web site !!
•Online Store
•Free Information
•Free Software
•Projects
•PC Boards
Circle #151 on the Reader Service Card. 19