SPI version of the ST 7920 GLCD

Post and discuss new components that you have created.
estevaon
Posts: 13
http://meble-kuchenne.info.pl
Joined: Tue Aug 29, 2023 7:42 pm
Has thanked: 4 times
Been thanked: 4 times

Flowcode v10 SPI version of the ST 7920 GLCD

Post by estevaon »

Hello,

I'm using a ST 7920 GLCD in a project, but it doesn't works in parallel mode ( and use too many pins), I'ts possible to create a SPI version to this component?

BenR
Matrix Staff
Posts: 1901
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 494 times
Been thanked: 668 times

Re: SPI version of the ST 7920 GLCD

Post by BenR »

Hello,

Yes looks possible, on your display do you have access to the pin (PSB) that sets if the display has a parallel or serial interface? This is often the limiting factor.

estevaon
Posts: 13
Joined: Tue Aug 29, 2023 7:42 pm
Has thanked: 4 times
Been thanked: 4 times

Re: SPI version of the ST 7920 GLCD

Post by estevaon »

Hello BenR,

Yes, this pin (PSB) exists.

BenR
Matrix Staff
Posts: 1901
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 494 times
Been thanked: 668 times

Re: SPI version of the ST 7920 GLCD

Post by BenR »

Great, I've made the change to the component to allow it to be configured as an SPI mode. I've not tested it so let us know how you get on.

The latest version is now available via the Help -> Library updates.

estevaon
Posts: 13
Joined: Tue Aug 29, 2023 7:42 pm
Has thanked: 4 times
Been thanked: 4 times

Re: SPI version of the ST 7920 GLCD

Post by estevaon »

Thank's Ben, it will very useful. I'll test and report the results.

estevaon
Posts: 13
Joined: Tue Aug 29, 2023 7:42 pm
Has thanked: 4 times
Been thanked: 4 times

Re: SPI version of the ST 7920 GLCD

Post by estevaon »

Hi BenR,

Unfortunately, the SPI mode doesn't work, squares appear instead of letters.

BenR
Matrix Staff
Posts: 1901
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 494 times
Been thanked: 668 times

Re: SPI version of the ST 7920 GLCD

Post by BenR »

Ok sounds like the write is maybe working but the read back isn't. I'll have another look at the code.

estevaon
Posts: 13
Joined: Tue Aug 29, 2023 7:42 pm
Has thanked: 4 times
Been thanked: 4 times

Re: SPI version of the ST 7920 GLCD

Post by estevaon »

Thank's BenR

estevaon
Posts: 13
Joined: Tue Aug 29, 2023 7:42 pm
Has thanked: 4 times
Been thanked: 4 times

Flowcode v10 Re: SPI version of the ST 7920 GLCD

Post by estevaon »

Hi BenR, the SPI Version is almost working, I made an example that draws a circle and writes "HELLO", but the cicle and the characters apears with some parts missing. Can you help me?
Attachments
TST_ST7920.fcfx
(16.01 KiB) Downloaded 103 times
ST_7920 (2).jpeg
ST_7920 (2).jpeg (38.83 KiB) Viewed 2454 times

BenR
Matrix Staff
Posts: 1901
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 494 times
Been thanked: 668 times

Re: SPI version of the ST 7920 GLCD

Post by BenR »

Hello,

It looks like the readback function is not quite right. I've had a look at the component code and found a bug so hopefully it's going to work better now. I've pushed the updated component to the library update system so let us know how you get on.

Post Reply