Tiny 2040 display watch

I am fairly new to raspberry pi but want to try to make a digital watch type thing, i want to use the tiny 2040 microcontroller and an adafruit oled display (Adafruit Monochrome 0.96" 128x64 OLED Graphic Display – Pimoroni). Only issue is that i have no idea to connect them (as there are alot less pins) or what other things id need to get this working or if its even possible to do this with issues regarding battery life and other things such as making it all in a small space.

There is a pinout on the product page, I saved it as an image file on my PC for easy reference.

If it was me I’d use the following pins on the tiny. Top right in the diagram.
0 GP0 i2c 0 SDA
and
1 GP1 i2c 0 SCL

Wire you display to those i2c pins and then set your code to use those same pins.

Thanks, the thing i wanted most to know is if it actually works, which it does.

Also any thought or ideas on things like battery’s or other things I’d need?

Thanks again.

I’ve run the SPI Breakout Garden Displays on a PICO using the Pimoroni Micro Python Examples. I haven’t run an i2c display, but I have run some of their i2c breakouts on a PICO.
I have a TINY but haven’t done anything with it so far. I got it as a trade with some other PICO / Raspberry Pi stuff.
I also have the PICO LIPO Shim wired up to a full size PICO with a 1200 MAH battery. It isn’t directly pluggable with a Tiny though. The Tiny has the power pins in a different spot. Plus its missing the VSYS Pin which is where you would feed you battery power in. Your likely going to have to use a powerboost and feed it 5V?

EDIT: 1
Keeping the Time updated to be accurate could be an issue. The PICO has a RTC onboard, but no battery backup for it. If you remove power it will not keep accurate time.
You may need an RV3028 RTC, that has a battery onboard.

If you go here, and scroll down the page, you’ll see a list of the devices that are supported in Pimoroni’s Micro Python uf2 image. You don’t need the breakout garden to use them, it just makes it easier. You can wire them up directly with jumper wire.

Pico Breakout Garden Pack – Pimoroni

EDIT: 2
Have you bought anything yet? If no, you may want to consider the Feather RP2040
Adafruit Feather RP2040 – Pimoroni
It’s small and has a built in LIPO charger.
Then mate it to this display
Adafruit FeatherWing OLED - 128x64 OLED Add-on For Feather - STEMMA QT – Pimoroni

DS3231 Precision RTC FeatherWing - RTC Add-on For Feather Boards – Pimoroni

I have not bought anything yet, and i was originally thinking the feather and display wasn’t quite the shape i wanted, but looking at it now i could make a sort of fitbit type thing which would still look really cool.

Is possible to connect the feather rtc and the display into one thing, because from the look of it it connects onto it like a pi hat (the site also said something about feather stacking header would be needed?), and for someone with my level of understanding that makes things alot easier as i wouldn’t have to include lots of wires and a power boost because it has the built lipo battery and the rtc has a backup battery.

The stacking header lets you put one in the middle and go three deep. I do the same thing with my Raspberry Pi’s and PICO’s.
Display
RTC
Feather 2040.

Oh cool, that definitely seems like a better option I’ll have a more in depth look at it, thanks you.

Im guessing ill have to solder the headers on?

I also can’t seem to find the male stacking headers which i presume is what ill need

Stacking headers are male to female,
Feather Stacking Headers - 12-pin and 16-pin female headers – Pimoroni
And you’ll need at least one set of female headers.
Feather Header Kit - 12-pin and 16-pin Female Header Set – Pimoroni

If you follow the guide, the display has male headers on the backside and the feather has female headers on the top pointing up.
The stacking headers would go on the RTC, female on top male out the bottom.
Assembly | Adafruit 128x64 OLED FeatherWing | Adafruit Learning System

The RTC stacks between the feather and display.

The one issue with that is that it will be very thick for a watch and quite flimsy and breakable

It’s been my experience that there are almost always tradeoffs.

I want to build something similar that displays weather data. Temperature, Humidity and Barometric pressure. I end up with the same, its a bit too big to strap to my wrist dilemma.

Making a case is also problematic, as I don’t own a 3D printer.

One option is to use extra long extended male headers. Put the RTC as close as possible to the feather and solder it to the male header, skipping the stacking header. Then solder the display as close as possible on top of that. All three soldered to the one long set of male pins. It will slim it down and make it more robust. You won’t ever be able to unplug anything though, not without a lot of unsoldering.

I was thinking if there was a way to do it all on one big header that’s why i was looking for male stacking headers or a way to shrink down the existing ones, why would i find extended male headers for the feather if they exist.

Edit: do the headers need to explicitly be for the feather or will any extended male headers work eg ones made for the pi or are the sizes different?

Any single row male header with a 0.1" / 2.54mm pin spacing will work.
You just break them off to the correct length / number of pins.
These “might” be long enough.
Break Away Headers - Long – Pimoroni

I’ve bought a couple of these packs for my PICO’s, great value, normal pin length though.

Break-away 0.1" 36-pin strip male header (10 pieces) – Pimoroni

Just got to wait for the rtc featherwing to be back in stock :)

Don’t forget to order the battery for the RTC.

What I would do is solder the RTC on first and make sure its working and that its back up battery is OK. Those batteries last ages, I have some Adafruit DS3231’s hooked up to Pi’s I bought easily over 5 years ago, probably close to 10 years ago, that are working just fine to this day. Regardless, you want to double check that its OK before you solder the display on top and block access.

Would writing a micropython script the prints the current time and then turning off the power and seeing if it still runs work?

Yeah, something like that. Once its all soldered in place, you have to set it to the correct time. Then remove power to the Feather, including the LIPO. Wait 10 or 15 minutes, power back up, then get the time from the RTC. If you set it to local time it should match your current local time.
I’ve done it in Micro Python on an RV3028 wired to a PICO. And tones of times with a RV3028 wired up to a Pi.

You may be able to do this without having to add the dedicated RTC board?

The PICO RP2040 has an onboard RTC, just no battery backup for it. Your Feather RP 2040 has the LIPO battery, which should keep the onboard RTC running just fine. You’d just have to make sure the LIPO never runs down. Plug it in to a power supply when not in use.
I don’t have a Feather RP2040, to test it out with. It would make things a lot thinner Just the feather and display. IMHO worth doing some research on, maybe start a new thread or do a search to see if anybody has done it.

OK i think ill order in the parts that are available and if it doesn’t work then ill just wait for the rtc to be in stock

Only issue is that i would have to keep a reliable connection because i don’t really want to have to.solder and unsolder if it doesnt work

I’ve been doing this on a Raspberry Pi for ages. I have several weather clocks that show day, date, time, temperature, etc in a scrolling message. One is portable and needed accurate time with no internet connection. Adding a RTC was the solution.

I have next to no experience doing the same thing on a Micro Controller though. I have a PICO with a PICO Breakout Garden and a RV3028 RTC breakout, it has a backup battery. I managed to set the time and read it back but that’s about as far as I have gone.

You should be able to set it and check it on the feather without having to do any soldering. I would think anyway? Plug the LIPO in and let it fully charge up. Then set the time via the USB connection and unplug the USB cable. Wait a while and then plug it back in and do a read. The “fun” part will be finding the python code to do that.
Adafruit are stellar at tutorials though, hard to find the one you want sometimes, but the info is usually on their site somewhere. That would be circuit python code.

What I used was Pimoroni’s Micro python code for my RV3028.