Developing Software for Embedded Systems on FPGAs

 Hi I’m Nathan Knight, an embedded applications engineer at Altera Corp.  FPGA’s are becoming more common in embedded design.  If you haven’t already, you’re likely to see on in a future project.   Fortunately, the software development protocol, for an FPGA processor is similar to what you’re used to with an off the shelf processor.  Today I’m going to show you how easy it is to develop software for an FPGA based embedded system.  I’m going to do this by using the ES2 embedded evaluation kit.  The ES2 is a configurable 32 bit processor.  Because it configurable you can select the exact set of set CPU’s and interfaces that you need for your application.  So let’s get started.  First let’s turn on the ES2 embedded evaluation kit.  This kit is perfect for developers that are new to FPGA’s.  The kit includes hardware and software development tools, design examples, tutorials and all the documentation you’ll need to get started.  Everything is in the box.

The first thing you’ll see when the kit powers up is the application selector.  This displays all the applications that are pre-loaded on the SD card.  Let’s look at the system (DEMO).

Another unique capability of this kit is how the applications are loaded.  The board contains an FPGA with a NIOS2 processor, an SD memory card and a flash memory device.  To reconfigure first the processor copies the hardware image from the SD card to the memory device.  It does the same thing with the software image, and then the process instructs the FPGA to reconfigure itself from the flash memory. The new configuration with contains a nios2 processor then boots form the flash memory device.  The application starts.

This demonstration calculates the Mandelbrot fractal using two methods.  First, using hardware accelerators.  Normally you’d need a processor that is much higher speed, but by using much higher accelerators NIOS2 can achieve this performance by running at only 80MHz.  The hardware accelerators in this example were created by the Altera NIOS2 cetaH compiler.  This compiles AnzCC code into accelerators. As a comparison, this is the performance you can see when the accelerators are removed, which, as you can see, is much slower.  Now I’ll show you how to build your own application. 

The software development flow is probably similar to what you’re used to.  First, your hardware engineer hands off a file that contains a description of your NIOS2 system.  Next, the NIOS2 software development tools automatically generate a vsp from this input.  If your hardware designs changes, you only need to generate a new vsp.  You do not need to change your application software.  NIOS2 tools also make it easy to program your design for flash by providing a flash program or utility.  This utility also inserts a boot copier that boots your system from flash and copies the software to ram.  We provide examples that show you this entire flow. For this demonstration, a hard design has been created for us and we’ve generated a vsp.  This is typical C code we are building.  I could build the project right from NIOS2 IDD, but for this demo I’m going to build it from the command line.  

To build the project from the command line, just type MAKE.  After finishing the build we have an elf file, which is the executable file that we’ll be downloading for the board.  Loading the file can be done a couple of ways.  We’ll be using a USB cable.  First, we configure the FPGA to our hardware design.  Next we download the software application to RAM and run it.  You’ll see the spinning cube app running on the board.  You can also copy the hardware and software files to an SD card which will allow you app to appear in the application selector the next time you power up the board.  

To learn more or to order your own kit go to www.altera.com/nios2eval

최신 동영상

죄송합니다. 선택한 필터와 일치하는 결과가 없습니다.

개인정보 보호정책이 업데이트되었습니다. 잠시 시간을 내어 변경사항을 검토하시기 바랍니다. 동의를 클릭하면 Arrow Electronics 개인정보 보호정책 및 이용 조건에 동의하는 것입니다.

당사의 웹사이트에서는 사용자의 경험 향상과 사이트 개선을 위해 사용자의 기기에 쿠키를 저장합니다. 당사에서 사용하는 쿠키 및 쿠키 비활성화 방법에 대해 자세히 알아보십시오. 쿠키와 추적 기술은 마케팅 목적으로 사용될 수 있습니다. '동의'를 클릭하면 기기에 쿠키를 배치하고 추적 기술을 사용하는 데 동의하는 것입니다. 쿠키 및 추적 기술을 해제하는 방법에 대한 자세한 내용과 지침을 알아보려면 아래의 '자세히 알아보기'를 클릭하십시오. 쿠키 및 추적 기술 수락은 사용자의 자발적 선택이지만, 웹사이트가 제대로 작동하지 않을 수 있으며 사용자와 관련이 적은 광고가 표시될 수 있습니다. Arrow는 사용자의 개인정보를 존중합니다. 여기에서 당사의 개인정보 보호정책을 읽을 수 있습니다.