Chapter 3. GNU/Linux

Step 1. Type in the following program in text editor like gedit or kedit and save it as hello.c

#include <board.h>
#include <lcd.h>

int main()
{
        board_init();
        lcd_init();

        lcd_puts("Hello World!\n");
        return 0;
}

Step 2. Open a terminal, switch to the folder containing the C file and compile it using the following command.

$ zcc zkit-arm-1343 hello.c

Step 3. Fix the errors, if any and check the folder for executable file with the extension bin.

Step 4. Connect the development kit to the PC using the USB cable, and press the PROG button, to switch into programming mode.

Step 5. The board will be detected as a USB mass storage device, and will be mounted. Download the firmware using the following command.

$ lpc-flash hello.bin

Step 6. Press the RESET button, to execute the downloaded program.