Programmable Devices
CPLDs, FPGAs, SoC FPGAs, Configuration, and Transceivers
20693 Discussions

Using RTOS for NIOS 2

Altera_Forum
Honored Contributor II
1,068 Views

Hi all, 

 

I'm wondering if there are any significant advantages of using RTOS in FPGA compared to RTOS in hard core microprocessor. 

 

regards, 

Michael
0 Kudos
1 Reply
Altera_Forum
Honored Contributor II
305 Views

Hi Michael, 

 

 

--- Quote Start ---  

 

I'm wondering if there are any significant advantages of using RTOS in FPGA compared to RTOS in hard core microprocessor. 

 

--- Quote End ---  

As far as processor cores go, there is no major difference between an FPGA soft-core processor, an FPGA hard-core processor, or an external processor chip.  

 

Whether or not you can get the performance you require is a processor selection issue. For example, if you need 50MHz performance, a NIOS or external microcontroller would work. However, if you need 1GHz performance, you might want an external processor, or a newer generation FPGA with 1GHz hard-IP processor. 

 

Whether or not you run an RTOS is purely up to you. If processor cost is an issue and you need to maximize the CPU usage, then an RTOS is a good way to go (though an RTOS can be expensive too). If cost is less of an issue, time-to-market is important, or you want to maximize programmer availability, then an external processor running Linux might be the way to go. 

 

For example, I have a large DSP-based system that runs uCOS-II (~70% CPU usage), and I have to make all the code changes. I have another large PowerPC-based system running Linux (~20% CPU usage), and there are other programmer resources that can deal with code maintenance. 

 

As far as FPGA real-estate goes, I have yet to buy off on the advantages of a Linux-class processor in an FPGA. This type of processor needs DDR memory, Flash, RTC, etc., which consumes pins on the FPGA. My applications tend to be I/O bound, so I cannot afford to lose those pins. A PowerPC processor with a high-speed SERDES, or serial RapidIO interface costs very little in terms of FPGA pin use, and the processors themselves are ~$100 (Freescale PowerQUICC II/III processors). 

 

You'll have a different set of design decisions, but that gives you a few things to think about. 

 

Cheers, 

Dave
0 Kudos
Reply