EEVblog Electronics Community Forum

Electronics => Beginners => Topic started by: jawa_master on September 15, 2023, 10:22:23 pm

Title: SSD1306 oled breakout, on portable atmega328 project
Post by: jawa_master on September 15, 2023, 10:22:23 pm
Hello.
I am working on making a wristwatch that will along with the time, show me tidal information.
Its atmega328 based, with a DS3231 RTC, a Bluetooth module, pressure sensor, and an 0.96 oled

For the oled, i wanted to solder the flex cable directly to my own board, to reduce the thickness of the watch. I was a good boy, and actually made a test-board, instead of just ordering the final board right away. On my test-board (SSD1306 oled flex cable, and the required passives) i got the screen to work reliably.

On the watch, however, it's not reliable at all. Occasionally, the screen will work as expected, and i can use the watch as intended. Then later it will turn on for a couple of seconds, before crashing, or not turn on at all. The buzzer, however, always work, so the problem seem to lie with the screen, and not the microprocessor. The only real differences between the watch and the test board, is that the watch uses 0603 instead of 0805, and that the 662k runs of a normal 3.7v lithium battery, instead of 5v.

When the screen was non-cooperating, I tried running a continuous i2c scanner. It only shows the RTC at 0x68, until I give the flex-cable a bit of a squeeze around the I/O area, which makes it discover the address briefly. I have tried multiple times to reflow the solder, and even swapping out the entire oled, but to no avail. I even tried soldering up another board, being EXTRA tidy, with the IIC connected to a separate, known working arduino nano

Things im considering, but would like inputs on before i make alterations:
     The I2C pullups are connected to the 3-4 V of the lithium battery, while the screen is connected to the 3.3 of the 662K. Might cause issues ?
     I tried hooking my power supply up to the vcc and ground pins. This seemed to be a LITTLE more reliable. Could it be a power delivery issue ?


EDIT: Looking at datasheets, i also added a 1uF cap on the in AND output of the 662K
Title: Re: SSD1306 oled breakout, on portable atmega328 project
Post by: DavidAlfa on September 15, 2023, 10:39:29 pm
The pullups that way will increase current consumption, but won't cause damage, the excess voltage will get clamped by the ESD diodes in the pins.
What you did with the HC06 is not good, leaving it floating!
Better you used a p-ch fet as power switch for secondary circuits (Aka auxiliar), oled, pullups, sensors, modules etc.
So the when the cpu goes to sleep most of the power can be turned off, only the cpu remains at the lowest power state, waiting for button press.

You can also use n-ch to switch as high-side switches if wyou make a small charge pump with two unused mcu pins.
You migh use any other commercially available charge pump, but they tend to consume more power.
I did this in a small recent project (https://www.eevblog.com/forum/microcontrollers/$0-25-hk32f030m-(cortex-m0-32mhz-16kb-2kb)/msg4903169/#msg4903169) using sod523 diodes, the thing was extremely small! (Also soldering them was PAIN).