Introduction to FPGA Part 2 - Getting Started with Yosys, IceStorm, and Apio | Digi-Key Electronics
DigiKey
@digikeyAbout
DigiKey Corporation is an industry leader in the distribution of quality electronic components, including Electromechanical, Interconnect, Optoelectronics, Passives, Power, RF & Wireless, Semiconductors, Sensors, Thermal Products and Test Tools. Whether small quantities for prototype design or large volumes for production, the company is committed to product availability, service and performance. Search, find, buy from a manufacturer authorized distributor. Same-day shipment, next-day delivery on orders entered by 8:00pm Central Time (USA). Access product information, datasheets, application notes, product photos, catalog, industry links can be found at http://www.digikey.com
Video Description
In this tutorial, we install the open-source iCE40 FPGA toolchain, which consists of apio, yosys, nextpnr, and Project IceStorm. A field-programmable gate array (FPGA) is an integrated circuit (IC) that lets you implement custom digital circuits. You can use an FPGA to create optimized digital logic for things like digital signal processing (DSP), machine learning, and cryptocurrency mining. Because of the FPGA’s flexibility, you can often implement entire processors using its digital logic. You can find FPGAs in consumer electronics, satellites, and in servers used to perform specialized calculations. In this series, we will see how an FPGA works and demonstrate how to create custom digital logic using the Verilog hardware description language (HDL). In the previous episode (https://youtu.be/lLg1AgA2Xoo), we examined how an FPGA works and why you might want to use it in your projects or products. In this episode, we demonstrate how to install apio and the various open-source tools required to build and upload designs to a Lattice iCE40 development board. The solution to the challenge at the end of the episode can be found here: https://www.digikey.com/en/maker/projects/introduction-to-fpga-part-2-toolchain-setup/563a9518cd11466fb6a75cf3cb684d6d All code examples and solutions for this series can be found here: https://github.com/ShawnHymel/introduction-to-fpga Lattice iCE40 product page (with pinout spreadsheet and datasheet): https://www.latticesemi.com/en/Products/FPGAandCPLD/iCE40 We install the apio tool (https://github.com/FPGAwars/apio), which will help us install and control other lower-level tools required to synthesize, simulate, and upload our FPGA designs: - Synthesis: http://yosyshq.net/yosys/ - Simulation: http://gtkwave.sourceforge.net/ - Place and route: https://github.com/YosysHQ/nextpnr - Package: icepack (as part of Project IceStorm: https://github.com/YosysHQ/icestorm) - Upload: iceprog (as part of Project IceStorm: https://github.com/YosysHQ/icestorm) The apio documentation can be found here: https://apiodoc.readthedocs.io/en/stable/source/installation.html Note that there might be some differences between the various operating systems (e.g. Windows, macOS, Linux) during installation. I demonstrate installation on Windows and try to point out the differences from other operating systems. Important! At this time, the latest version of apio (0.7.6) has several issues. Until those issues are resolved, I recommend sticking to v0.6.7 (as shown in the video). You can read about some of those issues here: https://github.com/FPGAwars/apio/issues. Apio includes several examples to get you started. We demonstrate one such example that illuminates all of the onboard LEDs. We finish by issuing a challenge to modify the leds.v example to turn off one of the LEDs. Product Links: https://www.digikey.com/en/products/detail/lattice-semiconductor-corporation/ICE40HX1K-STICK-EVN/4289604 Related Videos: https://www.youtube.com/watch?v=z8Oldd-nrfs https://www.youtube.com/watch?v=5kNXX67mchE https://www.youtube.com/watch?v=iwcxLQ6AB88 Related Project Links: https://www.digikey.com/en/maker/projects/introduction-to-fpga-part-2-toolchain-setup/563a9518cd11466fb6a75cf3cb684d6d Related Articles: https://www.digikey.com/en/pdf/r/renesas-electronics-america/powering-fpga-applications https://www.digikey.com/en/videos/d/dsp/edge-machine-deep-learning-on-fpga https://www.digikey.com/en/product-highlight/l/lattice/ice40-fpga-family-developmental-solutions Learn more: Maker.io - https://www.digikey.com/en/maker Digi-Key’s Blog – TheCircuit https://www.digikey.com/en/blog Connect with Digi-Key on Facebook https://www.facebook.com/digikey.electronics/ And follow us on Twitter https://twitter.com/digikey
Upgrade Your Everyday
AI-recommended products based on this video

Kasa Smart Outdoor Smart Plug by TP-Link (KP400) - Smart WiFi Outlet with 2 Sockets, IP64 Waterproof, Works with Alexa and Google Home, 2.4GHz WiFi Required, No Hub Required, Sunset & Sunrise Offset

Oraolo Open Ear Headphones, Bluetooth 5.4 Wireless Earbuds with Stereo Sound, ENC Clear Call, 21H Playtime, Type-C Charging, Touch Control, IPX6 Waterproof Open Ear Clip-On Earbuds for outdoor workout

Open Ear Wireless Earbuds, Sports Bluetooth Headphones with Real Time Translation, 80Hrs Playtime with LED Power Display, Noise Canceling Headset, IP55 Waterproof Earphones for Workout/Running (Black)

Wireless Earbuds, Sports Bluetooth Headphones, 80Hrs Playtime Ear Buds with LED Power Display, Noise Canceling Headset, IPX7 Waterproof Earphones for Workout/Running Z(Black)

Monster Wireless Earbuds Open Ear AC311, Bluetooth 5.4 Open Ear Headphones, Up to 30 Hours Playtimes Bluetooth Ear Earphones with Stereo Sound, Touch Control and IPX5 Waterproof Open Ear Buds

Brita Stainless Steel Premium Filtering Water Bottle, BPA-Free, Reusable, Insulated, Replaces 300 Plastic Water Bottles, Filter Lasts 2 Months or 40 Gallons, Includes 1 Filter, Carbon - 20 oz.

Simple Modern Filtered Water Bottle | Insulated Stainless-Steel Carbon Filter Travel Water Bottles | Reusable for Clean Drinking Water On The Go | 24oz, Sea Glass Sage

FITVII Health & Fitness Tracker (Answer/Make Calls), Smart Watch with 24/7 Heart Rate and Blood Pressure, Sleep Tracking Monitor, 120+ Sport Mode Activity Tracker

AYATAHA AYATAHA Smart Watch for Kids, Smartwatch Fitness Tracker for Boys Girls, Children's Activity Watch 37 Sports Modes SMS Notification, HD Full Touchscreen IP67 Waterproof, Blue

Iaret Iaret Smart Watch for Women, 1.83" HD Fitness Tracker with 4 Bands, Answer/Make Calls, Heart Rate/Sleep/SpO2/Step Tracking, 100+ Sport Modes, Android/iPhone Compatible Gift (Rose Gold)

Smart Watch for Men Women 1.8" Fitness Tracker, Bluetooth Call, DIY Dial, Heart Rate Sleep Blood Oxygen Monitor, 100+ Sports Modes, IP68 Waterproof Smartwatch for Android iPhone, Alexa Built-in

Hand Warmers 2 Pack, 14000mAh Rechargeable Hand Warmers, Electric Hand Warmer Reusable, Portable Power Bank USB Hand Warmers 4 Levels 8 Heating, Gifts for Raynauds Ski Golf Camping

Hand Warmers Rechargeable, 10000mAh Electric Heated Gloves Power Bank Portable Graphene Handwarmers Pouch with 3 Levels & Double-Sided Heating for Hunting Camping Golf Xmas Gifts for Women Men Kids

2Pack Rechargeable Hand Warmer, 8000mAh Electric Hand Warmer Power Bank, Portable USB-C Hand Warmer for Pocket, Reusable Hand Warmer Up to 8 hrs Each, Warm Gift for Men Women, for Hunting, Camping

GTOCE Portable Charger,40000mAh Power Bank with 22.5W Fast Charging LED Digital Display Battery Pack with 6 Outputs 2 Inputs, Type C Powerbank Portable Charger for iPhone 16 pro Samsung AirPods,Black

Monster Sleep Ear200, Wireless in-Ear Headphones, Bluetooth 6.0 Sleep Headphones, with ANC Active Noise Cancellation Designed for Side Sleepers, 30 Hours of bass Stereo Sound.

Monster Sleep Ear100 Ear Buds, Sleep Earbuds with Stereo Sound, Design for Side Sleeper, 32H Playtime, Bluetooth 6.0, ENC Noise Cancelling, IPX6 Waterproof Mini Headphones, White

Monster Sleep Ear100 Ear Buds, Sleep Earbuds with Stereo Sound, Design for Side Sleeper, 32H Playtime, Bluetooth 6.0, ENC Noise Cancelling, IPX6 Waterproof Mini Headphones, Black

Monster Sleep Ear100 Ear Buds, Sleep Earbuds with Stereo Sound, Design for Side Sleeper, 32H Playtime, Bluetooth 6.0, ENC Noise Cancelling, IPX6 Waterproof Mini Headphones, Black

Hydroponics Growing System Indoor Garden - Herb Garden with Grow Light, 15 Pods Stainless Steel Indoor Garden Kit, Auto Timer, Gardening Gift for All Ages

Umbra Triflora Hanging Planter for Window, Indoor Herb Garden, Set of 5, White/Black

Large Hydroponics Growing System 14 Pods, Indoor Herb Garden with LED Grow Light, 5L Water Tank, Hydroponic Grow Kit with 3 Auto-Timers, Rotatable Light Panel and Child Lock for Home School Gardening

Hanging Planter Hanging Plant Holder, 6 Inch 4 Indoor Plant Pots, Wall/Window Plant Hanger Indoor Herb Garden

slopehill Multi Hair Stylers & Hair Straightener - 2 in 1 Wet to Dry Air Straightener and Hair Dryer Combo with High Speed Air + Rapid Heat-Up + Customizable Temperature(Pink)

Hi.FANCY Portable Laptop Stand with Dual Cooling Fans for 14-17inch Laptops, Grey, 23.5 x 25.9 x 0.95cm

Laptop Stand for Desk, Adjustable Laptop Riser ABS+Silicone Foldable Portable Laptop Holder, Ventilated Cooling Notebook Stand for 10-15.6” Laptops,Tablet-Black

JETech 5 in 1 Case for Samsung Galaxy S25 Ultra 5G with 2-Pack Each Tempered Glass Screen Protector and Camera Lens Protector, Non-Yellowing Shockproof Bumper Phone Cover (Clear)

TAURI for iPhone 17 Pro Max Case 6.9" with 1-Pack Screen Protector, Camera Lens Full Protection, Military-Grade Protection, Shockproof Transparent Back Bumper Phone Cover - Clear Global Recycled Standard

TAURI for iPhone 17 Pro Case 6.3" with 1-Pack Screen Protector, Camera Lens Full Protection, Military-Grade Protection, Shockproof Transparent Back Bumper Phone Cover - Clear Global Recycled Standard

JOINPAYA 1Set Rechargeable Hand Warmer Hand Heater for Winter Heating Levels Compact

Shakven Rechargeable Hand Warmer | Cute Comfortable Portable Hand Warmers,Ergonomic Adjustable Energy-Efficient Small Heater for Travel, Outdoor, Winter

OCOOPA IP45 Waterproof Hand Warmer Rechargeable, Up to 15hrs Heat,10000mAh Durable Quick Charge Electric Hand Heater, PD Compatible, 3 Levels for Outdoors, Heavy Duty, H01-PD PRO














