Quick Start

From Liquid Metal Wiki

Step 1 : Install Prerequisites[edit]

a. Java Virtual Machine[edit]

b. Eclipse[edit]

  • You need Eclipse 3.8 or later. If you don't have Eclipse, or your current Eclipse is too old, visit the Eclipse download site.
    • If you have never used Eclipse before, we recommend you start with the Eclipse IDE for Java Developers, but you can use other versions like Eclipse Classic or the Eclipse IDE for Java EE Developers if desired.
    • Make sure that your Eclipse 3.8 (or later) actually runs on your Java JRE 1.6 (or later).
If you have multiple versions of Java and are not sure which one your Eclipse is running on, then, with Eclipse running, choose Help->About Eclipse and then Configuration Details. Scroll down to the java.version property. By default, Eclipse runs on the JRE that is in the PATH. If this does not give the desired result, either change the PATH or arrange to start Eclipse with the -vm option as described in the eclipse/readme/readme_eclipse.html document that comes with your Eclipse installation.

Step 2 : Read our License Terms[edit]

  • Downloading or installing anything from this site implies agreement with the governing license.

Step 3 : Install Lime Development Toolkit (LDT) Plugin[edit]

  • In your running Eclipse, select Help->Install New Software. This will bring up a wizard page.
  • Press Add then fill in the two fields in the dialog. The name can be anything. The location should be http://lime.mybluemix.net/liquidmetal/update-site.
  • Check the "Liquid Metal Basics" category to install all three features contained in it: the Lime Development Toolkit Feature, Lime Support for HW Simulators, and Lime Basic Samples. The additional items under the Board-specific Support category are not usable without material licensed from third parties and additional instructions from the Liquid Metal team: do not install them at this time.
  • Complete the instructions, including agreeing to the license (if you do) and restarting Eclipse.
  • When Eclipse restarts, you should see a new "Welcome" page including a "Lime Development" link. Click this link to be taken to the introduction page of our (limited) built-in help for further instructions. However, the bulk of the useful documentation is here on this web site.

Step 4: Start Playing[edit]

a. Install sample projects[edit]

Begin by opening the Lime Perspective.

  • Window→Open Perspective→Other... and then select Lime.
  • The Lime perspective supports both Lime and Java development. Lime and Java projects are distinct but Lime projects may contain Java code as well as Lime code.

In the Lime Perspective you can use File→New→Lime Sample Projects to install one or more samples. The sample projects will appear in the Lime Package Explorer.

In general you can edit, navigate, debug and execute Lime code the way you would with Java code, until you are ready to attempt FPGA execution. Not everything will work because Lime support is not yet as robust as Java support in Eclipse.

b. Run helloworld on a JVM[edit]

Lime programs can run in the JVM as Java bytecodes. This is the quickest way to run a Lime program and verify functionality. Follow these instructions to run the sample "helloworld".

  • In the Package Explorer view, select the HelloWorld.lime file inside helloworld/src/helloworld
  • right-click (context menu) on HelloWorld.lime, select Run As and then select Lime Application
  • you should see "hello, world!" in the console window

c. Compile helloworld to HDL[edit]

Some Lime programs may be compiled to HDL (Verilog). This is necessary if you wish to coexecute your program using a JVM and an FPGA or FPGA simulator. To generate the HDL, follow these instructions.

  • In the Package Explorer view, select the HelloWorldFPGA.lime file inside helloworld/src/helloworld
  • right-click (context menu) on HelloWorldFPGA.lime, select Run As and then select Lime Application
  • You should see a new tab in the editors area labelled Backend Build Monitor. The messages there will be similar to the following text
No simulator or board is specified so only a build will occur, no launch
Build by pressing build button.
  • This is happening because we supplied a "launch configuration" for HelloWorldFPGA.lime that requests compilation to FPGA but does not specify any simulator. Later, you'll learn how to make and modify launch configurations to tailor this behavior. If you press Build you'll see messages like this
GraphExtractor: Extracted 1 graphs and 1 tasks.  1 tasks from main.
HDL Codegen: Processing task Task helloworld_HelloWorldFPGA1350_1371_1 (helloworld_HelloWorldFPGA_toLowerCase)
HDL source can be found in ...
\helloworld\src\helloworld\HelloWorldFPGA.lime
	=> ([ task toLowerCase ])
	   ^^^^^^^^^^^^^^^^^^^^^^
Code generated by FPGA backend
----------
  • In the area labelled Problems and Benefits the "Code generated by FPGA backend" message will be repeated with source line information. Double clicking there takes you to the place in the source where this "benefit" was conferred.
  • a new folder called LimeArtifacts should appear in your helloworld project. The generated HDL is located in a subdirectory called hdl. You may expand this folder to inspect the generated code.

Step 5: Moving on[edit]

If you've gotten this far: Congratulations! We recommend you pause here for a Mojito or Caipirinha, and then come back when ready.

Where do you want to go next? Some options include: