Electronics > Beginners

Can't get SSD1306 OLED working on custom PCB

<< < (4/5) > >>

Nusa:

--- Quote from: Majek Ondrovic on April 07, 2019, 02:56:27 am ---
--- Quote from: Nusa on April 07, 2019, 02:36:16 am ---RST needs to be held low long enough to be recognized when power is first applied, and then allowed to go high. The capacitor is more than just a filter in this case.

--- End quote ---
Aha! very interesting, thank you. I'm glad I asked

--- End quote ---
For extra credit, see if you can figure out what the diode is for.

bson:

--- Quote from: Majek Ondrovic on April 06, 2019, 06:13:52 pm ---My limited understanding was that there are two modes of power, one where Vcc is supplied externally which is 9v for driving the OLEDs and VDD is supplied separately as the logic voltage level (3.3v?).
and the other is where Vcc is generated by an internal DC/DC voltage converter so the whole system can be supplied by 3.3v

--- End quote ---
Yeah, it apparently has a charge pump.  When this is used C1+/C1- and C2+/C2- are used for the capacitors for it.  It's powered by Vbat and needs to be enabled with command 8Dh.

It produces 7.5V, which means Iref is 5V, and to produce 12.5µA the external resistor needs to be 400k.  I supposed 390k is close enough.

bson:

--- Quote from: Majek Ondrovic on April 07, 2019, 01:36:10 am ---So I stumbled onto a schematic (see attached) for the pre-made OLEDs with PCB like you find on Amazon or AliExpress. I'm going to change my design to better match this one.

I also found another I2C hook-up guide for MCUs that seems to concur with most of the other schematic.

What I don't get is this reset circuit-- It has a 10k pull-up but also a diode and a filter cap? If RST/RESET is an input, and not interfacing to the MCU, what's the point of this?


--- End quote ---

The Adafruit schematic contains a similar arrangement so a 5V Arduino can issue a reset:



Also, their library twiddles the reset pin (if specified, if not it's assumed to be tied to the MCU reset pin) during init:


--- Code: ---    if(_rst >= 0) {
        // Toggle _rst low to reset
        pinMode(_rst, OUTPUT);
        digitalWrite(_rst, HIGH);
        delay(100);
        digitalWrite(_rst, LOW);
        delay(100);
        digitalWrite(_rst, HIGH);
        delay(200);
    }

--- End code ---

So make sure to do this, and issue the command to enable the charge pump.

Majek Ondrovic:

--- Quote from: bson on April 07, 2019, 07:46:06 am ---
Also, their library twiddles the reset pin (if specified, if not it's assumed to be tied to the MCU reset pin) during init:


--- End quote ---

This is good to know. I'm using the u8g2 library, set up with no reset pin, so it must also assume it's tied to the MCU reset

Majek Ondrovic:

--- Quote from: Nusa on April 07, 2019, 05:16:11 am ---
--- Quote from: Majek Ondrovic on April 07, 2019, 02:56:27 am ---
--- Quote from: Nusa on April 07, 2019, 02:36:16 am ---RST needs to be held low long enough to be recognized when power is first applied, and then allowed to go high. The capacitor is more than just a filter in this case.

--- End quote ---
Aha! very interesting, thank you. I'm glad I asked

--- End quote ---
For extra credit, see if you can figure out what the diode is for.

--- End quote ---

Hmm I'm not sure.. Does it discharge the cap quickly but allow it to charge up slowly, or something like that?  :-//

Navigation

[0] Message Index

[#] Next page

[*] Previous page

There was an error while thanking
Thanking...
Go to full version
Powered by SMFPacks Advanced Attachments Uploader Mod