Hi, this is my first post so I hope it’s in the right place.
When I initially run the PicoW and Display, the LED_RGB is at low intensity, meaning that I can see the display properly. After running the demos the intensity is too high for comfortable viewing. The keyword information on GitHub does not ( that I can see ) provide a means to reduce the intensity, is this correct? If it is not correct can you point me in the right direction please.
Hi alphanumeric, thanks for the quick response, I had tried a lot of combinations but I think I had commented out the “led = RGBLED(6, 7, 8)” which initializes the led variable so the following “set” instruction was not followed.
I’ve just been playing with it, the instructions and the display. I thought that I understood it after 20 or so trials but it’s not as straight forward as it should be.
“led.set_rgb(1, 1, 1)” definitely controls the brightness (PWM? 0-100 for each setting can be used ) and the other “led = RGBLED(6, 7, 8)” is necessary to allow it to function ( setting this over 10 seems to affect the brightness of the screen backlight) but there are combinations where it just makes the screen go black and further information with separate, settings,colours and display updates will not be shown.
Once it goes down the black screen route it needs to be hard reset.
Thanks for the help, at least I can see the screen now without it “Burning my Eyez”
led = RGBLED(6, 7, 8) sets what pins are used to control the RGB LED. Pin 6 controls the Red LED, etc. You don’t play with those numbers once set.
led.set_rgb(0, 0, 0) is what sets the brightness / color. The values used are 8 bit, 0 to 255. 0 is off and 255 is max brightnes.
led.set_rgb(255, 0, 0) is red at full brightness,
led.set_rgb(0, 255, 0) is green at full brighness.
led.set_rgb(0, 0, 255) is blue at full brightness.
I see from the above posts that
led = RGBLED(6, 7, 8) assigns the Red, Green, Blue LEDs to pins 6, 7, 8 respectively, and
led.set_rgb(100, 140, 255) sets the intensity of the RGB leds (0…255)
Which works and is fine, however, rather than searching through a forum for basic elementary and necessary info about off the shelf hardware is there a specific document which lists parameters of these and other functions/classes.
Also, in the enviro+ demo there is the line, at line 21
led = RGBLED(6, 7, 10, invert=True)
Does anyone know what the ‘invert=True’ is used for and are there anymore parameters?
Some RGB LEDs are common Cathode and some are common Anode. That chages the way they work and wether you use a Hi (3,3V) to turn them on, or a Lo (ground) to turn them on.
Polarity wise, Anode is + and Cathode is - on a diode / LED.
invert=True lets you easily reverse the logic to compensate.
Thanks alphanumeric. I could not find this information and so may I ask from where you found this actual parameter spec as there must be much more valuable info for people such as me who do not know where to look and Google does not find it.
Is there a document/book which lists every function/class/parameter for MicroPython (for Pico W) as developed by Pimironi. I see examples in their excellent demos but there is no document to show what the authors have carefully created. Any lists would be gratefully received and studied.
I’m a retired Electronic Technician, that still likes to tinker with electronics. I’m no stranger to through hole components. ;) LED - RGB Common Cathode (pack of 5) - Pimoroni
SMT is just a different package. Electronically they are the same.
Which one you get, common cathode or common anode, affects how you wire it up, and what signal you use to turn it on.
As far as code goes, it doesn’t know which one is there. The code just turns a GPIO pin Hi or Lo. There were a few posts where the code was supposed to turn the LED on, but it turned off. And vice versa. That thingamabob had the other type of RGB LED.
Adding the invert=True to the Pimoroni RGBLED Library let you fix it by just adding one line to your code.
Finding detailed info on “some” of this stuff can “sometimes” be hard.
Lots of info here though.
Thanks alphanumeric… ditto, I started in electronics in the 60s and grew up from using 4-bit micros - and still carry on, albeit at a much slower pace! Standard or SM hardware holds no fears as I still design PCBs, but what is perplexing me deeply is my lack of documentation whilst experimenting with the really exellent Pimoroni range, specific to their custom micropython. Maybe the authors of their specific version will one day issue a book. I will certainly buy it!
Where did you locate that you could add the ‘invert=True’ to Pimoroni’s library as that is really the answer I am searching for so I can go there and not rely on other people stepping in to help.
In the meantime back to looking at the various demos and relying on the good and high standard of help on this forum. Thanks for the link.
Incidentally I posted another query about reading pixel data elsewhere in the forum and wonder if you have seen it or have any ideas?
If memory serves me, this is what went on. The libraries for the various packs did everything needed for that Pack, graphics, RGB LED etc. They were getting bloated and there was a lot of redundancy. Pimoroni decided to split some stuff up so they could have a universal library that would work on multiple packs. This helped keep the size of the uf2 file down, they were running out of space. This is where PICO Graphics came from. LEDRGB and the Button functions etc are now each a separate universal library that can be used on multiple packs etc.
Some packs have common Anode RGB LEDs, and some have common Cathode. The invert function made life easier, example file wise. It was one of those, you see it mentioned, and make note of it for latter use. ;)
Hi, to both of you, after my last post here I’ve spent some time looking around for information on Display_2 320x240 but also with anything that helps me learn the full extent of the MicroPython language.
Information on Display_2 is hard to find and it is not always something that is immediately useful. Looking around on this forum I found another post (Tutorials) regarding tutorials that appears redundant and replied just asking for a list of keywords as it is, for the people who need to produce it, the least effort for the most benefit.
What I’ve found;
Raspberry Pi have a very active Pico/PicoW forum and very good documentation on their product and on the RPi MicroPython they use. But very little on the Display_2 or the other products that rely on the display driver ST77889.