Skip to content

micheltlutz/PyDHT11-API

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyDHT11 API

Python FastAPI Raspberry Pi

micheltlutz github python

Environment

  • Python 3.11.+ (3.9.+ or 3.10.+ should work too)
  • Raspberry Pi 2B+ (or any other Raspberry Pi with GPIO pins)
  • DHT11 sensor

Setup steps (Raspberry Pi)

python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt

Run

uvicorn app.main:app --host 0.0.0.0 --port 8000 --reload

Access

Change localhost to your Raspberry Pi IP address to access from another device

Routes Available