GithubHelp home page GithubHelp logo

picoprojects's Introduction

Pico Projects

This is our amazing introduction to basic electronics and working with the Raspberry Pi Pico microcontroller. These lessons will help you bring code to life and release your inner mad scientist!

Prerequisites

Basically you just need the simple Python editor called Thonny which allows you write code on your laptop and execute it on the Pico via a USB cable. USB cables will be provided just make sure you have a laptop with Thonny installed and an available USB jack on your laptop. We will have a few USB C to USB A adapters for those with only tiny ports. We will not have Mac dongles so make sure you have a way to connect a USB A cable into your laptop.

Please download and install the latest version(4.x or higher) of Thonny.
Download Thonny

For these labs, you do NOT have to be a Python expert. You can probably get by fine without having ever done Python programming before. However, some general programming knowledge is required. As long as you are comfortable with basic programming constructs(IF/ELSE statements, For/While loops, etc...) in other languagues we will have enough of the code for you to figure out the Python bits. If you want to get a little familar with Python before coming you can check out this free tutorial get comfortable with Python. We will have code samples and links to reference materials if you just need to see how to do "normal" programming things in Python. Python Tutorial

Are you Running a Hackathon

If you are using this as part of a Hackathon or contest, check out our Hackathon Guide.

Overview

We start with a basic introduction to circuits and some basic electronics. So, the first several labs only use the Pico as a power source to introduce basic circuits and some electronic components we will be working with. Without this foundational knowledge, it will be difficult to build useful solutions that integrate code and electronics.

If you aren't familar with how to use a breadboard, please take a moment and look at our introduction to them before starting the labs: Introduction to Breadboards

NOTE on LABS
We provide working code for each lab, but you are welcome to try to code some of the stretch goals or solutions on your own once you get the hang of things.

Many of the labs reference specific columns and rows to use when plugging in electronics. This is just to make it easier for beginners. The exact column and rows do not matter if you already understand how a breadboard works and know how to complete the circuit. If this is all brand new to this, you should follow our instructions exactly. But just know as you learn more about breadboards and circuits the exact location you plug things into the breadboard in many of the labs aren't important if you still complete the circuit.

If you finish a lab quickly and see others that are struggling, your stretch goal is to help a neighbor!

Intro to Circuits.

Simple circuit with LED using power from Pico and turn on LED.
Lab 1

Resistors.

Same simple circuit from above and just add resistors to control the brightness of the LED.
Lab 2

Variable Resistors (Photoresistor)

Working with Light Sensitive Resistors. Also known as Photoresistors.
Lab 3

Variable Resistor (Potentiometer)

Use a Potentiometer to control brightness of LED.
Lab 4

Buttons/Switches

Introduction to using Buttons/Switches with cicuits:
Lab 5

Use Code to Flash LED (First Lab with Pico and MicroPython)

Finally, we will use code to light up LEDs:
Lab 6
Lab 7

Working with Buttons and the Pico

Use the Pico to detect when a button is pressed.
Lab 8
Lab 9
Optional Game - Reaction Time Lab 16
Lab 10

Pulse Width Modulation (PWM)

Explain PWM and use PWM to fade an LED in and out and control brightness.
Lab 11

Buzzer lab with PWM.
Lab 11b

PWM to Control Servos

Use PWM to control a servo:
Lab 12

Threading in MicroPython

Threading on the Pico:
Lab 13

Reading PhotoResistor Values

Using Analog input with the Pico:
Lab 14

Seven Segment Display

Seven Segment Display:
Lab 15

Build the Laser Shooting Shark Game:

Final Lab 01
Final Lab 02
Final Lab 03

References:

Parts List

  • Pico, Pico H, or Pico W (Pico H is less work since it has pins soldered already)
  • Breadboard
  • Jumper Wires
  • LEDs
  • Button (push button switch)
  • micro USB cable
  • Active Buzzer
  • Photoresistor(5528, but others would work)
  • Resistors(220 Ohm, 10K Ohm) 2 of each
  • sg90 type mini servo
  • 10K Ohm Trim Potentiometer
  • 3D printed parts for final 3 game labs & paint stirring stick.Models

Spreadsheet with Links where I ordered most parts

Python:

Pico:

picoprojects's People

Contributors

javaplus avatar barthba avatar mattg1thub avatar bmcclaugherty avatar cyclump avatar

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.