Help with display and RasPi not "working"

Try to send the NodeRED message to the NodeRED Debug, and see if the glitches are originating from NodeRED.

2 Likes

Well, what I’ve done is (how good are you with Node-Red?) cache the outgoing message.

If a message comes back (via MQTT) which is the message just sent but not compliant to the needs of the script, both messages are stuck together and sent to a debug node for me to look at.

So far none of them are coming back. :frowning:
Which is a bit annoying because I have 2 gremlins on the display now.

(Work in progress)

1 Like

Oh, here are some piccies.

(I hope this works)



(more to come)
I think there is a size limit per post.

1 Like



On a couple you can see the seconds changing.
Don’t worry about that.

Its the other critters that have my attention.

2 Likes

Hmm, interesting. Especially the one on line 0 - I’ll have to read over your code again, but I’m not sure that even makes sense at first :thinking:

1 Like

Oh, an update on “letting it run”…

It kinda didn’t work as I expected.

I can’t (could) leave it running.

If the error happens on different parts of the display, all well and good.
But if it is limited to specific parts, you can’t really see anything.

AND

When it happened, I needed the other computer on to get to the web page to wipe the display and start it off again.

So not really much good for finding the problem.

2 Likes

Just for the sake of establishing a baseline.

From the CLI/Terminal on said machine:

python3
Python 3.7.3 (default, Jan 22 2021, 20:04:44) 
[GCC 8.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import qwiic_serlcd
>>> myLCD = qwiic_serlcd.QwiicSerlcd()
>>> myLCD.setBacklight(127,0,0)
>>> 

The display does a thing where it flashes the R G B LED’s to full (with text on the screen saying the colour and brightness % I believe) then goes to the set colour.

And a whole lot of corrupt text on the screen.

It seems like the library has been changed so what used to do it cleanly is now including all this extra show off stuff which isn’t wanted by an end user.

Is anyone else here using this library?

2 Likes

SOLUTION!

Two lines - one command:

From:
myLCD.setBacklight(255,255,255)

To:
myLCD.setFastBacklight(255,255,255)

The Fast is needed to negate all the extra stuff it is/was doing.

2 Likes

Oh, but it hasn’t stopped the extraneous characters…

Sorry.

Though their frequency has reduced since I changed the (python) script. To negate badly formatted messages.

2 Likes

The only thing I can now suspect is timing.

I believe I am sending correctly formatted messages now, and if they are not, they are dealt with and not displayed.

That has reduced a lot of problems.

But there are 3 positions which are still getting the characters appearing.

3 Likes

Further update:

TIMING may be an issue.

I have modified the code so it waits and can only send one message at a time.

This has again reduced the extraneous things, but not totally eliminated them.

WORK IN PROGRESS.

3 Likes

Anyone?
Thoughts on if it could be needing pull up resistors on the I2C bus?
I think they would be 4k7, but am not 100% sure.

And they would go to the 3.3v rail. NOT the 5v.

You always need pull-up resistors on SDL and SDA lines. Thats how it works. Gives a stable logic value.
The only exception is if a device (like a Pic Microcontroller has internal pull-ups) Not sure is Pi has them.

I mostly use 10K pulled up to whatever is supplying power to the device but have also pulled them up to an output pin I have turned on.
Anywhere between 4K7 and 10K usually works, the higher resistance will give better communication stability.

Hope it helps

1 Like