Coder Social home page Coder Social logo

fpgaprog's Introduction

FPGAprog

Unofficial port of the fpgaprog utility to work on OSX, which can be used to flash or load bit files to the Pipistrello board from Saanlima.

Installation

You need to install both libftdi and libusb-1.x, for example, using HomeBrew:

$ brew install libftdi libusb

Compilation is simply a matter of running make:

$ make
...
$ ls fpgaprog
fpgaprog

To flash bitfiles to the flash memory of your Pipistrello, you need to provide the correct bscan_spi bit file. Copy the file bscan_spi_lx45_csg324.bit to a place for later access.

For libftdi to work, you need to unload the FTDI serial driver that is loaded automatically by OSX:

$ sudo kextunload -b com.FTDI.driver.FTDIUSBSerialDriver

Usage

The fpgaprog program takes the following options:

-v                   Enable verbose output;
-j                   Detect JTAG chain, nothing else;
-d                   FTDI device name;
-f <bitfile>         Main bit file;
-b <bitfile>         bscan_spi bit file (enables spi access via JTAG);
-s [e|v|p|a]         SPI Flash options: e=Erase Only, v=Verify Only, p=Program Only or a=ALL (Default);
-c                   Display current status of FPGA;
-C                   Display STAT Register of FPGA;
-r                   Trigger a reconfiguration of FPGA;
-a <addr>:<binfile>  Append binary file at addr (in hex);
-A <addr>:<binfile>  Append binary file at addr, bit reversed.

To load (not flash) a bit file:

fpgaprog -v -f <bit_file>

To flash a bit file, you need to enable the SPI port to the flash chip through the JTAG port:

fpgaprog -v -f <bit_file> -b path/to/bscan_spi_lx45_csg324.bit -sa -r

License

The code is licensed under GPLv2. All modifications made by me (JaWi) are licensed under GPLv2 as well.

About

This code is based on the source code provided by Magnus Karlsson from Saanlima and can be found here:

http://pipistrello.saanlima.com/index.php?title=Welcome_to_Pipistrello#Fpgaprog_utility_program_download

fpgaprog's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

lujialiang

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.