This repository provides a comprehensive toolkit for controlling a Raspberry Pi Pico microcontroller board and managing 8 relay switches via Python and MQTT. It's designed for hobbyists, engineers, and anyone interested in DIY electronics and home automation projects. Using Python scripts, users can interface their Pico with multiple relay switches to control various devices, lights, or motors.
- Clone this repository to your local machine.
- Install the required Python libraries and MQTT broker.
pip install -r requirements
- Explore the example scripts to start controlling your devices.
- Edit the main.py or create another python file
- Please take note the "from core.relay import Relay" in line 1
- Then see the following functions
from core.relay import Relay
relay = Relay()
relay.turn("on", 8)
relay.turn("off", 8)
relay.on(8)
relay.off(8)
Contributions are welcome! If you'd like to contribute, please fork the repository and use a feature branch. Pull requests are warmly welcome.
This project is licensed under the MIT License.