Sun Microsystems V2.0 Welding System User Manual


 
15
Host
Sun SPOT
(“base station”)
Sun SPOT
(“Target”)
USB
802.15.4 radio
The Host can be any of the supported platforms (e.g. Windows PC, Mac). The Host application is a
J2SE program. The Target application is a Squawk Java program.
In the SPOT SDK and documentation the 64-bit addresses that identify SPOTs are expressed as
sixteen hexadecimal digits subdivided into four groups that are separated by dots for readability.
The Basestation may run in either dedicated or shared mode. In dedicated mode, it runs within the
same Java VM as the host application and can only be used by that application. In this model, the
host’s address is that of the basestation.
In shared mode, two Java virtual machines are launched on the host computer: one manages the
base station and another runs the host application. In this model, the host application has its own
system-generated address, distinct from that of the base station. Communication from host
application to the target is therefore over two radio hops, in contrast to one hop in the dedicated
case.
The main advantage of shared mode is that more than one host application can use the same
basestation simultaneously. Shared mode also allows multiple host processes to communicate with
each other using the radio communication stack, which makes it possible to simulate the
communication behaviour of a group of SPOTs using host applications (this simulation has
different timing characteristics).
The disadvantage of shared mode is that run-time manipulation of the basestation SPOT’s radio
channel, pan id or output power is not possible.
By default, host applications will use the base station in dedicated mode. To switch to shared mode,
insert this line into the
.sunspot.properties
file in your user root folder:
multi.process.basestation.sharing=true
Host applications that send or receive broadcasts, or that interact directly with the lower layers of
the radio stack, will behave differently in the two modes. This issue is discussed in more detail in
the section Broadcasting and basestations.
Set up
Connect a base station to your host computer. If you don't have a base station you can configure a
Sun SPOT to be used as the base station by issuing the following command:
ant selectbasestation
Then press the Sun SPOT’s control button and the Sun SPOT will act as a base station.