help with instructables arduinophone

Hello kind sir and/or madam. I am trying to create a cell phone arduino according to the code and design found on instructables.com: https://www.instructables.com/id/ArduinoPhone/ however, I am having trouble with the code itself. I have downloaded all the libraries (I think) and am now getting an error message basically stating that many variables were not declared in this scope, multiple libraries found, etc ending with

exit status 1
Error compiling for board Arduino/Genuino Mega or Mega 2560.

(I could not post the full error code here due to it being over 9000 characters)

Any help would be greatly appreciated.
Thank you,
Manbat0213

code.txt (18 KB)

error message.txt (19.2 KB)

That error message on its own tells us nothing.

Please place in text file and attach to post.

Thank you for the suggestion. I have done so.

I think you need to add these lines in your setup:

   TFT_BL_ON;      // turn on the background light
   Tft.TFTinit();  // init TFT library

and maybe

#include <stdint.h>

as the first line of your code

I tried adding those in the setup and 1st line (as stated) but it still returns the same error code. Is there anything else I should try?

It may come from the way you installed the libraries. In the zip file from here, there is a folder called 'Libraries', containing 5 folders. these 5 folders should be placed in the arduino/libraries folder on your computer.

Did you do this that way?

Actually, the code is provided as a sketchbook, and some information about sketchbooks is provided here. It's the first time I see this, so maybe what I suggested right before is wrong. Read the information about sketchbook and apply it.

Your error message is typical of a library problem (the IDE can't find the library files for example). The only thing I can think of is the name of the libray folder : Libraries (cap L) instead of libraries (small l). Maybe you can try to change the capital to a small 'l'... ?

So what you said worked, but now I am having another problem. I uploaded the code, but it just shows a blank screen. Do you have any ideas as to why?

The code is quite complex, so I don't know where it comes from.
When you say 'blank' do you mean 'empty' or 'white'?

When you use it, is it connected to your computer? If yes, you can use the serial monitor to debug.

Add

Serial.begin(115200);

in the setup, and change these lines (in the stateMachine function)

void stateMachine()
{
    switch(UI.state)
    {
        //***************************************main page*************************
        case ST_TIME:

        Tft.fillScreen();
        UI.getTime();
        UI.drawTimeDate(25, 90);
        UI.showMainPage();
        time1 = millis();

to

void stateMachine()
{
    Serial.print("UI.state = "); Serial.println(UI.state);
    switch(UI.state)
    {
        //***************************************main page*************************
        case ST_TIME:
        Serial.print("ST_TIME");
        Tft.fillScreen(); Serial.print("After fillscreen");
        UI.getTime(); Serial.print("After getTime");
        UI.drawTimeDate(25, 90); Serial.print("After drawTimeDate");
        UI.showMainPage(); Serial.print("After showMainPage");
        time1 = millis();

And after each 'case' line, add the corresponding Serial.println, for example :

case ST_CALLING:
Serial.println("ST_CALLING");

This way you can track the execution of the code.

Normally, if I understand well (but the code is complex), the TFT should display the time and date inside a rectangle. Maybe that text is written in the same color as the background

So you can try to change
Tft.fillScreen();
to
Tft.fillScreen(0, 239, 0, 319, BLUE); to see if you get a blue screen and see the text.

It says the problem is "Read TFT ID failed, ID should be 0x09341, but read ID = 0x000"

Do you know what this means

Hello kind sir and/or madam. I am trying to make a cell phone via this tutorial: https://www.instructables.com/id/ArduinoPhone/ My problem is, no matter what, I get a white screen. I have looked up tutorials, but none of them seem to work.
My code and error messages are attached as text files.

Before this, I went to the serial monitor and got: Read TFT ID failed, ID should be 0x09341, but read ID = 0x000

Any help would be greatly appreciated.

Thanks,
Manbat0213

arduinocode.txt (18.5 KB)

error.txt (2.3 KB)

It comes from the call of the function Tft.TFTinit();
At the address 0xd3 of the registers of the display, the value should be 0x09341 and you have 0x0000, I don't know why it is not such.

This is beyond my knowledge. Maybe you should post in the displays section of the forum, some of the people there are very good!

One last idea.
You said you did what I suggested and the errors disapeared: do you mean what I suggested concerning the sketchbook? If yes, try again with your original program (so without the lines I told you to add). Maybe the problem came only from that sketchbook thing and what I told you before created the new problem...

I have no experience with that Instructables project but I think you would be more likely to attract help if you modify your Original Post and change your title to "Help with Instructables ArduinoPhone"

...R

I deleted this topic's twin