My Enviro (code) based Weather Station Build

I’ve been working on this off and on, for what seems like ages. It all started with the Enviro Weather and light example file, and a mock up of an Enviro using Breakout Garden stuff.
Basically what you see running on the Enviro on the shop page. With some minor edits.
That got expanded to two displays and two BME280’s. One for indoor readings and one for outdoor readings. I started with indoor on one screen and outdoor on the other. Then later switched it around so its indoor temp top left, outdoor temp top right, indoor humidity lower left and out door humidity lower right. Light and pressure on the other display. Then swapped the light sensor for a UV sensor.

The two displays are the 0.96" SPI Color LCD (160x80) Breakout. Its the same display used on the Enviro and Enviro+. They are mounted on a Proto Zero wired up to SPI0, left on CE0 and right on CE1.
Behind that is a second Proto Zero with an RV3028 RTC on top and BME280 on the bottom. Wired up to i2c. I wanted to keep the BME280 out of direct sunlight for better accuracy. It’s using the stock 0x76 i2c address.
Behind that is a Breakout Garden i2c Hat with the second BME280 (address 0x77) and a VEML6073 UV sensor breakout.
This is my coding setup, where I work out the bugs etc.

The above pHats and Hat are mounted on a modified pHat Stack. I cut one end off just past the last GPIO header. Right where the C and 4 are. Then soldered on a female 90 header. That lets me plug it into my Pi400 just like it was a Flat HAT Hacker for Raspberry Pi 400. It’s just twice as big with 4 headers instead of 2. All the Phats are facing the right way, towards you. =)

The coding was by far the hardest part. All the image calls etc. In the end I went with two separate images img_left and img_right. And created two separate backgrounds, even though they use the same identical background. Weird things happened if I didn’t. I also hope to add Wind Speed - Direction and Rainfall to the empty spot on the second display

WARNING Wall of code to follow. =)

#!/usr/bin/env python3

import os
import sys
import time
import numpy
import colorsys

import smbus

from PIL import Image, ImageDraw, ImageFont, ImageFilter
from fonts.ttf import RobotoMedium as UserFont

import veml6075

import ST7735
from bme280 import BME280

import pytz
from pytz import timezone
from astral.geocoder import database, lookup
from astral.sun import sun
from datetime import datetime, timedelta


try:
    from smbus2 import SMBus
except ImportError:
    from smbus import SMBus
    
    
bus = smbus.SMBus(1)
uv_sensor = veml6075.VEML6075(i2c_dev=bus)
uv_sensor.set_shutdown(False)
uv_sensor.set_high_dynamic_range(False)
uv_sensor.set_integration_time('100ms')


def calculate_y_pos(x, centre):
    """Calculates the y-coordinate on a parabolic curve, given x."""
    centre = 80
    y = 1 / centre * (x - centre) ** 2

    return int(y)


def circle_coordinates(x, y, radius):
    """Calculates the bounds of a circle, given centre and radius."""

    x1 = x - radius  # Left
    x2 = x + radius  # Right
    y1 = y - radius  # Bottom
    y2 = y + radius  # Top

    return (x1, y1, x2, y2)


def map_colour(x, centre, start_hue, end_hue, day):
    """Given an x coordinate and a centre point, a start and end hue (in degrees),
       and a Boolean for day or night (day is True, night False), calculate a colour
       hue representing the 'colour' of that time of day."""

    start_hue = start_hue / 360  # Rescale to between 0 and 1
    end_hue = end_hue / 360

    sat = 1.0

    # Dim the brightness as you move from the centre to the edges
    val = 1 - (abs(centre - x) / (2 * centre))

    # Ramp up towards centre, then back down
    if x > centre:
        x = (2 * centre) - x

    # Calculate the hue
    hue = start_hue + ((x / centre) * (end_hue - start_hue))

    # At night, move towards purple/blue hues and reverse dimming
    if not day:
        hue = 1 - hue
        val = 1 - val

    r, g, b = [int(c * 255) for c in colorsys.hsv_to_rgb(hue, sat, val)]

    return (r, g, b)


def x_from_sun_moon_time(progress, period, x_range):
    """Recalculate/rescale an amount of progress through a time period."""

    x = int((progress / period) * x_range)

    return x


def sun_moon_time(city_name, time_zone):
    """Calculate the progress through the current sun/moon period (i.e day or
       night) from the last sunrise or sunset, given a datetime object 't'."""

    city = lookup(city_name, database())

    # Datetime objects for yesterday, today, tomorrow
    utc = pytz.utc
    utc_dt = datetime.now(tz=utc)
    local_dt = utc_dt.astimezone(pytz.timezone(time_zone))
    today = local_dt.date()
    yesterday = today - timedelta(1)
    tomorrow = today + timedelta(1)

    # Sun objects for yesterday, today, tomorrow
    sun_yesterday = sun(city.observer, date=yesterday)
    sun_today = sun(city.observer, date=today)
    sun_tomorrow = sun(city.observer, date=tomorrow)

    # Work out sunset yesterday, sunrise/sunset today, and sunrise tomorrow
    sunset_yesterday = sun_yesterday["sunset"]
    sunrise_today = sun_today["sunrise"]
    sunset_today = sun_today["sunset"]
    sunrise_tomorrow = sun_tomorrow["sunrise"]

    # Work out lengths of day or night period and progress through period
    if sunrise_today < local_dt < sunset_today:
        day = True
        period = sunset_today - sunrise_today
        # mid = sunrise_today + (period / 2)
        progress = local_dt - sunrise_today

    elif local_dt > sunset_today:
        day = False
        period = sunrise_tomorrow - sunset_today
        # mid = sunset_today + (period / 2)
        progress = local_dt - sunset_today

    else:
        day = False
        period = sunrise_today - sunset_yesterday
        # mid = sunset_yesterday + (period / 2)
        progress = local_dt - sunset_yesterday

    # Convert time deltas to seconds
    progress = progress.total_seconds()
    period = period.total_seconds()

    return (progress, period, day, local_dt)

def draw_background_left(progress, period, day):
    """Given an amount of progress through the day or night, draw the
       background colour and overlay a blurred sun/moon."""

    # x-coordinate for sun/moon
    x = x_from_sun_moon_time(progress, period, WIDTH)

    # If it's day, then move right to left
    if day:
        x = WIDTH - x

    # Calculate position on sun/moon's curve
    centre = WIDTH / 2
    y = calculate_y_pos(x, centre)

    # Background colour
    background_left = map_colour(x, 80, mid_hue, day_hue, day)
    
    # New image for background colour
    img_left = Image.new('RGBA', (WIDTH, HEIGHT), color=background_left)
    
    # New image for sun/moon overlay
    overlay = Image.new('RGBA', (WIDTH, HEIGHT), color=(0, 0, 0, 0))
    overlay_draw = ImageDraw.Draw(overlay)

    # Draw the sun/moon
    circle = circle_coordinates(x, y, sun_radius)
    overlay_draw.ellipse(circle, fill=(200, 200, 50, opacity))

    # Overlay the sun/moon on the background as an alpha matte
    composite_left = Image.alpha_composite(img_left, overlay).filter(ImageFilter.GaussianBlur(radius=blur))

    return composite_left

def draw_background_right(progress, period, day):
    """Given an amount of progress through the day or night, draw the
       background colour and overlay a blurred sun/moon."""

    # x-coordinate for sun/moon
    x = x_from_sun_moon_time(progress, period, WIDTH)

    # If it's day, then move right to left
    if day:
        x = WIDTH - x

    # Calculate position on sun/moon's curve
    centre = WIDTH / 2
    y = calculate_y_pos(x, centre)

    # Background colour
    background_right = map_colour(x, 80, mid_hue, day_hue, day)
    
    # New image for background colour
    img_right = Image.new('RGBA', (WIDTH, HEIGHT), color=background_right)
 
    # New image for sun/moon overlay
    overlay = Image.new('RGBA', (WIDTH, HEIGHT), color=(0, 0, 0, 0))
    overlay_draw = ImageDraw.Draw(overlay)

    # Draw the sun/moon
    circle = circle_coordinates(x, y, sun_radius)
    overlay_draw.ellipse(circle, fill=(200, 200, 50, opacity))

    # Overlay the sun/moon on the background as an alpha matte
    composite_right = Image.alpha_composite(img_right, overlay).filter(ImageFilter.GaussianBlur(radius=blur))

    return composite_right

def overlay_text_left(img_left, position, text, font, align_right=False, rectangle=False):
    draw = ImageDraw.Draw(img_left)
    w, h = font.getsize(text)
    if align_right:
        x, y = position
        x -= w
        position = (x, y)
    if rectangle:
        x += 1
        y += 1
        position = (x, y)
        border = 1
        rect = (x - border, y, x + w, y + h + border)
        rect_img = Image.new('RGBA', (WIDTH, HEIGHT), color=(0, 0, 0, 0))
        rect_draw = ImageDraw.Draw(rect_img)
        rect_draw.rectangle(rect, (255, 255, 255))
        rect_draw.text(position, text, font=font, fill=(0, 0, 0, 0))
        img_left = Image.alpha_composite(img_left, rect_img)
    else:
        draw.text(position, text, font=font, fill=(255, 255, 255))
    return img_left


def overlay_text_right(img_right, position, text, font, align_right=False, rectangle=False):
    draw = ImageDraw.Draw(img_right)
    w, h = font.getsize(text)
    if align_right:
        x, y = position
        x -= w
        position = (x, y)
    if rectangle:
        x += 1
        y += 1
        position = (x, y)
        border = 1
        rect = (x - border, y, x + w, y + h + border)
        rect_img = Image.new('RGBA', (WIDTH, HEIGHT), color=(0, 0, 0, 0))
        rect_draw = ImageDraw.Draw(rect_img)
        rect_draw.rectangle(rect, (255, 255, 255))
        rect_draw.text(position, text, font=font, fill=(0, 0, 0, 0))
        img_right = Image.alpha_composite(img_right, rect_img)
    else:
        draw.text(position, text, font=font, fill=(255, 255, 255))
    return img_right


def analyse_pressure(pressure, t):
    global time_vals, pressure_vals, trend
    if len(pressure_vals) > num_vals:
        pressure_vals = pressure_vals[1:] + [pressure]
        time_vals = time_vals[1:] + [t]

        # Calculate line of best fit
        line = numpy.polyfit(time_vals, pressure_vals, 1, full=True)

        # Calculate slope, variance, and confidence
        slope = line[0][0]
        intercept = line[0][1]
        variance = numpy.var(pressure_vals)
        residuals = numpy.var([(slope * x + intercept - y) for x, y in zip(time_vals, pressure_vals)])
        r_squared = 1 - residuals / variance

        # Calculate change in pressure per hour
        change_per_hour = slope * 60 * 60
        # variance_per_hour = variance * 60 * 60

        mean_pressure = numpy.mean(pressure_vals)

        # Calculate trend
        if r_squared > 0.5:
            if change_per_hour > 0.5:
                trend = ">"
            elif change_per_hour < -0.5:
                trend = "<"
            elif -0.5 <= change_per_hour <= 0.5:
                trend = "-"

            if trend != "-":
                if abs(change_per_hour) > 3:
                    trend *= 2
    else:
        pressure_vals.append(pressure)
        time_vals.append(t)
        mean_pressure = numpy.mean(pressure_vals)
        change_per_hour = 0
        trend = "-"

    # time.sleep(interval)
    return (mean_pressure, change_per_hour, trend)


def describe_pressure(pressure):
    """Convert pressure into barometer-type description."""
    if pressure < 970:
        description = "storm"
    elif 970 <= pressure < 990:
        description = "rain"
    elif 990 <= pressure < 1010:
        description = "change"
    elif 1010 <= pressure < 1030:
        description = "fair"
    elif pressure >= 1030:
        description = "dry"
    else:
        description = ""
    return description

def describe_humidity_in(humidity_in):
    """Convert relative humidity into good/bad description."""
    if humidity_in < 30:
        description = "dry"
    elif 30 <= humidity_in <= 60:
        description = "good"
    elif humidity_in > 60:
        description = "humid"
    return description

def describe_humidity_out(humidity_out):
    """Convert relative humidity into good/bad description."""
    if humidity_out < 30:
        description = "dry"
    elif 30 <= humidity_out <= 60:
        description = "good"
    elif humidity_out > 60:
        description = "humid"
    return description

def describe_uvindex(uvindex):

    if uvindex < 3:
        description = "low" 
    elif 3 <= uvindex < 6:
        description = "mod"
    elif 6 <= uvindex < 8:
        description = "high"
    elif 8 <= uvindex < 11:
        desctption = "vh"
    elif uvindex >= 11:
        descrition = "ex"
    else:
        descrition = ""
    return description    


# Initialise the left LCD
disp_left = ST7735.ST7735(
    port=0,
    cs=0,
    dc=9,
    #backlight=19,
    rotation=90,
    spi_speed_hz=10000000
)

disp_left.begin()



# Initialise the right LCD
disp_right = ST7735.ST7735(
    port=0,
    cs=1,
    dc=9,
    #backlight=19,
    rotation=90,
    spi_speed_hz=10000000
)

disp_right.begin()

WIDTH = 160
HEIGHT = 80

# The city and timezone that you want to display.
city_name = "Halifax"
time_zone = "Canada/Atlantic"

# Values that alter the look of the background
blur = 50
opacity = 125

mid_hue = 0
day_hue = 25

sun_radius = 50

# Fonts
font_sm = ImageFont.truetype(UserFont, 12)
font_lg = ImageFont.truetype(UserFont, 14)

# Margins
margin = 3

# Set up BME280 weather sensor
bus = SMBus(1)
bme_in = BME280(0x76)
bme_out = BME280(0x77)

min_temp_in = None
max_temp_in = None
min_temp_out = None
max_temp_out = None

# Pressure variables
pressure_vals = []
time_vals = []
num_vals = 1000
interval = 1
trend = "-"

# Keep track of time elapsed
start_time = time.time()

while True:
    path = os.path.dirname(os.path.realpath(__file__))
    progress, period, day, local_dt = sun_moon_time(city_name, time_zone)
    background_left = draw_background_left(progress, period, day)
    background_right = draw_background_right(progress, period, day)

    # Time.
    time_elapsed = time.time() - start_time
    date_string = local_dt.strftime("%B %-d")
    time_string = local_dt.strftime("%-I:%M %p")
    img_left = overlay_text_left(background_left, (15 + margin, 0 + margin), ("Indoor"), font_lg)
    img_left = overlay_text_left(img_left, (150 - margin, 0 + margin), ("Outdoor"), font_lg, align_right=True)
    img_right = overlay_text_right(background_right, (0 + margin, 0 + margin), date_string, font_lg)
    img_right = overlay_text_right(img_right, (WIDTH - margin, 0 + margin), time_string, font_lg, align_right=True)


    # Temperature in
    temperature_in = bme_in.get_temperature()

    if time_elapsed > 30:
        if min_temp_in is not None and max_temp_in is not None:
            if temperature_in < min_temp_in:
                min_temp_in = temperature_in
            elif temperature_in > max_temp_in:
                max_temp_in = temperature_in
        else:
            min_temp_in = temperature_in
            max_temp_in = temperature_in

    #temp_string = f"{corr_temperature:.0f}°C"
    temp_string_in = f"{temperature_in:.0f}°C"       
    img_left = overlay_text_left(img_left, (68, 18), temp_string_in, font_lg, align_right=True)
    spacing = font_lg.getsize(temp_string_in)[1] + 1
    if min_temp_in is not None and max_temp_in is not None:
        range_string_in = f"{min_temp_in:.0f}-{max_temp_in:.0f}"
    else:
        range_string_in = "------"
    img_left = overlay_text_left(img_left, (68, 18 + spacing), range_string_in, font_sm, align_right=True, rectangle=True)
    temp_icon = Image.open(f"{path}/icons/temperature.png")
    img_left.paste(temp_icon, (margin, 18), mask=temp_icon)

    # Temperature out
    temperature_out = bme_out.get_temperature()

    if time_elapsed > 30:
        if min_temp_out is not None and max_temp_out is not None:
            if temperature_out < min_temp_out:
                min_temp_out = temperature_out
            elif temperature_out > max_temp_out:
                max_temp_out = temperature_out
        else:
            min_temp_out = temperature_out
            max_temp_out = temperature_out

    #temp_string = f"{corr_temperature:.0f}°C"
    temp_string_out = f"{temperature_out:.0f}°C"       
    img_left = overlay_text_left(img_left, (150 - margin, 18), temp_string_out, font_lg, align_right=True)
    spacing = font_lg.getsize(temp_string_out.replace(",", ""))[1] + 1
    if min_temp_out is not None and max_temp_out is not None:
        range_string_out = f"{min_temp_out:.0f}-{max_temp_out:.0f}"
    else:
        range_string_out = "------"
    img_left = overlay_text_left(img_left, (150 - margin, 18 + spacing), range_string_out, font_sm, align_right=True, rectangle=True)
    temp_icon = Image.open(f"{path}/icons/temperature.png")
    img_left.paste(temp_icon, (80, 18), mask=temp_icon)


    # Humidity in
    humidity_in = bme_in.get_humidity()
    humidity_string_in = f"{humidity_in:.0f}%"
    img_left = overlay_text_left(img_left, (68, 48), humidity_string_in, font_lg, align_right=True)
    spacing = font_lg.getsize(humidity_string_in)[1] + 1
    humidity_desc_in = describe_humidity_in(humidity_in).upper()
    img_left = overlay_text_left(img_left, (68, 48 + spacing), humidity_desc_in, font_sm, align_right=True, rectangle=True)
    humidity_icon = Image.open(f"{path}/icons/humidity.png")
    img_left.paste(humidity_icon, (margin, 48), mask=humidity_icon)

    # Humidity out
    humidity_out = bme_out.get_humidity()
    humidity_string_out = f"{humidity_out:.0f}%"
    img_left = overlay_text_left(img_left, (150 - margin, 48), humidity_string_out, font_lg, align_right=True)
    spacing = font_lg.getsize(humidity_string_out.replace(",", ""))[1] + 1
    humidity_desc_out = describe_humidity_out(humidity_out).upper()
    img_left = overlay_text_left(img_left, (150 - margin - 1, 48 + spacing), humidity_desc_out, font_sm, align_right=True, rectangle=True)
    humidity_icon = Image.open(f"{path}/icons/humidity.png")
    img_left.paste(humidity_icon, (80, 48), mask=humidity_icon)

    # UV Index
    uva, uvb = uv_sensor.get_measurements()
    uv_comp1, uv_comp2 = uv_sensor.get_comparitor_readings()
    uv_indices = uv_sensor.convert_to_index(uva, uvb, uv_comp1, uv_comp2)
    uv =('{0[2]}'.format(uv_indices)) #uv reading as a float value with no text mixed in
    u = int(float(uv)) #uv index converted to an integer value
    uvindex = round(u)

    uvindex_string = f"{uvindex:.0f} UV"       
    img_right = overlay_text_right(img_right, (150 - margin, 18), uvindex_string, font_lg, align_right=True)
    spacing = font_lg.getsize(uvindex_string.replace(",", ""))[1] + 1
    uvindex_desc = describe_uvindex(uvindex).upper()
    img_right = overlay_text_right(img_right, (150 - margin - 1, 18 + spacing), uvindex_desc, font_sm, align_right=True, rectangle=True)
    uvindex_icon = Image.open(f"{path}/icons/uvindex.png")
    img_right.paste(uvindex_icon, (80, 18), mask=uvindex_icon)
        
    # Pressure
    pressure = bme_out.get_pressure()
    t = time.time()
    mean_pressure, change_per_hour, trend = analyse_pressure(pressure, t)
    #pressure_string = f"{int(mean_pressure):} {trend}"
    pressure_string = f"{pressure:.0f} {trend}"
    img_right = overlay_text_left(img_right, (WIDTH - margin, 48), pressure_string, font_lg, align_right=True)
    #pressure_desc = describe_pressure(mean_pressure).upper()
    pressure_desc = describe_pressure(pressure).upper()
    spacing = font_lg.getsize(pressure_string.replace(",", ""))[1] + 1
    img_right = overlay_text_right(img_right, (150 - margin - 1, 48 + spacing), pressure_desc, font_sm, align_right=True, rectangle=True)
    pressure_icon = Image.open(f"{path}/icons/weather-{pressure_desc.lower()}.png")
    img_right.paste(pressure_icon, (80, 48), mask=pressure_icon)

    # Display image
    disp_left.display(img_left)
    disp_right.display(img_right)
2 Likes

I’m thinking one of these will be what I add next.

Wire it up to a PICO LIPO and connect my outdoor sensors to the PICO. Then send the data to the Pi via WIFI.

Go mad and learn to use LoRa to send the data at a greater distance. (popped here from over Pi Forums )

If you stay with WiFi (you have the wi-fi range) then scrap the Pico. The addon for WiFi is usually an ESP device, so you can scrap the Pico and just use the ESP device itself. i.e. the pico is redundant increases power usage and you gain no advantage.

Pretty much all my devices are setup like this ‘IoT style’ and I send it to a Pi server to do the hard work being a server.

Nice to see you here. Lots of time to research this and form a plan. I won’t be buying the above for a while yet, maybe Christmas?

EDIT: Hmm, I have an Arduino MKR1000 sitting here doing nothing?

That is developing nicely. I will be following your progress with interest.
I’ve gone for a Pico Environmental Sensor board from Waveshare:

  • BME280 = Temperature, Humidity and Pressure
  • TSL25911FN = light sensor - Lux
  • LTR390-UV-1 = Ultra Violet
  • SGP40 = Air quality
  • ICM20948 = Motion 9-DoF - accelerometer, gyroscope and magnetometer
  • I2C and all on the same 2 wires!

I’ve got them all reporting readings and am now working on the graphics in Micropython. 1352 lines of code, including drivers - no libraries, and still growing!

My coding skills are average at best. Thus I usually borrow on what I can find that already works, and has most of the grunt work already done. Then modify to my needs. I’m pretty good at figuring out what a block of code does, just not how it does it. ;)

I have some PICO’s here, and the PICO Breakout Garden. At some point I’ll likely try to do something similar on it. Over the winter maybe?

Thanks for the comments, I do value your input. =)

EDIT: And a big thanks to @bensimmo, for all his help over on the Pi Foundation Forum.
Double Trouble, need some help with a Python file. - Raspberry Pi Forums

1 Like

I went headless for now, easy peasy even with my modified pHat Stack. I just plug my custom Pi Zero into the ribbon cable header. It has a female 90 header on the back side. It plugs in with all the plugs pointing up for easy access.
I also added a Backlight On Off switch to turn off both backlights. I can leave it running but turn the displays off at night. I also added a shut down and boot buttons. Needed if you run headless.

If you look close you can see the female header that plugs into the Pi 400 on the left just below the two LCD’s.

That is a pretty smart I like it. Nice tidy build too. Look forward to future updates. 👍

1 Like

Thanks, I enjoy this stuff immensely when a project starts to come together. And Pimoroni make it so much easier. That was a pretty easy mod, dremel and a 90 female header. Not knowing where the tracks were inside the board, there was some risk. There isn’t anything past that last header so I took the risk. Then did a continuity check from that last header to the next one. All good. =) Warmed up the soldering iron, etc.

I’ve been putting Pi Zero’s on pHat stacks and Mini Hackers for a while now. If you put the 90 female header on the Pi Zero, the pHat Stack stays stock and you can still use the ribbon cable to hook up a 3B or 4B. Or a Pi 400, but its a bit of a pain on a Pi 400. That’s what led me to do the above. Now that pHat stack is dual purpose. You just have to remember to remove the Pi Zero before plugging it into a Pi 400.

My Pi 400 is something new to tinker with. The placement of its GPIO Header makes you get creative.

What is on the Breakout Garden Hat will eventually end up outside. The hat will be removed at that point too, and I’ll put what’s left on a Mini Black Hat Hacker. It will be half as big as it is now. The bits that go outside is the next bit I’ll be working on. I have to order some more stuff for that. I’m probably going to go wireless for the data transfer. A micro controller with the BME280 and UV sensor attached to it. Along with the windspeed etc sensors.

1 Like

Plugged in a USB battery pack today to take it outside to test the UV code. It read 2 which is what it was with the hazy sky we had. Something to keep in mind is most plastics and glass block UV light. It wasn’t always this way but its pretty well SOP these days to block UV light.
I have another similar portable build with the same UV light sensor in it. It’s in a weatherproof enclosure with a clear plastic front. That clear plastic blocks UV light. I had to make a hole in it and then cover it with quartz crystal glass. It’s what microscope slides are made of. I bummed a couple from my friendly neighborhood veterinarian. If you don’t own a pet you might be able to get one from your doctor. It saves ordering a sheet online and hoping it doesn’t get broken in transit.

Put this together today. PICO Omnibus, PICO Proto, and 4 Breakout Garden i2c Extenders, just the socket end.
I had no way to add the PICO Wireless pack to my PICO Breakout garden Base. And no, a stacking header wouldn’t work, trust me.
I didn’t have a PICO Breakout Garden Base, plus I needed at least 3 i2c sockets.
RTC, BME280, VEML6075 uv sensor.
Really need a Pico Decker (Quad Expander) I need to add another Pico Proto to hook up to the wind vane rain bucket.
Still early stages yet. Lots of coding to do to get it all working as I want. Fingers crossed I have the skills to pull it off. =)

Do you really need the RTC? You can get the time from the wireless module and set utime then use that. You could reset twice a day or on the hour for better accuracy. I’m watching with interest. Best of luck.

I had a spare RV3028 on hand, its supported in the Pimoroni uf2, so for now why not.
The final version is likely to be PICO > Pico Proto with stacking header > Pico Wireless. I’ll just run cables off of the Pico Proto to the various sensors etc. The UV sensor is going to be in one place, and the BME280 in another. The RV3028 will be on the Proto if there is room. i2c for the sensors and ADC etc for the wind vane.
EDIT: I have the Wind Vane here still in the box, only just got it the other day. All I can do is test it to make sure there are no defects and then put it away for Christmas.

I now have the Wind and Rain Sensors linked to above setup. Made a temporary indoor stand for it, for now. Just some left over bits of wood I had kicking around. Time to get back into the coding part of this build. I’ll put some more pictures up when I get a chance.
With my current setup I can do it all from my Pi 400. The pHat Stack indoor part is plugged into its GPIO header, and PICO outside end via USB for now. I’ll worry about the WIFI bit latter on. I want to nail down the Wind & Rain sensor code first.