Prepared by Carl Poirier and Reza Ameli, graduate students, Université Laval; in co-operation with CMC Microsystems.
Xilinx offers a powerful Linux environment that can run on its MicroBlaze soft processor, PetaLinux. Using Xilinx software development kit (SDK), it is straightforward to get it to run either in the Quick Emulator (QEMU) or on the actual hardware. By using the SDK, which is based on the Eclipse Integrated Development Environment (IDE), you can extend the capabilities of the system by creating new projects that integrate automatically with the build of the PetaLinux system.
But, it can be challenging to integrate an existing project from source code that has its own makefile into the PetaLinux environment. In this application note, two particular cases are studied: the Lua and the Python interpreters. These language interpreters were chosen because they present many interesting features, such as:
- Scripts can be developed very quickly.
- Deploying an application or script on the platform does not require any cross-compiling; it just has to be copied over.
For simplicity, everything shown in this application note is demonstrated using an emulator. All software steps are valid on the actual FPGA — only the boot method differs when deploying PetaLinux on the hardware. Loading a platform image onto an actual FPGA is not explained in this application note.