Your Amulet 5.7" module comes pre-programmed from the factory with sample µHTML pages stored in the onboard flash. If you haven't already done so, please take a few minutes to power up the Amulet module to review the pre-programmed demo. To power up the Amulet Starter Kit and begin GUI navigation, proceed as follows:
![]() |
Switch 1 ON --- Boot Mode Switch 2 OFF -- Program Baud Rate Switch 3 OFF -- RAM Test Switch 4 ON --- Touch Panel Mode |
By now, you should be familiar with the operation and navigation of the Amulet module. The next step is to use the Amulet HTMLCompiler to compile and program a GUI. In keeping with a long-standing programming tradition, this section introduces you to the Amulet development tools by guiding you through the creation of a "Hello, World!" program -- Amulet Style. Proceed as follows:
Launch the HTMLCompiler by whichever means you prefer.
The HTMLCompiler will open and compile home.htm and all other files that are linked from home.htm. When the conversion is complete the compiler will display:
<Successful Compile! Ready to Program 17 files (12032 bytes) into Flash>
NOTE: DO NOT click on the Program Flash button yet because you must first prepare the Amulet module for programming.
Before you can program your "Hello, World" program into the Amulet Flash, you must first select
a comm port and a programming baud rate.
To select a serial port for programming:
Now, you must connect the Amulet module to the PC. Before proceeding, remove the power from your Amulet module and make sure the module DIP switch settings on SW2 are as follows:
Switch 1 (Boot Mode) = ON (normal) (*See note below)
Switch 2 (Program Baud Rate) = OFF (115200) or ON (19200)
NOTE: This must match the bit rate set for the compiler.
Switch 3 (RAM Test) = OFF (disabled)
Switch 4 (Touch Panel Mode) = ON (Normal operation)
Connect one end of the 9-pin serial cable (included with the starter kit) to the serial port (J2) on the Amulet module and the other end to the assigned serial port on your computer. Now go ahead and apply power to the Amulet module.
* Note: Upon clicking on the Program Flash button in the Compiler window, the Compiler will attempt to send out an auto "wake-up" message to the Amulet controller. If the page currently being displayed is set up to use the same baud rate using the META tag (if META is not present, the default is 115200) as the Compiler's uP comm rate, then the Amulet controller will change to a generic "Please wait while programming flash..." screen and commence programming. If the page has a baud rate different than what the Compiler is set to, then you should set the uP comm rate in the Settings->RS232 dialog box to match the baud rate set by the META tag. This will allow the HTMLCompiler to wake up the Amulet at one baud rate and then program it at another baud rate. The only time you should have to set Switch 1 to OFF (program mode) is when the project you compiled locks up the Amulet OS to the point where it won't accept the wake up message or if the Amulet OS has been corrupted and you need to reload the OS.
Click on the Program Flash button in the Compiler window. If there is a comm port conflict, the compiler will display "Port is in use." If the compiler doesn't see the Amulet module, the compiler will display "Serial port timed out." Normally, though, the compiler will display a series of messages as each file within the page is flashed. When the flash programming is complete, the compiler will display:
<Successfully Flashed...>
Congratulations! You have successfully compiled and flashed your first Amulet uHTML page(s). The home page is now displayed on the LCD of the Amulet module. Navigate the GUI before proceeding to the next section.
Now, it is time to personalize your GUI. Using a text editor, such as Notepad or a "WYSIWYG" tool like Namo, open "home.htm" located in the \projects\tour\ subdirectory of the Amulet main directory. View the source code for the page and search for "Hello, World!" between the <BODY> and </BODY> tags.
Replace "World" with your name. For example, "Hello, World" should now read "Hello, John!"
Save the modified file and compile it.
Click on the Program Flash button.
Congratulations! You have successfully modified an Amulet uHTML page. A personalized version of the home page is now displayed on the LCD of the Amulet module. If desired, see Restoring
The Flash To Factory Configuration.
Before you embark on creating your own GUI from scratch, a few tips are in order:
The Easy GUI controller board comes equipped with a 2.5 mm external power connector (J3). The power requirement is 12 VDC @ 250 mA. A reset switch (momentary pushbutton, SW1 on the back of the board) resets the Easy GUI controller chip as well as LCD power.
|
CAUTION: Do not reverse the polarity on the power input. |
The Amulet 5.7" module can be powered up in different modes via the settings of the DIP switch (SW2). Some of the power up modes include: programming mode, run mode, RAM test mode, and touchpanel mode.
|
Switch 1 -- Boot Mode Switch 2 -- Flash Mode Baud Rate Switch 3 -- RAM Test Switch 4 -- Touchpanel Mode |
Boot Mode (Switch 1) -- This switch is monitored during a reboot to determine the operational mode of the controller board; ON is the normal mode and OFF is the FLASH program mode. Upon clicking on the Program Flash button in the Compiler window, the Compiler will attempt to send out an auto "wake-up" message to the Amulet controller. If the page currently being displayed is set up to use the same baud rate using the META tag (if META is not present, the default is 115200) as the Compiler's uP comm rate, then the Amulet controller will change to a generic "Please wait while programming flash..." screen and commence programming. If the page has a baud rate different than what the Compiler is set to, then you should set the uP comm rate in the Settings->RS232 dialog box to match the baud rate set by the META tag. This will allow the HTMLCompiler to wake up the Amulet at one baud rate and then program it at another baud rate. The only time you should have to set Switch 1 to OFF (program mode) is when the project you compiled locks up the Amulet OS to the point where it won't accept the wake up message or if the Amulet OS has been corrupted and you need to reload the OS.
Flash Mode Baud Rate (Switch 2) -- This switch sets the baud rate used during a Flash Reprogram. The ON position sets the hardware to 19,200 baud; OFF sets the hardware to 115,200 baud. This setting must match the baud rate selected in the Easy GUI HTMLCompiler software.
RAM Test (Switch 3) -- Turn this switch ON and then reboot the controller board to auto-execute a RAM test. A RAM test failure will result in a zero (0) volt signal on the MEM PASS test pad on the board; a pass will result in a 3.3 volt signal.
Touchpanel Mode (Switch 4) -- This switch should remain ON during normal operation. Turn this switch OFF and then reboot the controller board to begin a touchpanel calibration. The controller will display a series of three calibration targets. Use a stylus to touch the center of each target. If necessary, the controller will repeat the calibration. When calibration is complete, the controller will return to normal operation. The switch must be returned to the normal mode (ON) before the next reboot to continue normal operation.
NOTES:
A serial connection is required between the controller board and a personal computer in order to program uHTML pages into the FLASH memory of the controller board.
The serial parameters for communications between the Easy GUI client and the server are, as follows:
Baud Rate: 9600, 19200, 57600, or 115200bpsSee Communications Protocol for more information.
Parity: None
Data Bits: 8
Stop Bits: 1
Back to Welcome - Contact Amulet - Amulet Home