Java hello in flash with hardware debug

Introduction

This demonstrates how to debug an application stored in flash. Normally when remotely debugging an application, the debugger is responsible for downloading the application to the board. However, when the application is stored in flash, there is nothing to download. In this case, a different debugger mode, network must be used. This communicates in the same way as the nw mode, but does not download the application.

When a flash application that is to be debugged in hardware is built, the linker places all the code segments into RAM, allowing breakpoints to be correctly set. This is automatically handled by the make and ant build environments.

Building the example

Change directory to the java_hello example
    cd %LF_HOME%\examples\java_hello_flash_debug

Rebuild the application
    lfmake clean all

Download the application to the board

Make sure that the applications are correctly built.
    lfflash --flash --mode=xip java_hello.raw

Debugging the example

Start the debugger with the network protocol and reset the development board.
    lf2debug network java_hello.lfa

Features

This example demonstrates the following SDK features.