Booting Up the Hardware

GA1000 and WA2000 devices are booted by calling the wln.boot method. There are some differences in how this is done on the GA1000 and on the WA2000:

GA1000

GA1000 does not have a ROM or a flash memory and its internal processor executes the firmware out of its RAM. Before the GA1000 module can start working, you need to upload its firmware into the module, and this is what wln.boot really does.

The firmware file is called "ga1000fw.bin" (the file can be downloaded from Tibbo website). The file must be added to your Tibbo BASIC/C project as a binary resource file.

Access to resource files is through the romfile. object. First, you open the "ga1000fw.bin" file with the romfile.open method, then pass the pointer to this file (value of the romfile.offset read-only property) to the wln.boot method:

** Tibbo Basic **


'boot it up
romfile.open("ga1000fw.bin")
If wln.boot(romfile.offset) Then
   'something is wrong, react to this
   ...
End If

The boot takes about 1.5 seconds to complete. The method will return 0- OK if the boot was completed successfully. At that moment, wln.enabled will become 1- YES.

The boot will fail (return 1- NG) if:

  • The Wi-Fi hardware is not powered, not properly reset, mapped incorrectly, or malfunctioned.
  • The offset to the firmware file is incorrect or the file is not included in your project.
  • The GA1000 is already booted and operational.

WA2000

The WA2000 stores its firmware in its flash memory, so there is no need to upload the firmware file on each boot. For WA2000, this method must be executed with its argument set to 0.

The boot process may take up to five seconds to complete. If wln.getmoduletype is executed before wln.boot is called, the boot time will be shorter because the Wi-Fi module type is already known. If wln.boot is called without the prior execution of wln.getmoduletype, the boot time will be longer, because it will also involve determining the Wi-Fi module type.

The boot will fail (return 1- NG) if:

  • The Wi-Fi hardware is not powered, not properly reset, mapped incorrectly, or malfunctioned.
  • The argument of the wln.boot is anything but 0.
  • The WA2000 is already booted and operational.

Booting up either module

To make your app ready for working with either Wi-Fi add-on module, determine the module type using wln.getmoduletype first, then call wln.boot in the right manner. An example of the code that does this is shown in Bringing Up Wi-Fi Interface.