RichardE

Trying to get IntroToSpartanFPGABook to work using Xilinx web pack

Recommended Posts

Hi everyone,

I just got a Papilio 1 500K. I work as a software engineer and have been programming for ages but this is my first foray into programmable logic. I am more interested in learning VHDL than using a ready made micro at the moment so I thought I would start simple by following Mike Field's online book "Introducing the Spartan 3E FPGA and VHDL". I've downloaded the tools from the Xilinx web site and got a free license which seems to have been recognised. So far so good. But then it all starts to go wrong.

The main problem is that I seem to be using a more recent version of the software. Where the book says to click on the "Xilinx ISE Design Suite 13.3 Studio" icon I can find no such icon. After a bit of hunting I ran "Xilinx Platform Studio". This displays a message "A license was not found for the XPS feature" and when you click on "OK" it starts up the licence configuration manager which I already ran to get the licence in the first place. I close down the configuration manager.

Then the book says to select "File" then "New Project". No luck there. I went for the "Create New Blank Project" option. This looks promising (although different from the book). I give the project the name "Switches_LEDs.xmp", select a spartan3e, xc3s500e, vq100 abd speed grade -5 and leave everything else unmodified. Then I click "OK".

Xilinx Platform Studio starts up (release version 14.3). Now I'm really stuck. The book, in the section entitled "Step 2 - Create a new VHDL Module" says to right click on the design window, "on the FPGA device" and then choose "New Source". Where's the design window? I have a "Project" tab, an "IP Catalog" tab, a "Design summary" tab, a "Graphical design view" tab and a "System assembly view" tab. No idea what to right click here. Nothing looks right.

Working on guesswork I tried the "Hardware" menu, "Create or Import Peripheral" option which initially looks promising but then I get bogged down in selecting which kind of bus to attach to. All I want to do is connect two switch inputs to 2 outputs that drive LEDs. I suspect this is not the way to go.

So, my questions are:

1. Did I do right to run "Xilinx Platform Studio"?

2. Why am I getting warnings about a missing license?

3. How do I create a new VHDL module? The book says "Right-click on the design window, on the FPGA device, and choose "New Source". I can't find the design window, an FPGA device to click on or anything that when right clicked gives me the option to choose "New Source".

You will gather that I'm a bit out of my depth at the moment. Should I abandon the "Introducing the Spartan 3E FPGA and VHDL" book and try something else? That would be a shame because it looks like exactly what I am looking for, starting off with the absolute basics.

Share this post


Link to post
Share on other sites

RichardE,

Sorry for the short reply last evening but I was not near a Xilinx install.

For the Intro Book you will want to use Project navigator.

You will find Project navigator under ISE Design Tools menu whereas the Platform Studio is under the EDK menu and is used for working with embedded processing cores and peripheral blocks such as MicroBlaze

Share this post


Link to post
Share on other sites

Next slight problem. I don't have a LogicStart MegaWing because they don't seem to be available at the moment in the UK and I hesitate to order from the US because of possible problems with customs (I normally get stuff delivered to work and they rather object to paying customs duties for personal parcels) so I'm knocking together a few LEDs and switches based on the design of the LogicStart.

Is there a complete circuit diagram of the LogicStart MegaWing anywhere?

I based my switch on the partial circuit diagrams here: http://www.gadgetfactory.net/papilio-megawings/ This shows a 4K7 resistor between the common terminal of the slider switch and the Papilio input and the other two terminals are connected to the 3V3 rail and 0V. When I try this I find that I get either 0V or 1.22V at the input depending on the position of the switch (I'm using a toggle switch). 1.22V isn't high enough to register as a 1. I reckon there must be a pull down resistor inside the Spartan 3 forming a resistor divider which is why I don't get 3.3V. So ...

Is there a mistake on the partial circuit diagram? Is there really a 4K7 resistor in series with the input or have I done something wrong?

I will try without the resistor and see if that works.

Share this post


Link to post
Share on other sites

Took out the resistor and now the input swings between 0V and 3.3V when the switch is operated.

However, the output pins (which are connected to LEDs) don't seem to change state. I even tried writing a '1' to them and they still stay at 0V except for a brief period when the Papilio is plugged in to the USB socket when it shows 3.3V.

Why is this?

All I have is this:


library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
entity Switches_LEDs is
Port ( switch_0 : in STD_LOGIC;
switch_1 : in STD_LOGIC;
LED_0 : out STD_LOGIC;
LED_1 : out STD_LOGIC);
end Switches_LEDs;
architecture Behavioral of Switches_LEDs is
begin
LED_0 <= '1';
LED_1 <= '1';
end Behavioral;

and constraints of:


# Constraints for Papilio One
NET switch_1 LOC = "P3" | IOSTANDARD=LVTTL;
NET switch_0 LOC = "P4" | IOSTANDARD=LVTTL;
NET LED_1 LOC = "P16" | IOSTANDARD=LVTTL;
NET LED_0 LOC = "P17" | IOSTANDARD=LVTTL;

So why do both P16 and P17 stay low? (Papilio pins C14 and C15). Confused.

Share this post


Link to post
Share on other sites

Next slight problem. I don't have a LogicStart MegaWing because they don't seem to be available at the moment in the UK and I hesitate to order from the US because of possible problems with customs (I normally get stuff delivered to work and they rather object to paying customs duties for personal parcels) so I'm knocking together a few LEDs and switches based on the design of the LogicStart.

Is there a complete circuit diagram of the LogicStart MegaWing anywhere?

Hello RichardE, thank you for joining us in the forum and playing with the Papilio. :) I just got a batch of LogicStart MegaWing's and 10 of them are going to S.K. Pang's store in the U.K. so sometime in the next week or so there will be a viable option for you to buy one.

There is a full schematic for the LogicStart MegaWing on Github in PDF format.

Sorry folks. My fault. I forgot the generate "Generate programming file" step so the old bit file was being used over and over again. Oops.

Ha! I think we've all been guilty of that at some point. It takes a little while to get used to the new tools.

Jack.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now