Thursday, January 2, 2025

FGPA's 2025 part I: Intel/Altera/Quartus

Hello there, it's a new year, and I am jumping back down the FPGA rabbit hole:

Tesaric DE10-LITE. The URL for the CD, on a sticker glued by the manufacturer to the board, 404's. Sorry.

I last worked with FPGA's a couple of years ago almost to the day (post here)

This time I wanted to see if I could figure out how to use an FPGA for accurate data acquisition (the frequency counter project/multiplier, for instance: here).  

I got out my tinyFPGA BX for this but soon found out it's listed on Digikey as "obsolete" and not currently for sale.... 

Hello? It's only a couple of years old but, whatever.

Digging into alternatives, wow, the FPGA market is figure 8 trailer racing: 

In a nutshell: the FPGA landscape apparently changes more quickly and more often than my chonies.

Older, lower density FPGA's are being phased out:

I bought this Altera Cyclone II development board a few years ago for next to nothing, but recently discovered that the current Quartus programming IDE no longer supports it. Sorry. I might be able to get an older version of Quartus working on an Windows 7 VM and revitalize this dinosaur? 

Regardless, as a birthday gift to myself, or maybe because I love punishment, I bought a few newer FPGA offerings and will try to get their toolchains going in the next few posts.  

This time it's Intel, Altera, and Quartus. But first.....

PCBWAY--THIS BLOG'S HUMBLE SPONSOR

No matter what FGPA I end up using, if I have to fab up a board for it, my stop will of course be my sponsor, PCBWAY.  They manufacture small quantities of PCB's for very affordable prices and work and ship very quickly. They also do injection molding, 3D printing, assembly, and a lot more. You can help out this blog by checking them out here.

A QUARTUS LOW?


Quartus Prime Lite Edition is the free offering from Intel (Wait--Altera? or these guys?) you can use to program supported Intel FPGA's.

As far as I can tell, Quartus Prime Lite is the same software with the same features as the >$2k USD  licensed versions but only supports Altera's current line of lower density FPGA's. 

Good enough for what we do? Probably, yes!

I downloaded and ran the 28MB SFX installer for Windows: here. Some how-to videos such as the one here demonstrated downloading tricks needed to get Quartus Prime Lite to work for free, but nope, the single file linked above pulled in necessary files and the install was simple. 

Best of all--no license was needed! 

Warning: As mentioned above, the FPGA scene is always changing fast, so who knows when the links in this post will break....if you want software so you can program your FPGA, get it soon!

For hardware: after some research, a good bang-for-the-buck option supported by the current version of Quartus Prime Lite is the Tesaric DE10-LITE.  
 
There are less expensive Altera options, but for now, I wanted to make sure I could get the toolchain to work and a lot of documentation pointed to Tesaric.

The video I followed to get the toolchain up and running is Olawale Akinwale's offering here

This was a helpful video, but Olawale showed me how to do something wrong before showing me how to do it right--educational, but, time consuming. You might want to watch the whole video before attempting to get your FPGA board working.

For Verilog code I used the same .v file the content he used:

module lab1_1 (SW,LEDR);
input [9:0] SW; //slide switches
output [9:0] LEDR; // red LEDs
assign LEDR = SW;
endmodule


A few things not mentioned in the video:

  • The USB-Blaster driver did not install correctly on my windows 11 system during the initial Quartus install. 

To get that going I ran the DPINST.exe program that was installed along with Quartus. On my Windows PC I found the app here: C:\intelFPGA_lite\23.1std\quartus\drivers.  




I found other videos and forum posts saying to fix this issue use Windows device manager--but for Windows 11, no, that didn't work.  Running DPinst.exe fixed things; I can now see "USB-Blaster [USB-0] in the "hardware setup" dialog.

  • To blow your verilog code get into the firmware of the dev board--and not have your work wiped out each power cycle--the Programmer UI needs to be set to run the .pof file and "program/configure" needs to be set as you see here:



Beyond that the video was spot-on.

After uploading to the FPGA deb board, and solving the issues above, each slide switch turned on or off its corresponding LED. 

It worked! Cool!!! 

str = 'F' + str.Substring(1);


Say what you will about Intel, Quartus is a super powerful piece of software.

Next, I found out that you can do low code/no code Verilog development using its "schematic" feature. Video is here.  

Using that I drew up a few AND gates and converted the schemo into verilog code:

"File" > "Create/Update" > "Create HDL Design File for Current File" (I had to have the .v overarching project open for this export to work).

I got this:


module lab1_3(
SW0,
SW1,
SW2,
SW3,
LEDR0
);


input wire SW0;
input wire SW1;
input wire SW2;
input wire SW3;
output wire LEDR0;

wire SYNTHESIZED_WIRE_0;
wire SYNTHESIZED_WIRE_1;




assign SYNTHESIZED_WIRE_0 = SW0 & SW1;

assign SYNTHESIZED_WIRE_1 = SW2 & SW3;

assign LEDR0 = SYNTHESIZED_WIRE_0 & SYNTHESIZED_WIRE_1;


endmodule


QUARTOUTTRO?  QUARTUSTRO?  QUARTOJUMBO? 


Between these features and AI maybe I can do useful FPGA coding without having to learn a ton of Verilog.....

Obviously I have a very, very long way to go here, but, figuring out this new toolchain was a lot of fun.

Next up I am going to look into current offerings for Lattice--thankfully, they are still around, have not been recently acquired by a wig company, and in that they have some lower-end offerings and seem to care about the hobbyist and semi-pro community, might be a better fit for DiWHY.  

We will see.
 


FGPA's 2025 part I: Intel/Altera/Quartus

Hello there, it's a new year, and I am jumping back down the FPGA rabbit hole: Tesaric DE10-LITE. The URL for the CD, on a sticker glu...