I2C OLED thread

Re: I2C OLED thread

Postby shufflez » Thu Nov 15, 2012 11:49 pm

Strange thing is (strange pixelation also happens with different I2C speed BTW!) that it does work fine when OLED is connected after FC has fully booted.
Also tried this on my Flyduino MEGA and sure enough, same shizzle, different board :) So that leads me to suspect some kind of I2C initialization error.
Maybe sensors are polled too soon for OLED to boot up? Dunno the code, but some geekish logic applied there :)
shufflez
 
Posts: 42
Joined: Sat Nov 19, 2011 5:26 pm
Location: Amsterdam, Netherlands

Re: I2C OLED thread

Postby chopc » Sun Nov 18, 2012 12:28 am

Hopefully the right place to ask ,,
Have just received obe of these displays and wanted to check it out using a bare Arduino ( Considering the display for a non 'copter idea) with the supplied ( China dealer) Arduino sketch I get precisely nothing on the display , no sign of any life !! , Have any members managed to get a display using a bare Arduino Mega or Duemilanove ?
I've had a few i2c projects running on both boards and the results with the Crius board are almost as if the address ( 0x3c ) is wrong and the device is not replying to any commands

Art
chopc
 
Posts: 1
Joined: Sun Nov 18, 2012 12:16 am

Re: I2C OLED thread

Postby Woppit » Tue Nov 27, 2012 11:48 am

Bergerac56 wrote:I have two crius oled (co-16) and have the same problem with both. Random dots at startup unless it is connecetd after full initialisation of the oled. Could it be a problem with the init sequence?


Hi, I have 2 of these screens and both give me the dots randomly on FC Boot. Tried connecting after and so far it works, first time into lcd config I get blank screen, come out I get the aborting exit, go in again I get all the config info but upside down??? reboot the FC and if the screen does not crash I get logo the right way up!
Woppit
 
Posts: 22
Joined: Tue Jul 17, 2012 11:47 pm

Re: I2C OLED thread

Postby Bergerac56 » Wed Nov 28, 2012 9:51 pm

I GOT IT :)
After a lot of investigations it seemed that the reset/initialisation of the crius OLED co-16 v1.0 was the problem. I tried to solve this by modifying the software without result. As I did not find the "reset" pin to modify the way the oled was initializing, I used another way to stabilize the initialization process.

I just inserted a 100 ohm resistor in the positive line of the oled. This lowers very slightly the positive voltage and, combined with the capacitance on the PCboard, adds some filtering of the 5v. This permits a correct reset of the oled driver chip. The easiest way is to insert the resistor in the positive (red) wire but it is also possible to insert it on the pcb itself (needs very good eyes :) ).

Material: 1x 100 ohm 1/4 or 1/8 watt
a short piece of heat shrinkable tube to protect the resistor

Cut the red wire
Solder the resistor and protect it with the tube
And that's it.

Tried on several crius oled. Works perfectly :)

Enjoy
Last edited by Bergerac56 on Thu Nov 29, 2012 6:55 pm, edited 1 time in total.
Bergerac56
 
Posts: 5
Joined: Sun Nov 11, 2012 6:35 pm

Re: I2C OLED thread

Postby Hamburger » Thu Nov 29, 2012 11:52 am

thumbs up - good catch!
User avatar
Hamburger
 
Posts: 2553
Joined: Tue Mar 01, 2011 2:14 pm
Location: air

Re: I2C OLED thread

Postby hansth » Wed Dec 05, 2012 9:10 pm

Have the same issue. Have not fully tested yet, but the 30 pin connector of the OLED seems compatible with :

http://www.wide.hk/download/UG-2864HSWEG01.rar

Reset pin should be pin 14 of the 30 pin flat cable. seems to be connected to supply 3.3V.
hansth
 
Posts: 1
Joined: Wed Dec 05, 2012 9:04 pm

Re: I2C OLED thread

Postby petgu » Thu Dec 06, 2012 9:12 am

Using the Crius OLED: The board does not seem to have SDAin and SDAout connected to each other so you will not receive ACK from it.

For those fiddeling with your own code for bare Arduino you will have to make your code not care about ACK.

With this and the 100ohm trick I got the Crius OLED working rigth :)

Found this out by reading:
http://www.adafruit.com/datasheets/UG-2 ... 0guide.pdf
And watching the images of the board on EBAY eg.:
http://www.ebay.com/itm/CRIUS-CO-16-OLE ... 4609079ea4
petgu
 
Posts: 1
Joined: Thu Dec 06, 2012 8:50 am

Re: I2C OLED thread

Postby Bergerac56 » Thu Dec 06, 2012 10:35 pm

Good suggestion.

But, in the specific case of the multiwii, connecting D1 and D2 together did not solve the problem for me. It was possible to differ the reset (with an RC circuit) but isolating the reset pin and addind the circuitry was more complex than simply adding the 100 ohm resistor ;)
Bergerac56
 
Posts: 5
Joined: Sun Nov 11, 2012 6:35 pm

Re: I2C OLED thread

Postby jgarnham47 » Sun Dec 09, 2012 12:47 pm

To add to the story ...

The 100 ohm resistor trick didn't work for me. I also tried 470 ohms which made and it worse and 47 ohms. I attached a scope to the 5V supply and it rings, perhaps due to the inductor on the board, and when the display comes on the voltage dips and screws up the display again.

Like many I felt the reset pin is the issue. Most microprocessors and interface devices like their reset pin to be low on power up so they can reset internal registers on the rising edge of reset, the most common technique is to add an RC network to the pin. Because we are only using a 4 pin connector, the reset it tied to the supply and it becomes a race condition that may be dependance on the rate of rise of the supply. The evaluation kit mentioned above says 10ms low on the pin, which seems to long. Looking at something like the SSD1306 data sheet it says 3us is enough, page 27. http://www.solomon-systech.com/en/product/display-ic/oled-driver-controller/ssd1306/

I then used a scalpel, and 0.5mm soldering iron bit to isolate the reset pin of the display connector and lift it off the board. To this I added a 100nF cap and 100K resistor to form a standard RC circuit and ran the board again. To my surprise it just didn't work :(

Also in the data sheet above (second from last page) it gives the exact software configuration of the chip. I replicated this in the OLED init routine and followed it with a simple text message. Still didn't work consistently.

I have wasted a day and I am still at a loss, it's not the reset pin I suspected it was but it does appear to be a function of the power supply. Before I pull all the components off the board and start again from scratch, based on the discussion above does anybody else have another suggestion or two ??

Regards ... John
Attachments
P1040828.jpg
Isolation of reset pin for testing
P1040824.jpg
RC Network shows delayed rise of reset pin (red) compared to 5V (Yellow)
P1040826.jpg
Series resistor causing ringing on 5V supply of board
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby Jantar » Sun Dec 09, 2012 5:19 pm

RESET pin should be pin 14 of the 30 pin flat cable.
On the photo you can see that you have used the pin 13.
Jantar
 
Posts: 6
Joined: Sun Dec 09, 2012 5:02 pm

Re: I2C OLED thread

Postby Hamburger » Sun Dec 09, 2012 5:25 pm

Is it positive these problems are limited to crius oleds?
I have 3 oleds from wide.hk direct or via ebay and never had any of the issues with powerup / init.
User avatar
Hamburger
 
Posts: 2553
Joined: Tue Mar 01, 2011 2:14 pm
Location: air

Re: I2C OLED thread

Postby jgarnham47 » Sun Dec 09, 2012 9:34 pm

Jantar wrote:RESET pin should be pin 14 of the 30 pin flat cable.
On the photo you can see that you have used the pin 13.


D'Oh, did I really get the wrong pin?!!

These things are too small even with a magnifying lamp.

Thanks very much, let me go try again ...

John
Attachments
008.jpg
Pin 13, D'Oh !!
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby jgarnham47 » Sun Dec 09, 2012 10:27 pm

YAY, FIXED IT :D Simple schoolboy error before, using the right pin certainly helps! :oops: An RC network is all that is required.

I have several MultiWii boards but the Crius AIO Pro has constantly refused to work with the OLED display. I just tested it and it worked 20 times without fault :ugeek:

I have another board to double check and then I will post the best layout with photos later in the week (getting late here in UK).

For those that can't wait ... you just need something like a 100K resistor connected between 5V on the 4 pin connector and pin 14 on the display ribbon (once you have cut either side of the pin and lifted it off the board with a small iron, as shown above, with some insulating tape). Then a small capacitor between 10nF to 100nF connected between pin 14 and GND on the 4 pin connector.

Yes, it's that simple after all :)

Thank you Jantar for pointing out the obvious mistake.

Regards ... John
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby Bergerac56 » Mon Dec 10, 2012 1:32 pm

Héhéhé. I confirm, like said in my last post, that an RC network on the reset pin (14!) works. I did it too on one of my crius oled. I have today 4 crius oled at home and all 4 work with the 100 ohm. As I believe that the reset problem comes from a bad "raise" of the power supply of the multiwii controller used, the 100 ohm could work with some boards and not with others. If well equiped, the "reset" solution is certainly the most "universal"...

BTW I tested also with 2 Crius AIO V1.1 boards, with one HK SE V2 and one HK Lite V1 It worked with both "tricks"
Bergerac56
 
Posts: 5
Joined: Sun Nov 11, 2012 6:35 pm

Re: I2C OLED thread

Postby jgarnham47 » Mon Dec 10, 2012 9:25 pm

Just to finish off then ...

1) Start by using a scalpel and iron to isolate pin 14 (not 13!) and place some tape to prevent shorting.
2) You must pickup VDD from pin 9 for the resistor, this is the 3.3V supply used by the "core logic operation" (you can probably use the 5V supply but you will be over-driving the input and relying on a "catch" diode on the chips input). Then soldered a 100K resistor between pin 9 and 14.
3) Solder a 10nF capacitor (or 100nF) to pin 14 on the other side.
4) Connect the other-side of the capacitor to VSS (GND), Pin 30/31 is a convenient location.

Yes, it's tiny delicate work. If you are using wire ended components then I would probably just solder to the back of the 4 pin I2C connector and have a flying lead to pin 14.

:D At last, no more re-booting to see the display :D

Regards ... John
Attachments
final.jpg
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby jgarnham47 » Mon Dec 10, 2012 10:45 pm

Hamburger wrote:Is it positive these problems are limited to crius oleds?
I have 3 oleds from wide.hk direct or via ebay and never had any of the issues with powerup / init.


Yes, I believe it is just the Crius version. I got mine from RCTimer.
The HK one looks to have a different set of components with larger capacitors.
The Paris version from MultiWiiCopter also seems to to work.

Regards ... John
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby spagoziak » Tue Dec 11, 2012 5:47 am

Hi folks,

I didn't do enough research before I got the Crius CO-16 v1.0, so when I enabled the defines below, as you might have guessed, NOTHING happened on that screen. No light, no dots, nothing. It's plugged into the usual Crius SE.

Is this likely the 100ohm resistor + reset issue described above?

spag

Code used:
Code: Select all
#define LCD_CONF
#define OLED_I2C_128x64
#define SUPPRESS_OLED_I2C_128x64LOGO
#define LCD_TELEMETRY
#define LCD_TELEMETRY_STEP "015240"
spagoziak
 
Posts: 171
Joined: Thu Jan 20, 2011 1:18 am

Re: I2C OLED thread

Postby jgarnham47 » Tue Dec 11, 2012 8:46 pm

That set of defines should be okay. My two Crius displays always showed something, the usual fault is a series of random dots on the screen that gets brighter than dimmer a couple of times but will not clear to give the correct display text. Best check your I2C connections again, especially SDA and SCL.
Regards ... John
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby Hamburger » Thu Dec 13, 2012 12:13 pm

jgarnham47 wrote:
Hamburger wrote:Is it positive these problems are limited to crius oleds?


Yes, I believe it is just the Crius version. I got mine from RCTimer.

John,
thank you for clarifying. I will add a note to the wiki. Getting the oled crom another dealer sbould be the easiest route.
User avatar
Hamburger
 
Posts: 2553
Joined: Tue Mar 01, 2011 2:14 pm
Location: air

Re: I2C OLED thread

Postby ardufriki » Thu Dec 13, 2012 5:04 pm

Hi all, I have this electronics:. It seems to be like Crius SE, but not sure. I have bought also a CRIUS CO-16 OLED 128x64 display, and I dont see anything when I connect to the board. May be the Multiwii 2.1 version inside doesnt have enable the corresponding "#defines".

That is not a problem for now, as I can connect to my drone over bluetooth an android phone. Later I will try to extract the .hex file inside my board (for backup pourpouse) and flash a compiled one with the OLED #defines...but this is a project.

What I am trying now, without success, is to get a simple "ack" from the OLED display, conected to an arduino Nano and nothing else. I use the I2C_scanner sketch from arduino playground page, no pullup resistors (as it is only one device), but I get only "no devices found" message. Pretty sure the wiring is OK...

For now, I dont have a logic analyzer to check more..

Any help?
Thanks in advance.
ardufriki
 
Posts: 88
Joined: Thu Dec 13, 2012 4:47 pm

Re: I2C OLED thread

Postby achiii » Sun Dec 16, 2012 1:32 pm

Hi,

I am currently setting up an AIOP board for a hex. I got one of the RCtimer OLEDs. I had the "random white dots problem" which was fixed by a single 100ohm resistor placed on the positive line in. My OLED now displays properly:
Image

BUT, I dont seem to get the PID setting pages. And the battery voltage page is not reading properly (but I think I have to spend more time understanding the note on the config page about this) . I have, I think, 3 completely blank pages. I know one should be PID setting. Can someone tell me what setting I should have changed to be able to configure pids on the OLED? I can navigate through pages with full forward and full right roll stick input, but thats it.

I have:

#define LCD_CONF
#define LCD_CONF_AUX
#define OLED_I2C_128x64 // I2C LCD: OLED viewtopic.php?f=7&t=1350
#define LCD_TELEMETRY
#define LCD_TELEMETRY_STEP "0123456789" // must begin with 0

update: I notice that I get tons of I2c errors, and weird jumps in sensor values, if the OLED is left on some of the pages. ?????

update 2: I turned off vbatt and buzzer and stopped getting I2c errors. Then I stopped having the gps work. Couldnt figure out what was going on. Messed around with gps and settings for a bunch and THEN I somehow ended up in the pid editing page on the OLED. Is it just a stick combo to get into that? And if so what is it? once I exited out of there, my GPS came back. I am confused about what just happened.
achiii
 
Posts: 2
Joined: Sun Dec 16, 2012 1:19 pm

Re: I2C OLED thread

Postby jgarnham47 » Sun Dec 16, 2012 9:31 pm

Once you go into the PID menus system the processor stays there until you exit, so GPS reads will be off-line. If you are messing about in this area try adding the telemetry pages too. For instructions on Tx sticks check out this excellent page ... http://multiwii.googlecode.com/svn/branches/Hamburger/ I print them out and then laminated them and they stay in my Tx box for reference. LCD mode is shown. BTW thanks Hamburger :)
John
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby achiii » Sun Dec 16, 2012 9:58 pm

Oh, that was helpful. Thanks!
achiii
 
Posts: 2
Joined: Sun Dec 16, 2012 1:19 pm

Re: I2C OLED thread

Postby ardufriki » Tue Dec 18, 2012 4:21 pm

Hi again, anybody has got this OLED working with "Wire.h" (i2c) library from Arduino IDE? Or with the examples from WIDE.HK? I mean, in a separate scenary, not conected to MultiWii board, but to Arduino board...
ardufriki
 
Posts: 88
Joined: Thu Dec 13, 2012 4:47 pm

Re: I2C OLED thread

Postby jlouden » Thu Jan 10, 2013 1:36 am

I have one of the Crius boards and I get the top two lines on the display. I can change the text so I know I am communicating. I can't get the board to show anything else. I have tried different combinations of settings in the telemetry section but nothing seems to make any difference.

Any ideas?
jlouden
 
Posts: 6
Joined: Sat Dec 08, 2012 11:12 pm

Re: I2C OLED thread

Postby jlouden » Thu Jan 10, 2013 1:58 am

I just found the problem. I had to turn up the end points on my XMTR to get the board to recognize the commands.
jlouden
 
Posts: 6
Joined: Sat Dec 08, 2012 11:12 pm

Re: I2C OLED thread

Postby scanman » Sun Jan 13, 2013 10:07 pm

fantastic thread thanks to all contributors, got my crius AIO and crius oled display working in 20 minutes after having "random snow flake dots" issue by using 100 ohm resistor (guess i was lucky not to have to use the capacitor.) the link to hamburgers stick commands downloads was a bonus!
Thanks everyone!
scanman
 
Posts: 74
Joined: Thu Jun 21, 2012 9:26 am
Location: Durban, South Africa

Re: I2C OLED thread

Postby dominicclifton » Tue Feb 05, 2013 10:30 pm

ardufriki wrote:Hi again, anybody has got this OLED working with "Wire.h" (i2c) library from Arduino IDE? Or with the examples from WIDE.HK? I mean, in a separate scenary, not conected to MultiWii board, but to Arduino board...


Not with Wire.h, but i combined the MultiWii I2C code and the demo code and got it working just fine.

I uploaded the resulting code to github, it works with Arduino IDE 1.0.3.

https://github.com/hydra/UG2864HSWEG01

I am curious as to why it doesn't work with the Wire library, if you figure it out please let me know.
dominicclifton
 
Posts: 202
Joined: Tue Feb 05, 2013 10:28 pm

Re: I2C OLED thread

Postby Hubbie0001 » Sun Feb 24, 2013 10:44 pm

My oled works with your coding. Thank you. Greate job. The reason off the failure with the wire-library is the missing acknowledge from the oled. It never send an ack. I have checked it with a 2-ray oscilloscope.
Hubbie0001
 
Posts: 1
Joined: Sun Feb 24, 2013 10:15 pm

Re: I2C OLED thread

Postby ardufriki » Thu Mar 21, 2013 10:35 am

Hubbie0001 wrote:My oled works with your coding. Thank you. Greate job. The reason off the failure with the wire-library is the missing acknowledge from the oled. It never send an ack. I have checked it with a 2-ray oscilloscope.


wow, good info. Thanks.
ardufriki
 
Posts: 88
Joined: Thu Dec 13, 2012 4:47 pm

Re: I2C OLED thread

Postby szepnorbee » Sat Mar 23, 2013 12:24 pm

Anyone know how to apply this in the MW code? With this code works without resistor mod? Thanks
szepnorbee
 
Posts: 4
Joined: Wed Dec 26, 2012 10:15 am

Re: I2C OLED thread

Postby ardufriki » Thu Mar 28, 2013 9:25 am

Checking deeply this in the datasheet, there are two wires coming from the sd1306 controller, but in this oled only the SDIN is connected. If you join SDOUT to SDIN it should send the ACK (not tested, dificult to solder...).
ardufriki
 
Posts: 88
Joined: Thu Dec 13, 2012 4:47 pm

Re: I2C OLED thread

Postby dominicclifton » Fri Mar 29, 2013 8:48 pm

jgarnham47 wrote:Yes, it's tiny delicate work. If you are using wire ended components then I would probably just solder to the back of the 4 pin I2C connector and have a flying lead to pin 14.

:D At last, no more re-booting to see the display :D



Thanks for posting details of it, today I have fixed my OLED screen using wire ended components, and yes it really is a bit fiddly. Especially lifting pin 14 from the board. Still, it seems to work OK.

I used some silicon sealant/adhesive to hold the components in place too. Glue gun would probably be OK for that too but i don't have mine out here right now.

Here's a picture of my fix, not as clean as johns but it works just fine.

Image
dominicclifton
 
Posts: 202
Joined: Tue Feb 05, 2013 10:28 pm

Re: I2C OLED thread

Postby EdAmps » Sat Apr 06, 2013 4:01 am

Greetings! I just received two Crius CO-16 OLED displays from RCTimer and have experienced the random dot problem.
Both units act the same on an AOIP controller from Hobby King. Rather than install a 100 ohm resistor in series with the
5 volt line I came up with a better and reliable solution. Apparently, applying 5 volts to the module and controller at the same time scrambles the display. I designed a circuit using a NE555 timer IC to create a turn on delay of the 5 volts applied to the CO-16. About a 1.5 second delay does the trick and works every time. I used pin 3 of the NE555 to power the display directly, as the 555 can source over 200 ma. Hope this info helps. :)
EdAmps
 
Posts: 3
Joined: Sat Apr 06, 2013 3:47 am

Re: I2C OLED thread

Postby ardufriki » Tue Apr 09, 2013 8:30 am

ardufriki wrote:Checking deeply this in the datasheet, there are two wires coming from the sd1306 controller, but in this oled only the SDIN is connected. If you join SDOUT to SDIN it should send the ACK (not tested, dificult to solder...).


Hi, I´ve got the ACK from the SSD1303 chip inside our OLED(seen in logic analyzer). Just joining pins 19 and 20 with a drop of soldering (no so hard to do). Now it works fine with Adafriut libraries and other Arduino skectches.
ardufriki
 
Posts: 88
Joined: Thu Dec 13, 2012 4:47 pm

Re: I2C OLED thread

Postby dominicclifton » Tue Apr 16, 2013 11:01 am

that's great ardufriki. i'll try that on mine when i get a chance.
dominicclifton
 
Posts: 202
Joined: Tue Feb 05, 2013 10:28 pm

Re: I2C OLED thread

Postby jgarnham47 » Sun Apr 21, 2013 12:08 pm

dominicclifton wrote:Here's a picture of my fix, not as clean as johns but it works just fine.


Good effort Dominic, especially with wire-ended components :D

Regards ... John
jgarnham47
 
Posts: 19
Joined: Fri Nov 23, 2012 10:30 pm

Re: I2C OLED thread

Postby maxid » Wed May 01, 2013 6:20 am

Hello, I'm new here, and I come because buy 2 modules co-16 on ebay. for use with Arduino, but I can not print to display some character. Not if they are damaged or my code is wrong.
Download the sample from adafruit and http://www.wide.hk/download/i2c_OLED.rar
Any help me?


Hola , soy nuevo aqui, y vengo porque compre 2 modulos co-16 en ebay. para usarlos con Arduino, pero no logro que imprima en pantalla algun caracter. No se si estan dañados o mi codigo está mal.
http://www.ebay.com/itm/RC-CRIUS-CO-16- ... 3a7a55a269

Baje el ejemplo de adafruit y de http://www.wide.hk/download/i2c_OLED.rar
Alguna ayuda?
maxid
 
Posts: 1
Joined: Mon Apr 29, 2013 10:52 am

Re: I2C OLED thread

Postby Quad FRITZ » Tue May 07, 2013 12:28 pm

With the CRIUS Oled I have that startup problem only when using fully charged 4s Lipo (Crius AIO Pro V2) odd...

What ever- is there a way to start showing the telemetry pages WITHOUT any stick input?
I have limited my stick values to 80%, so I am not able to activate it via remote without changing this every time- PITA ;-)

Thanks a lot!
Quad FRITZ
 
Posts: 44
Joined: Wed Apr 25, 2012 11:21 pm

Re: I2C OLED thread

Postby Hamburger » Tue May 07, 2013 12:40 pm

use lcd.telemetry.step and first page in that sequence gets loaded&updated automagically.

I use dual rate switching on my tx in such cases to enter stick combo inputs - like for stepping through the telemetry sequence.
User avatar
Hamburger
 
Posts: 2553
Joined: Tue Mar 01, 2011 2:14 pm
Location: air

Re: I2C OLED thread

Postby Quad FRITZ » Tue May 07, 2013 1:50 pm

Awesome-
great idea- just put a mix on a unused switch and assign a stick combo- this way I will not use an extra channel!
Perhaps program it that way that the mix is disabled as soon as there is throttle input also- otherwise one also could name it the "flip switch" ;-)
Thanks!
Quad FRITZ
 
Posts: 44
Joined: Wed Apr 25, 2012 11:21 pm

Re: I2C OLED thread

Postby hudibras » Thu May 23, 2013 2:58 am

ardufriki wrote:
ardufriki wrote:Checking deeply this in the datasheet, there are two wires coming from the sd1306 controller, but in this oled only the SDIN is connected. If you join SDOUT to SDIN it should send the ACK (not tested, dificult to solder...).


Hi, I´ve got the ACK from the SSD1303 chip inside our OLED(seen in logic analyzer). Just joining pins 19 and 20 with a drop of soldering (no so hard to do). Now it works fine with Adafriut libraries and other Arduino skectches.


Thanks for your help, that did the job. Had made reset circuit, but this did the trick.
hudibras
 
Posts: 1
Joined: Thu May 23, 2013 2:54 am

Re: I2C OLED thread

Postby llima31 » Wed May 29, 2013 11:00 am

Hello, first of all great thread, there is a lot of usefull info here

I also bought one of these displays, I implemented the RC circuit modification, and the random dots issue went away, but there is another issue in my case.
Everytime I power up the quad, it enters the configuration mode (I can see it in the display), and when I exit the configuration mode, it sort of reboots, and enters again in the configuration mode, everytime I exit the cnfig mode it does it again.

Could this be solved with the ACK modification, joining pins 19 and 20, or could it be a MultiWii configuration issue?
Also regarding the ACK modification, should the pins be joined in place, or must any one of them be unsoldered from the board?

Thank you in advance

Lima
llima31
 
Posts: 1
Joined: Wed May 29, 2013 10:47 am

Re: I2C OLED thread

Postby Antscran » Thu Aug 29, 2013 1:04 pm

Hi all,

Just read this post all the way through to see where I am going wrong or if the display is faulty. I am just trying to connect to an Arduino Uno to start with.

I have a no display issue, not even the random dots issue which seems to be the main cause for concern, have tried several software samples including the one posted earlier by 'dominicclifton' here https://github.com/hydra/UG2864HSWEG01

I have also tried the 100 Ohm resistor trick, and double checked the connections 5V, Gnd, SDA (Arduino A4) and SCL (Arduino A5).

I am going to try the pin 14 reset fix (posted by jgarnham47) next but out of idea's after that, any further tips anyone can offer as a potential solution?

Cheers,

Ant
Antscran
 
Posts: 1
Joined: Thu Aug 29, 2013 12:51 pm

Re: I2C OLED thread

Postby keepitsimple » Wed Oct 30, 2013 10:02 pm

Antscran wrote:Hi all,

Just read this post all the way through to see where I am going wrong or if the display is faulty. I am just trying to connect to an Arduino Uno to start with.

I have a no display issue, not even the random dots issue which seems to be the main cause for concern, have tried several software samples including the one posted earlier by 'dominicclifton' here https://github.com/hydra/UG2864HSWEG01

I have also tried the 100 Ohm resistor trick, and double checked the connections 5V, Gnd, SDA (Arduino A4) and SCL (Arduino A5).

I am going to try the pin 14 reset fix (posted by jgarnham47) next but out of idea's after that, any further tips anyone can offer as a potential solution?

Cheers,

Ant


Hi,

try enabeling the internal pullups, seems that the crius has none. (very wise)
SCL and SDA will never go high 8-)


Code: Select all
void i2c_init(void) {
//  #if defined(INTERNAL_I2C_PULLUPS)
    I2C_PULLUPS_ENABLE
//  #else
//    I2C_PULLUPS_DISABLE
//  #endif
  TWSR = 0;                                    // no prescaler => prescaler = 1
  TWBR = ((F_CPU / I2C_SPEED) - 16) / 2;   // change the I2C clock rate
  TWCR = 1<<TWEN;                              // enable twi module, no interrupt
}


regards from hans
keepitsimple
 
Posts: 3
Joined: Tue Oct 29, 2013 8:32 pm

Re: I2C OLED thread

Postby flyman777 » Fri Nov 01, 2013 6:59 pm

Hi all Oled users,

OK that is warm beer !
I tried to make my Crius V1.0 Oled working , i had just a snow storm on the screen.
Then i tried to hack with different pins of the connector with no relevant results.
I tried with a 1OO ohm resistor with success only at 25%.
I tried with software mods, no result.
Then i remember that EdAmps (Sat Apr 06 2013) had introduced a power startup delay of 1.5 seconds for the Oled device. This feature had no reply in this threat.
So i mounted on a prototyp board this circuit with a NE55 and look that is great, it work's with 100% reliability.
I made a schema layout for those who are not confident with this chip, it uses only 5 components and is very fast to build (for me 30 minutes).
The circuit is inserted between the power supply i2c-Oled lines (+5V - GND), SDA and SCL remains continuous.
You can find the Eagle files in attaching ZIP.
Hope this can help someone and thanks again to EdAmps.

Cheers
Claude
Attachments
Power_Up_Delay_555.zip
(74.99 KiB) Downloaded 264 times
flyman777
 
Posts: 55
Joined: Mon Sep 19, 2011 1:44 pm

Re: I2C OLED thread

Postby o_lampe » Mon Nov 11, 2013 9:16 pm

I've just read the whole thread and was wondering, if it would be possible to use an unused ATMega output pin as 5V source for the OLED?
This way, a delayed powerup for the OLED would be done with a few lines of code.
How much is the current consumption of the OLED?
o_lampe
 
Posts: 117
Joined: Sat Nov 02, 2013 5:09 pm

Re: I2C OLED thread

Postby Hamburger » Mon Nov 11, 2013 9:36 pm

Never had any such poweron ti.ing problems with any of my 0.96 i2c oleds of this type. I got mine from wide.hk is the obvious difference but do they really sell a different product?
User avatar
Hamburger
 
Posts: 2553
Joined: Tue Mar 01, 2011 2:14 pm
Location: air

Re: I2C OLED thread

Postby jsystem » Sat Jan 31, 2015 5:06 pm

fyi, my Crius CO-16 version v1.2 works like charm with NAZE32/cleanflight without any modifications. Seems the issue solved from v1.2
jsystem
 
Posts: 3
Joined: Sat Jan 31, 2015 5:03 pm

Re: I2C OLED thread

Postby Lecostarius » Sun Feb 01, 2015 11:09 pm

All,

not power-up related, but in case you want to use the OLED and control the row and column when printing characters to the screen and want to use the 8x5 font that is supplied with the MWii code, the function that sets the cursor position is not right. It looks like this (in LCD.cpp):

Code: Select all
void i2c_OLED_set_XY(byte col, byte row) {        //  Not used in MW V2.0 but its here anyway!
  i2c_OLED_send_cmd(0xb0+row);                //set page address
  i2c_OLED_send_cmd(0x00+(8*col&0x0f));       //set low col address
  i2c_OLED_send_cmd(0x10+((8*col>>4)&0x0f)); 


This is fine for a 8x8 font, but not for the 8x5 font that MultiWii uses. If you change the two constants '8' in the last two lines to '6', all is fine.

Cheers, Leco
Lecostarius
 
Posts: 46
Joined: Mon Oct 20, 2014 11:29 pm

Next

Return to Shields, boards and sensors

Who is online

Users browsing this forum: No registered users and 2 guests