## Ergebnisse der Monats-Archivsuche

Du hast den Blog nach dem Monat März 2014 durchsucht. Hier ist, was sich finden ließ.

• ## ZYBO board MIOs: Driving the LD4 LED using the BTN4 button

Just a quick and dirty non-tutorial solution on how to use the multiplexed I/Os (MIO/GPIO) to wire the BTN4 button on the ZYBO board (MIO50, the right one) to the LD4 LED (MIO7). Both are connected directly to the processing system and cannot be controlled from the fabric.

#include "platform.h"

#include "xparameters.h"
#include "xgpiops.h"
#include "xstatus.h"

#define GPIO_DEVICE_ID  XPAR_XGPIOPS_0_DEVICE_ID
#define OUTPUT_PIN		7	/* MIO7,  pin connected to LED */
#define INPUT_PIN		50	/* MIO50, pin connected to button */

int main()
{
int Status;
XGpioPs Gpio;
XGpioPs_Config *ConfigPtr;

// Initialize the system
init_platform();

// initialize the GPIO driver.
ConfigPtr = XGpioPs_LookupConfig(GPIO_DEVICE_ID);
if (Status != XST_SUCCESS) {
return XST_FAILURE;
}

// configure the LED pin as output
// status checks skipped for readability
XGpioPs_SetDirectionPin(&Gpio, OUTPUT_PIN, 1);
XGpioPs_SetOutputEnablePin(&Gpio, OUTPUT_PIN, 1);

// configure the button pin as input
XGpioPs_SetDirectionPin(&Gpio, INPUT_PIN, 0);

// wire the button to the LED (inverted)
while(1)
{
XGpioPs_WritePin(&Gpio, OUTPUT_PIN, !data);
}

return 0;
}


Note that when you open the system.mss file in SDK, you’ll find the ps7_gpio_0 entry under the Peripheral Drivers section. Click “Example” there to find more information.

• ## ZYBO with PlanAhead Tutorial

Because I desperately searched for something like that and found nothing, I just wrote a tutorial myself on how to start with the Xilinx PlanAhead workflow in ISE 14.7 when using the Digilent ZYBO board. Though I made this with the ZYBO in mind, the general workflow also applies to ZedBoard users and probably general Zynq boards as well.

It can be found at http://sunsided.github.io/zybo-tutorial/.

Basically the tutorial explains in about 120 pictures how to implement

LEDs <= Switches xor Buttons;


using the Xilinx tools. You can also find that nice picture of my fingers there, too.

If that ain’t something!

Edit:
Johann wrote a tutorial on using the ZYBO with Vivado on Linux. It can be found here.

• ## Xilinx SDK: make crashing with Interrupt/Exception

After exporting the implemented and generated project from PlanAhead to Xilinx SDK and having generated a Board Support Package, the build stops with an error due to make crashing with a rather dubious message along the lines of

make: Interrupt/Exception caught (code = 0xc00000fd, addr = 0x4227d3)


It turned out that this is due to an existing installation of Git, when the Git directory is added to the path. Specifically, sh.exe is the problem here and simply removing that from (or renaming it in) the Git installation directory solves the problem.

• ## Digilent ZYBO (Zynq-7010)

The ZYBO is an evaluation board for the Xilinx Zynq-7010 All-Programmable SoC made by Digilent. I got mine from Trenz Electronic at a reduced price for academic use.

I chose it over the ZedBoard (which I already have some experience with) because of the reduced size and since I don’t need the high-density I/O jack. It turns out though that the board is very small, yet quite heavy.

One thing to keep in mind though is that despite the rather large number of PMOD connectors, not all of them might be actually useful for a given task. The one on the left is connected to the Cortex processor, the right one is mixed analog/digital, and the three lower right ones are differential, leaving exactly the one on the lower left as a logic-dedicated PMOD for the FPGA (i.e. a single ended one that is connected directly to the FPGA, apart from the XADC one, of course).

I originally intended the board to be used to experiment with the OV7670 camera, but that might turn out to be a problem because of the PMODs. So: Caveat emptor.

Unfortunately, while Digilent’s own software, Adept, was now able to talk to the board too, it was still unable to recognize the chip.

Edit: After asking Digilent support I received a mail saying that the Zybo can’t be programmed with Adept, so that’s expected behavior.

Edit: I wrote up a quick-start tutorial for the ZYBO. You can read more about it here.

• ## Pipistrello rev. 2.0

I just received my Pipistrello board and it’s damn beautiful! (Unfortunately the site seems to be down sometimes; It looks like a DNS problem to me. Just try again later if the link does not work.)

On the front side, there’s the Spartan 6 LX45 FPGA (XC6SLX45-2CSG324), an FT2232H FTDI chip (one channel wired for custom use), the HDMI, USB, MicroSD and Headphone connectors, a button and six LEDs as well as a whole bunch of GPIOs.

On the bottom the DRAM chip can be found.

Shipment to Germany took less than a week (apart from being held back by customs) and in addition to a tracking number Magnus, the creator of the Pipistrello board, sent a mail regarding additional information to the board, as well as sources and example code.

The board comes pre-configured with a MicroBlaze prozessor running a Linux system that identifies itself as Linux Pipistrello-LX45 3.6.0-11207-ga0d271c #12 Sun Dec 9 11:56:59 EST 2012 microblaze GNU/Linux. CPU and architecture information can be grabbed with cat /proc/cpuinfo, as can be seen on the following screenshot of PuTTY.

All in all a very nice experience.