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

Altera Primitives

Altera_Forum
Honored Contributor II
2,262 Views

Hello, 

I am new in this forum but nevertheless I hope someone can help me with my task. 

 

I am looking for the Altera primitives for designing,just the way we have in Xilinx. 

Does anyone know where do i find those primitives. 

 

Any help is welcome. 

 

Thanks 

Upal Bandopadhyay
7 Replies
Altera_Forum
Honored Contributor II
845 Views

Tools -> Megawizard is probably the best place to start. It will let you create PLLs, DSP blocks, and memories. Note that Altera users generally do not do as much designing at the primitive level(and to be honest, I think most X users are getting away from it too). Things like PLLs have to be done this way. But something like IO buffers are generally done with I/O assignments in the Assignment Editor, rather than manually instantiating a buffer on every I/O port. This keeps the code as generic as possible. For memory, Altera recommends inferring whenever possible(and most things can be inferred nowadays), and using the megawizard when necessary. And even there, there's a level of abstraction, i.e. X users used to instantaite physical memories and stitch them together with muxes, but the megawizard just has you build one that is the logic size you need(X allows this too now). Anyway, the following may be useful: 

http://www.altera.com/literature/ug/ug_low_level.pdf 

My point though, is that I've seen X users get frustrated with anything in the A flow that isn't just like the X flow, while A users get by just fine creating the same designs without complaints, so be sure to have an open mind.
0 Kudos
Altera_Forum
Honored Contributor II
845 Views

Thanks for the advice. 

 

Actually if i do not want to use QuartusII Software for simulating my design but some other tool then i need the primitives to be somewhere in the path.So in that case i need the source files of the primitives. 

How do we set up such an environment for simulation. 

 

Thanks in advance.
0 Kudos
Altera_Forum
Honored Contributor II
845 Views

this chapter of the Quartus II Handbook describes setting up Altera simulation libraries for ModelSim: 

 

http://www.altera.com/literature/hb/qts/qts_qii53001.pdf 

 

there are chapters for a couple of other simulators
0 Kudos
Altera_Forum
Honored Contributor II
845 Views

Thanks for pointing out to this document. 

 

However I find it very specific to ModelSim and QuestaSim Software.After reading some other documents its looks like the Altera primitives are built in the Quartus II Software.I have also searched for the primitives along with their definitions in the Altera installation directory but could not find everything i was looking for. 

 

Actually in our company we are now using GHDL as a simulation tool.I want to set up an environment where i have all the primitives needed to simulate a design in one place just like we have in Xilinx. 

 

In case of Xilinx all the primitives are present inside the installation directory at one place.Once given the path GHDL imports all the primitives needed to simulate the design.Actually we already have a design using Xilinx primitives.If we want to do the same using Altera how do i set up a similar environment for GHDL. 

 

I am specifically looking for Altera primitives and their definitions(simulation models) to place them altogether in one place, so that we can use GHDL to simulate our design the same way we did for Xilinx. 

 

Thanks in advance.
0 Kudos
Altera_Forum
Honored Contributor II
845 Views

Did you check the *.vhd and *.v files in quartus\eda\sim_lib? They should be understandable to all standard simulator tools, I think.

0 Kudos
Altera_Forum
Honored Contributor II
845 Views

Yeah the primitives you mentioned are understandable to GHDL as well. 

 

Is there any primitive for the dedicated adders inside ALM like the way we have carry chain primitive(CARRY4) in Xilinx.If not then how do i use the dedicated adder. 

 

Also when we use lut_input/output primitives how many luts are used up,as in how to know the lut count.for example, say we want to make a xor gate and we use two lut_input primitive and one lut_output primitive. 

Then what will be the lut count. 

 

I have attached a code with it. 

 

I got the libraries under "install dir/eda/sim_lib" but i need libraries without timing simulation.....these primitives use timing simulation. 

 

Any solution will be of great help.
0 Kudos
Altera_Forum
Honored Contributor II
843 Views

 

--- Quote Start ---  

but i need libraries without timing simulation.....these primitives use timing simulation 

--- Quote End ---  

 

I don't exactly understand your problem. You have been asking for simulation libraries, and these are the Altera functional simulations libraries. Some are representing timing behaviour as far as required for functional simulation, e.g. of PLLs. Mostly, they don't.
0 Kudos
Reply