element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Personal Blogs
  • Community Hub
  • More
Personal Blogs
Legacy Personal Blogs Got my first FPGA
  • Blog
  • Documents
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: cybermah
  • Date Created: 25 Jan 2018 9:24 PM Date Created
  • Views 891 views
  • Likes 11 likes
  • Comments 8 comments
  • lattice_semiconductor
  • fpga development kit
Related
Recommended

Got my first FPGA

cybermah
cybermah
25 Jan 2018

Browsing through element14's community post a few months back I notice some articles about FPGA's.  At first I dismissed them mainly because I didn't know what they were. And I didn't think I would ever use one or what one was.  As I continued to look around in the weeks to follow, there seem to be more and more post about FPGA's.  I though to myself I should probably do a bit of reading about them to see what they are all about.  Well, now my interest is peaked.  I started reading more and more about them, I watched some videos and looked a some code.  Unfortunately I convinced myself this is too much of a learning curve, I really didn't know where to start, what board to buy, what software to use, what programming format would be best to learn, and if I did buy one, would it scale, what other tools I would need to buy to program it and lastly, would the board I'd end up with be overkill.  So I dropped it.
image

A couple of weeks ago, Randall Scasny posted a question What's Stopping You Building Your Next Project with an FPGA? (Please, Don't Blame the Cost!).   My first thought was actually the cost, but I replied to the post with pretty much the same reasons listed above.  Then I started thinking about it and came the the conclusion that FPGA's are not going away and they are probably going to be the way of the future and I should probably learn it while its still feared by many.

 

The thing that really made me jump into FPGA's was a small little fact in a comparison of a MCU to and FPGA.  And that was MCU process instructions sequentially and FPGA's can process parallel.  I've been working on a project that needs to read at least 4 sensors at the exact same time and calculate the time differences between them.  I did find a IC that can do this called a Time to digital converter (TDC) and with some other hardware I believe I could accomplish it. But after watching some FPGA videos, I thought this may be the project I want to try to build using an FPGA since it would be able to read the inputs in parallel and in combination with a counter and some registers store the values for me to retrieve.

 

So, I took the plunge and purchased my first FPGA.  I was ordering some other parts and decided to look at the cost of FPGA boards and found this MachXO3L http://www.latticesemi.com/en/Products/DevelopmentBoardsAndKits/MachXO3LStarterKit.aspxmade by Lattice Semiconductor. The price of it was just under $35 Canadian.  The specs on it looks like its a huge overkill for what I wanted, but you need to start somewhere and it I figure I can use it for future projects.  The software to program it was free although there isn't a whole lot of examples for it, it does support Verilog and VHLD.

 

Well the MachXO3L came in today and it looks like the picture image.  I guess my next few blog entries should be around setting up the software, testing out the demo code, creating some simple logic gates and tying the inputs and outputs to the on board switches and leds.

 

Before I go, below is a circuit I would like to try to mimic in an FPGA for my first project, I don't know yet if it is even possible, but again I have to start somewhere.  If anybody reading this knows anything about FPGAs, could you comment to tell me if it is possible or am I just wasting my time on it.  If you need more information on how its suppose to work, let me know I can try to describe it out, I know the picture is a little hard to read.

 

image

 

Thanks

Dana.

  • Sign in to reply

Top Comments

  • fmilburn
    fmilburn over 7 years ago +3
    I am really curious to hear how you find the learning curve. Please continue to blog On this topic.
  • michaelkellett
    michaelkellett over 7 years ago +3
    I don't fully understand what your circuit is doing but I'm sure it can be done in an FPGA ! Try and describe what you want to happen at a higher level of abstraction - the sane way to program an FPGA…
  • genebren
    genebren over 7 years ago +2
    Dana, Way to jump in the FPGA pool! It sounds like you have a problem to solve and a tool to use, everything you need for a learning experience. I wish you luck on your project and your journey. Gene
  • michaelkellett
    michaelkellett over 7 years ago in reply to cybermah

    OK - definitely UART is best for you - since it only needs 2 wires. I2C only needs 2 wires but it's a pain.

     

    Are you happy using VHDL ?

     

    If so then try to find a simple VHDL project for your board and get it running.

     

    Then hack it to do something different.

     

    Or, since I bet your board has at least one LED, then get the LED to flash.

     

    If you have absolutely no idea how to get that to happen then let me know and I'll make a suggestion.

     

    MK

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • cybermah
    cybermah over 7 years ago in reply to michaelkellett

    I basically have a usb oscilloscope.  The software can act as a logic analyser on the 2 channels.  It says it can read uart, spi, and i2c but I have never tried to do it.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • michaelkellett
    michaelkellett over 7 years ago in reply to cybermah

    This isn't hard to do - I reckon the very simplest way to get your data back to the micro is via uart on the FPGA because it's so easy to code and debug. SPI is easy enough to code but harder to debug without a logic analyser.

     

    This leads me to my final question before suggesting you get started - what test gear do you have available ?

     

     

    MK

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • cybermah
    cybermah over 7 years ago in reply to michaelkellett

    The drawing is how I was going to do it if I was planning to do it if I had to use simple gates. 

     

    Basically how I would like it to work is:

    • From initial state, if any of the 4 inputs goes high, it starts a 32 bit counter and the corresponding register is set to the counter value  (this one should be near 0)
    • As the other 3 inputs go high it will set their register to the counter value
    • the reset pin will just reinitialize the counter and registers.

     

    I2C isnt necessary, it could be any protocol as long as I can get the register values back to a MCU.  The board I bought is suppose to have examples of I2C and SPI, so I just picked one. 

     

    I do agree the diagram does make it seem more complicated than it needs to be. What I need is much simpler than the diagram.

     

    Thanks

    Dana

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • jc2048
    jc2048 over 7 years ago

    That's a useful looking board.

     

    If you're new to using these kind of development tools, you might want to do something a little simpler first whilst you're getting the hang of the design flow.

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • More
    • Cancel
>
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube