De1 Pin Assignments Csv File

  1. August 9th, 2012, 11:57 AM#1
    Join Date
    Aug 2012
    Posts
    3
    Rep Power
    1

    Importing .csv files for DE1 pin assignments

    I'm using the DE1_pin_assignments file for a design, and I used the board port names (SW[0], etc) in the design, but when I try to import the .cvs assignment file (Assignments - Import Assignments) I get this warning:
    Warning: Can't import assignments from Comma-Separated Value File Y:/118/Labs_F12/Lab4_Quartus_v2/DE1_pin_assignments.csv -- file does not contain at least 'Assignment Name' and 'Value' columns
    Warning: ,,,,
    and the pins are not assigned properly in the Assignments - Pin window.
    The .cvs file looks fine to me, and DOES have the "Assignment Name" and "Value" columns (along with "From", "To", and "Enabled" columns).
    Something I'm missing?

  2. Re: Importing .csv files for DE1 pin assignments

    Try the example design I posted in this thread:

    http://www.alteraforum.com/forum/showthread.php?t=35687

    de1_basic.zip contains a pin constraints Tcl file and top-level file. You can use it as the basis for any of your designs.

    Cheers,
    Dave
  3. August 9th, 2012, 12:25 PM#3
    Join Date
    Aug 2012
    Posts
    3
    Rep Power
    1

    Re: Importing .csv files for DE1 pin assignments

    Thank you, I've been successful in creating and downloading a few designs, but I'm particularly interested in getting the pin assignment import working. I didn't see anything in the zip file that was helpful (not a sample .csv file for example)
    Appreciate your quick reply though.

  4. Re: Importing .csv files for DE1 pin assignments

    Please read the readme.txt file, and then look at scripts/synth.tcl. That file creates a project and synthesizes the example design. The scripts/synth.tcl script calls procedures in scripts/constraints.tcl. That file contains all of the pin constraints.

    At a minimum, if you use the same top-level pin names in your design, you can use the Quartus Tcl console and

    tcl> source scripts/constraints.tcl tcl> set_default_constraints
    Ask questions if you need clarification.

    Cheers,
    Dave
    I didn't see anything in the zip file that was helpful (not a sample .csv file for example)

  5. Re: Importing .csv files for DE1 pin assignments

    By the way, if you do not like the way I have used scripts, then you can create your own set of pin constraints from my basic design. Run the synthesis script to create the example design, and then use Quartus to export a Tcl script or .csv script for the pin assignments, eg., use Project->Generate Tcl File for Project.

    Cheers,
    Dave
  6. August 10th, 2012, 09:58 AM#6
    Join Date
    Aug 2012
    Posts
    3
    Rep Power
    1

    Re: Importing .csv files for DE1 pin assignments

    Thank you for the advice about exporting a .csv file from the project. Once I realized this was accomplished by using the File Export command with the Pin Planner open, rather than "Assignments - Export Assignments, I got the .csv file. It is formatted very differently than the one that came with the boards, so I should be able to figure it out from here. Thanks again.

  7. Re: Importing .csv files for DE1 pin assignments

    Last edited by dwh@ovro.caltech.edu; August 10th, 2012 at 10:13 AM.
    I'm glad you figured it out.

    Once you have your project working, come back and look at the scripts, you will find they are more convenient than using the GUI and importing .csv files when rebuilding projects in newer versions of Quartus.

    Cheers,
    Dave
    Thank you for the advice about exporting a .csv file from the project. Once I realized this was accomplished by using the File Export command with the Pin Planner open, rather than "Assignments - Export Assignments, I got the .csv file. It is formatted very differently than the one that came with the boards, so I should be able to figure it out from here. Thanks again.

Similar Threads

  1. Replies: 0
    Last Post: July 6th, 2012, 11:30 PM
  2. Replies: 7
    Last Post: May 24th, 2010, 07:06 AM
  3. Replies: 10
    Last Post: October 20th, 2009, 11:10 PM
  4. Replies: 8
    Last Post: March 30th, 2009, 05:01 AM
  5. Replies: 0
    Last Post: September 2nd, 2005, 10:21 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

Forum Rules


Wentworth Institute of Technology

Department of Electrical Engineering and Technology

Elec 667 Advanced Programmable Logic

Assigning Pins using DE2_pin_assignments.csv

  1. Adding pin assignments can become a tedious chore as the NIOS II processors become loaded with more and more features.In our early labs since there are only a few switches and LEDs we are working with, this typically will be fairly short typing assignment.However, let’s take the opportunity to introduce a short-cut.Quartus II will allow users to import assignments using comma-separated-values files (*.csv).Altera uses COOP students from Canadian universities and one lucky student got to type 400+ assignments into a spreadsheet.This file is called DE2_pin_assignments.csv and is found on the Altera website:

ftp://ftp.altera.com/up/pub/Altera_Material/QII_9.1/Development_Boards/DE2/

  1. Save this file where you can find it later.
  2. To import these assignments into Quartus II for use with any project, click Assignments on the main menu and select Import Assignments.The following screen will appear:

  1. Browse to the DE2_Board_pin_assignments.csv location.ALSO, deselect Copy existing assignments into…. and then click OK. In the Quartus II message window you should see that 425 assignments were written.
  2. We have to deal with the FPGA unused pins.Some authors suggest they should be set to “inputs tri-stated with weak pull up”.Here is the click path to deal with that issue.
    1. Assignments>>Device.
    2. Click “Device and Pin option” button:

    1. Select the Unused Pins tab then used the pull down to see your options.

  1. Your application may not tolerate the output pushing ground out the I/O’s so consider “As output driving an unspecified signal” or the recommended “As input tri=stated with weak pull-up”.
  2. Also, Dual Purpose Pins, specifically nCEO which is used by the IRDA_TXD, needs to be changed.

    1. Click on the Dual-Purpose Pins tab
    2. Double-left click in the Value column for NCEO a pull down menu appears
    3. Select “Use as regular I/O”.
    4. Close out of here back to your project
  1. Suppose you’ve all ready used some assignment in a previous project and you want to reuse the file but you’ve deleted some IP.Those pins are still assigned.Here’s how you can clean them up.
  2. Assignment>>Remove Assignments looks interesting and I did notice some categories related to trouble shooting: Design Assistant, Programmer, Signal Probe, Signal Tap II, Incremental Compilation.

Figure 34 Subjects for further investigation at a later date.

  1. The check box at the bottom “Remove obsolete assignment” may work if we knew what Quartus considers an obsolete assignment.Click on Help and type obsolete assignments into the search box.Two topics come up that appear interesting.One of them gives us a definition: the removal of design assignments that no longer exist.We did make assignments for pins that have nothing connected to them externally or internally.What about the other two removal choices: global and instance?Include in your lab reports a screen shot of the Remove Assignments text box what boxes you checked to clean up the excessive pin assignments.
  2. Check the results by clicking Assignments>>Assignment Editor.

  1. I love this feature.You can import all the pins then trim away the ones you don’t want.The assignment of the global 50 MHz clock is correctly assigned to PIN_N2 and KEY(0) goes to the pin (PIN_G26) for the blue push button.The switches are assigned starting from the right end of the row and using the next 7 consecutively.LEDG go the right pins to turn on the green LEDs.Everything is correct.
  2. Include in your lab reports a screen shot of some of the pin assignments with the message about the number of assignments written.

0 thoughts on “De1 Pin Assignments Csv File

Leave a Reply

Your email address will not be published. Required fields are marked *