Go Down

Topic: RA8875 8-bit or 16-bit Arduino Library?  (Read 553 times) previous topic - next topic

BrettAshtonClinton

Hello, first post here,
    I am programming my Arduino(s) for a CNC router I am building from scratch. I have programmed thermocouples(SPI), stepper motor drivers, Micro-SD card reader (SPI), etcetera... Now, the real kicker is the only RA8875 libraries I can find use SPI ONLY even though the board supports I2C, 8-Bit, 16-Bit parallel. Of course the display works with SPI, however, there is a core flaw with the RA8875 chip itself which does not allow it to play nice with other SPI connected devices without a **** ton of external wiring. Therefore, I can either use my display ONLY or I can use everything else without the display. I do not want to have to buy another display with say an SSD 1963 unless I have to. You may laugh, but my current setup is 2 Arduino boards. The Due is donated to driving the display and the mega everything else with the mega communicating through Serial all of the data to the Due with the Due communicating back commands from the touch screen on the display.

Are there any libraries out there that will support the RA8875 in 8-bit or 16-bit mode so I don't have to make things complicated with the 2 Arduino boards and just use the Due?


Any suggestions are useful and thank you for your time!

ZinggJM

Hi BrettAshtonClinton,

should I answer, or should I let it be?

I am not good at serving Newbies, and you didn't tell us about your background, nor your display, e.g. a link to it.

I used a Waveshare 7inch RA8875 display, both with SPI and P16. You might take a look at my library GxTFT.

I do not recommend this library for Newbies, unless there is no other option.

Good Luck!
No personal message please; any question may be useful for other users. Use code tags for code. Make links clickable with URL tags. Provide links to the product in question.

BrettAshtonClinton

Hi,
    I am not new to programming AT ALL. However, driving LCDs is very new to me. I could spend months digging into the RA8875 datasheet to program my own 8-bit or 16-bit P library but why would I lol.

https://www.buydisplay.com/default/tft-5-inch-lcd-display-module-controller-board-serial-i2c-ra8875.

It is what I can tell a standard RA8875 board with integrated LCD with a separate touchscreen interface, not using the RA8875 touch features. I could easily solder the headers on the side of the PCB to hook it up to parallel mode if your library works with my display.


Thank you for replying :).

ZinggJM

Hi,

unfortunately your display uses a different screen resolution (one of the two the controller supports? I don't remember), and I don't know how easy it would be to change the display class.

Maybe David Prentice can help with MCUFRIEND_kbv.
No personal message please; any question may be useful for other users. Use code tags for code. Make links clickable with URL tags. Provide links to the product in question.

BrettAshtonClinton

Hello again,
 
Sorry, the link I provided was for the lower resolution model.

https://www.buydisplay.com/default/5-inch-tft-lcd-module-800x480-display-controller-i2c-serial-spi

I have the 800x480 display. I was unaware of the lower resolution as well which is why I did not check the resolution past the controller. I do like the organization of your library and am going to try the SPI example first. Then I will solder the headers on for the 16P mode. I do not have a shield so I will have to wire them by hand with jumpers.

Thank you for your time.


BrettAshtonClinton

Hey buddy,

    I have now got your library to work in SPI mode and it runs through the RA8875 graphics test flawlessly. There is a lot of information in your library and I am a little confused about the defined pin layouts of the different display shields for 16P mode. I am not going to use a shield and instead am going to simply just jump the pins between the Arduino and the display. Can you give me a little guidance on how to go about setting the pins in the code for 16P mode instead of SPI mode? I am really excited to finally use 16P mode with this display.

Thank you so much!

david_prentice

BuyDisplay provide schematics and advice on connecting hardware.    Study them.

BuyDisplay also sells Adapter Shields.

If you connect jumpers from a 5V Arduino to the 3.3V display you will destroy it.    Not immediately but within hours.

There is little point in using 8080-16.   SPI works fine.   The RA8875 performs graphics faster tan any external MCU.

David.

BrettAshtonClinton

Hello David,

   The SPI works great, however, when using SPI on the board the RA8875 has a bug in which it will not play nice with the other connected SPI devices. This is why I wish to use the RA8875 in either 8-bit or 16-bit mode. I am running the display off a Due. I am studying his library pinouts and there are some extra pins that are not included in the BuyDisplay output. Perhaps they have different names for the pins. I am going to try and figure out the wiring for the BuyDisplay in correlation to his library.     

If you have any other suggestions for me please leave them, Brett!

ZinggJM

@BrettAshtonClinton

I used it with Arduino Due through a CTE adapter, see my_7_Waveshare_800x480_CTE_DUE.h

Jean-Marc
No personal message please; any question may be useful for other users. Use code tags for code. Make links clickable with URL tags. Provide links to the product in question.

david_prentice

Phew.   That is a relief.    The Due has 3.3V GPIO.   You can safely connect to the RA8875.

I would still stick with SPI.   You only need to put a 1k series resistor in the MISO line.    Hardly Rocket Science.

David.

anujgarg07

Hello,

I have been working on a project which requires 7inch touch screen driven by Arduino Mega. I have bought the same from buydisplay.com ( https://www.buydisplay.com/default/serial-spi-arduino-7-inch-tft-lcd-touch-shield-ra8875-for-mega-due-uno ).

I have plugged in the screen+shield+mega and uploaded the sample code and it worked fine. Thereafter I googled several different libraries and samples (mostly using Adafruit library) and all worked fine at a basic level.

However here is a problem which I want someone to please help me with. When I am trying to display a BMP (800x480) on the screen from the SD card it is taking around 20seconds to load a single image on the screen. As you can see this much speed is of no good for any practical application.

I am using example code at ( https://github.com/adafruit/Adafruit_RA8875/tree/master/examples/ra8875_bitmap )

So my question is that if RS8875 is the bottle neck or SPI is the bottle neck? Because if RA8875 is the bottle neck then I have to look at other options. But if SPI is the bottle neck then will Parallel interface increase the speed? And if yes then anyone have a basic library?

david_prentice

The RA8875 is  blisteringly fast with graphics and text.    Not so good if you are plotting one pixel at a time.

Your display has a microSD socket.    The RA8875 can access this at full speed but as a "big Flash Memory" rather than a disk with filing system.

If you use the microSD on the Adapter shield it can use regular SD.h file system.    You process with the AVR.   Then send the result to the RA8875 via SPI.

Typed from distant memory.   I have not looked at ra8875_bitmap

David.

anujgarg07

Thanks David,
Will try this and report the results.

Go Up