Environmental sensing projects often rely heavily on cloud dashboards and complex frameworks, which can hide how the system actually works.
EnviroGo was created to flip that approach. Instead of starting with the cloud, it starts with the fundamentals—sensors, data handling, power management, and storage.
The goal is to help learners understand what happens between the sensor and the data, not just visualize results.
Reading and calibrating environmental sensors
- Reading and calibrating environmental sensors
- Working with microcontrollers and peripherals
- Working with microcontrollers and peripherals
- Logging data locally to SD cards
- Logging data locally to SD cards
- Designing portable, battery‑powered systems
- Designing portable, battery‑powered syste
- Structuring firmware for readability and reuse
- Microcontroller (ESP32 / RP2040 / etc.)
- Temperature & humidity sensor
- Air quality sensor
- SD card module
- Battery & power management modul
- Enclosure (3D printed)
import time
import board
import busio
import displayio
import terminalio
from adafruit_st7735r import ST7735R
from adafruit_display_text import label
from adafruit_display_shapes.roundrect import RoundRect
import fourwire
import digitalio
# ---------------- DISPLAY SETUP ----------------
displayio.release_displays()
spi = busio.SPI(clock=board.GP2, MOSI=board.GP3)
tft_cs = board.GP5
tft_dc = board.GP4
tft_rst = board.GP22
display_bus = fourwire.FourWire(
spi, command=tft_dc, chip_select=tft_cs, reset=tft_rst
)
tft_bl = board.GP14
led = digitalio.DigitalInOut(tft_bl)
led.direction = digitalio.Direction.OUTPUT
led.value=True
display = ST7735R(
display_bus,
width=160,
height=80,
rotation=90,
rowstart=1, colstart=26,
bgr=True
)
main = displayio.Group()
display.root_group = main
# ---------------- BACKGROUND ----------------
bg = displayio.Bitmap(160, 80, 1)
bg_palette = displayio.Palette(1)
bg_palette[0] = 0x0A0A0A
main.append(displayio.TileGrid(bg, pixel_shader=bg_palette))
# Title
title = label.Label(
terminalio.FONT,
text="LIVE TEMP",
color=0xFFFFFF,
x=48,
y=8
)
main.append(title)
# Card
card = RoundRect(
6, 14, 148, 60, 10,
fill=0x1C1C1C,
outline=0x00E5FF,
stroke=2
)
main.append(card)
# Temperature text
temp_label = label.Label(
terminalio.FONT,
text="--.- C",
scale=2,
color=0x00E5FF,
x=12,
y=30
)
main.append(temp_label)
# ---------------- GRAPH BITMAP ----------------
GRAPH_W = 136
GRAPH_H = 26
GRAPH_X = 12
GRAPH_Y = 42
TEMP_MIN = 20
TEMP_MAX = 35
graph_bitmap = displayio.Bitmap(GRAPH_W, GRAPH_H, 2)
graph_palette = displayio.Palette(2)
graph_palette[0] = 0x1C1C1C # background
graph_palette[1] = 0x00FF00 # graph line
graph = displayio.TileGrid(
graph_bitmap,
pixel_shader=graph_palette,
x=GRAPH_X,
y=GRAPH_Y
)
main.append(graph)
# ---------------- GRAPH FUNCTIONS ----------------
def temp_to_y(temp):
# Clamp temperature
temp = max(TEMP_MIN, min(TEMP_MAX, temp))
# Map temperature to bitmap Y so higher temp = higher pixel
return int((temp - TEMP_MIN) * (GRAPH_H - 1) / (TEMP_MAX - TEMP_MIN))
# ---------------- MAIN LOOP ----------------
temperature = 25.0
while True:
# Simulated temperature (replace with real sensor)
temperature += 0.2
if temperature > 34:
temperature = 25
temp_label.text = f"{temperature:.1f} C"
'''
# Scroll graph left
for x in range(GRAPH_W - 1):
for y in range(GRAPH_H):
graph_bitmap[x, y] = graph_bitmap[x + 1, y]
# Clear last column
for y in range(GRAPH_H):
graph_bitmap[GRAPH_W - 1, y] = 0
# Draw new temperature point
y = temp_to_y(temperature)
graph_bitmap[GRAPH_W - 1, y] = 1
'''
# Scroll graph right
for x in range(GRAPH_W - 1, 0, -1):
for y in range(GRAPH_H):
graph_bitmap[x, y] = graph_bitmap[x - 1, y]
# Clear first column
for y in range(GRAPH_H):
graph_bitmap[0, y] = 0
# Draw new temperature point at left
y = temp_to_y(temperature)
graph_bitmap[0, y] = 1
time.sleep(0.5)Support & Learn MoreIf you enjoyed exploring EnviroGo and want to support its development, you can back the full project on Kickstarter:










_3u05Tpwasz.png?auto=compress%2Cformat&w=40&h=40&fit=fillmax&bg=fff&dpr=2)


Comments