Skip to content

austinp0573/raspberry_pi_pico_2w_various_modules

Repository files navigation

Raspberry Pi Pico 2 W Sensor and Module Scripts

This repository contains a collection of scripts and libraries designed to help you quickly get started with the Raspberry Pi Pico 2 W and various sensors or modules. Each directory corresponds to a specific sensor or module and includes the necessary code to interface with it.

Directory Overview

not_working_but_should_sda41

Scripts for the SCD41 sensor. Includes I2C scanning and test scripts. Module arrived non-functional. My tests were thorough, triple checked my wiring and never got any life from the i2c_scan. Code should work to get a functional sda41 started.

working_aht20

Code for the AHT20 temperature and humidity sensor. Includes examples and libraries.

working_aht20_bmp280

Combines the AHT20 and BMP280 sensors for temperature, humidity, and pressure measurements.

working_aht20_ens160

Scripts for using the AHT20 sensor alongside the ENS160 air quality sensor.

working_apds9960

Code for the APDS9960 proximity and gesture sensor.

working_bme680

Scripts for the BME680 environmental sensor, which measures temperature, humidity, pressure, and gas.

working_bmi160

Code for the BMI160 inertial measurement unit (IMU) for motion sensing.

working_ld2410c

Scripts for the LD2410C microwave-based human/object presence sensor.

working_mmc5603

Code for the MMC5603 magnetometer sensor.

working_pwm_to_test_oscilloscope

A simple script to generate PWM signals for testing an oscilloscope.

working_sht45

Scripts for the SHT45 temperature and humidity sensor.

working_ssd1306

Code for the SSD1306 OLED display module.

working_webpage

Scripts to host a basic webpage on the Raspberry Pi Pico for controlling an LED and displaying temperature readings.

working_webpage_prettier

An enhanced version of the working_webpage directory with improved HTML and CSS styling.

Getting Started

  1. Hardware Setup: Connect the Raspberry Pi Pico 2 W to the sensor or module as per the datasheet or documentation. If it doesn't work, congratulations, you have likely encountered the hardware tinkerer's infinite annoyance, some minor connection issue. But I all the code has been thoroughly tested.
  2. Software Setup: Copy the relevant directory to your Raspberry Pi Pico 2 W. With a blank pico, you can just directly copy the given directory and it's ready to run.
  3. Run the Script: Use a MicroPython-compatible IDE (e.g., Thonny) to run the script. I've only ever used Thonny, it makes working with microcontrollers in micropython very straightforward. One can use other IDEs like Mu or Visual Studio Code with the Pymakr extension, but Thonny is the only one I can speak to.

Notes

  • Each directory contains a lib/ folder with the necessary libraries for the sensor or module.
  • Some scripts may require additional configuration, such as Wi-Fi credentials for web-based examples.
  • Portions of the scripts were sourced from various places on the web. Every effort has been made to cite these sources where possible, but some attributions may have been missed.

License

This repository is licensed under the MIT License. It is provided as-is for educational and prototyping purposes. Please ensure compliance with any licenses or terms associated with the included libraries.

 

466f724a616e6574

About

Scripts and libraries for quickly getting started with the Raspberry Pi Pico 2 W and various sensors/modules. Each folder contains code for a specific sensor or module, including examples and libraries. Designed for prototyping and educational purposes. Licensed under MIT.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages