Git Product home page Git Product logo

picow-enviroplus's Introduction

Pico W Enviro+ Pack sample

This is the MicroPython code that I'm running on the Pico Enviro+ Pack from Pimoroni.

My Enviro+ sits on top of a Pico W. I wanted it to show the text display of the current environmental parameters, and also to publish the information to my MQTT broker at the same time. The sample code from Pimoroni is either/or, so, this repository contains an unholy mashup of a couple of chunks of their code, until I get around to doing something better.

Rather than using the full Enviro self-provisioning code from the standalone products, this is using a lightly-modified version of the network_manager code from Pimoroni as well.

In addition, I thought I'd noodle around with using the vector-ish Hershey fonts instead of using the bitmap ones, which gave me a chance to tinker with PicoGraphics. I'm happy with the result!

vector fonts

I also modified the network code to enable setting the device name (new in MicroPython 1.20).

  • open config.py.example in Thonny to add your wifi details (and save it as config.py when you're done). You'll also need to add MQTT details in there.
  • for MQTT, you'll need to install micropython-mqtt.simple using Thonny's 'Tools' > 'Manage Packages' (or using mip - to be documented)
  • transfer config.py, main.py, network_manager.py and the lib directory to your Pico.
  • for the PMS5003 particle sensor, requires the correct driver:

mip.install("https://raw.githubusercontent.com/pimoroni/pms5003-micropython/main/package.json")

Tested / running on MicroPython 1.20[.1] ๐Ÿ‘๐Ÿป๏ธ

Now if you'll excuse me, I'm off to design 3D printed cases for Pimoroni products...

License

MIT (which matches the original Pimoroni code this is derived from)

picow-enviroplus's People

Contributors

andypiper avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 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.