Errors while compiling

For general Flowcode discussion that does not belong in the other sections.
ctesla75
Posts: 23
http://meble-kuchenne.info.pl
Joined: Tue Nov 22, 2022 10:56 am
Been thanked: 2 times

Errors while compiling

Post by ctesla75 »

Hi All,
After some issues getting an esp32 to compile to target it is now working, but my main program that works during debug displays no LCD. So i am trying to start slow. First flash an led next "hello" on LCD. The led flashes, But the compiler still brings up a lot of errors.

Code: Select all

In file included from C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:110,
                 from C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\internals.c:568,
                 from ../main/esp-project.c:48:
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_Float.c:91:6: warning: conflicting types for built-in function '__builtin_isinf_sign' [-Wbuiltin-declaration-mismatch]
 char isinf(float f)
      ^~~~~
In file included from C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\internals.c:568,
                 from ../main/esp-project.c:48:
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:876:13: warning: 'FCI_SCOPY' defined but not used [-Wunused-function]
 static void FCI_SCOPY(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_STRING sDst, MX_UINT16 iDst_len)
             ^~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:815:13: warning: 'FCI_SHEAD' defined but not used [-Wunused-function]
 static void FCI_SHEAD(MX_STRING sSrc1, MX_UINT16 iSrc1_len, MX_STRING sSrc2, MX_UINT16 iSrc2_len, MX_STRING sDst, MX_UINT16 iDst_len)
             ^~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:795:18: warning: 'FCI_STRMOV' defined but not used [-Wunused-function]
 static MX_UINT16 FCI_STRMOV(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_STRING sDst, MX_UINT16 iDst_len)
                  ^~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:771:18: warning: 'FCI_STRREV' defined but not used [-Wunused-function]
 static MX_UINT16 FCI_STRREV(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_STRING sDst, MX_UINT16 iDst_len)
                  ^~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:701:17: warning: 'FCI_STRING_TO_FLOAT' defined but not used [-Wunused-function]
 static MX_FLOAT FCI_STRING_TO_FLOAT(MX_STRING String, MX_UINT16 MSZ_String)
                 ^~~~~~~~~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:598:18: warning: 'FCI_NUMBER_TO_HEX' defined but not used [-Wunused-function]
 static MX_STRING FCI_NUMBER_TO_HEX(MX_ULONG Number, MX_STRING String, MX_UINT16 MSZ_String)
                  ^~~~~~~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:531:18: warning: 'FCI_FLOAT_TO_STRING' defined but not used [-Wunused-function]
 static MX_STRING FCI_FLOAT_TO_STRING(MX_FLOAT Number, MX_UINT8 Precision, MX_STRING String, MX_UINT16 MSZ_String)
                  ^~~~~~~~~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:476:17: warning: 'FCI_COMPARE' defined but not used [-Wunused-function]
 static MX_UINT8 FCI_COMPARE(MX_STRING sSrc1, MX_UINT16 iSrc1_len, MX_STRING sSrc2, MX_UINT16 iSrc2_len, MX_UINT8 iNoCase)
                 ^~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:450:13: warning: 'FCI_TOUPPER' defined but not used [-Wunused-function]
 static void FCI_TOUPPER(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_STRING sDst, MX_UINT16 iDst_len)
             ^~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:424:13: warning: 'FCI_TOLOWER' defined but not used [-Wunused-function]
 static void FCI_TOLOWER(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_STRING sDst, MX_UINT16 iDst_len)
             ^~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:331:10: warning: 'FCI_TOSTRU32' defined but not used [-Wunused-function]
 MX_UINT8 FCI_TOSTRU32(MX_UINT32 iSrc1, MX_STRING sDst, MX_UINT16 iDst_len)
          ^~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:297:10: warning: 'FCI_TOSTRU16' defined but not used [-Wunused-function]
 MX_UINT8 FCI_TOSTRU16(MX_UINT16 iSrc1, MX_STRING sDst, MX_UINT16 iDst_len)
          ^~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:254:10: warning: 'FCI_TOSTRS32' defined but not used [-Wunused-function]
 MX_UINT8 FCI_TOSTRS32(MX_SINT32 iSrc1, MX_STRING sDst, MX_UINT16 iDst_len)
          ^~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:211:10: warning: 'FCI_TOSTRS16' defined but not used [-Wunused-function]
 MX_UINT8 FCI_TOSTRS16(MX_SINT16 iSrc1, MX_STRING sDst, MX_UINT16 iDst_len)
          ^~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:182:18: warning: 'FCI_RIGHTSTRING' defined but not used [-Wunused-function]
 static MX_STRING FCI_RIGHTSTRING(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_UINT16 iCount, MX_STRING sDst, MX_UINT16 iDst_len)
                  ^~~~~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:159:18: warning: 'FCI_LEFTSTRING' defined but not used [-Wunused-function]
 static MX_STRING FCI_LEFTSTRING(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_UINT16 iCount, MX_STRING sDst, MX_UINT16 iDst_len)
                  ^~~~~~~~~~~~~~
In file included from C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\internals.c:568,
                 from ../main/esp-project.c:48:
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:129:18: warning: 'FCI_MIDSTRING' defined but not used [-Wunused-function]
 static MX_STRING FCI_MIDSTRING(MX_STRING sSrc, MX_UINT16 iSrc_len, MX_UINT16 iStart, MX_UINT16 iCount, MX_STRING sDst, MX_UINT16 iDst_len)
                  ^~~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:121:18: warning: 'FCI_GETLENGTH' defined but not used [-Wunused-function]
 static MX_UINT16 FCI_GETLENGTH(MX_STRING sStr1, MX_UINT16 iStr1_len)
                  ^~~~~~~~~~~~~
C:\ProgramData\MatrixTSL\FlowcodeV9\CAL\ESP\ESP_CAL_String.c:113:17: warning: 'FCI_GETCHAR' defined but not used [-Wunused-function]
 static MX_UINT8 FCI_GETCHAR(MX_STRING sStr1, MX_UINT16 iStr1_len, MX_UINT16 iPos)
                 ^~~~~~~~~~~
[4/7] Linking CXX static library esp-idf\main\libmain.a
I am not sure if this is why the lcd didnt work but why are these errors coming up, the LED flashes

BenR
Matrix Staff
Posts: 1926
Joined: Mon Dec 07, 2020 10:06 am
Has thanked: 503 times
Been thanked: 686 times

Re: Errors while compiling

Post by BenR »

Hello,

I beleive those warnings look normal. Can you attach your project file so we can have a look at your program.

ctesla75
Posts: 23
Joined: Tue Nov 22, 2022 10:56 am
Been thanked: 2 times

Re: Errors while compiling

Post by ctesla75 »

Hi Ben , Thanks for looking at the errors. I have tried using different LCD's and different pinouts with no luck. I am only trying to get text on an lcd .
I am now wondering whether my esp32 is faulty. IT is a ESP32-wroom-32. There were no errors during compiling
Attachments
lcd test.fcfx
(7.34 KiB) Downloaded 291 times

mnfisher
Valued Contributor
Posts: 1470
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 136 times
Been thanked: 706 times

Re: Errors while compiling

Post by mnfisher »

You are calling 'Start' repeatedly - move that to before the loop - it just needs to be called once..

Also add a delay to the loop (say 500ms) - the LED on the esp32 is flashing because the watchdog timer is causing an error. (Or add a loop with a delay after printing something to the display - as in this case it is just 'static' text)

Martin

ctesla75
Posts: 23
Joined: Tue Nov 22, 2022 10:56 am
Been thanked: 2 times

Re: Errors while compiling

Post by ctesla75 »

I have made changes as suggested but still no output, i will try a few different lcds tommorow, they are hd44780 LCD's as far as i know. They are second hand , taken from faulty equipment with working LCD'S
Attachments
lcd test.fcfx
(7.51 KiB) Downloaded 213 times

chipfryer27
Valued Contributor
Posts: 1533
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 352 times
Been thanked: 550 times

Re: Errors while compiling

Post by chipfryer27 »

Hi

You don't really need your loop at all just to display a single line for testing. You could just Start the display then print "Hello".

You might want to include a delay of say 50mS after the Start command as I think some older displays needed such. Also, have you set the contrast level and R/W pin?

The WiKi will provide generic connections (right click component then select Help) for these displays.

Regards

medelec35
Matrix Staff
Posts: 1934
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 622 times
Been thanked: 648 times

Re: Errors while compiling

Post by medelec35 »

Just make sure your R/W is connected to GND and the pot is wired correctly.
A general rule is:
If you can only see a top row of squares, then there is a connection issue (including R/W not connected to GND) or LCD start has not been used.
If there is more than one row of black squares, then the contrast i.e pot settings are the issue.
If nothing at all can be seen, then software or the contrast (pot settings) could be the issue.
Martin

ctesla75
Posts: 23
Joined: Tue Nov 22, 2022 10:56 am
Been thanked: 2 times

Re: Errors while compiling

Post by ctesla75 »

Thanks for the replies.
I have updated the code and removed the loop, I also added a delay ,set r/w to ground and fixed the contrast.
But still no luck. I get one line of blocks the contrast seems to work fading it in and out but no characters. I tried using the first 4 bits db0 - db then db4 - db7. but still nothing. the lcd is a tc1602a-09t and i looked up the datasheet. so think its wired up right\
Attachments
lcd test.fcfx
(7.29 KiB) Downloaded 240 times

chipfryer27
Valued Contributor
Posts: 1533
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 352 times
Been thanked: 550 times

Re: Errors while compiling

Post by chipfryer27 »

Hi

Sounds like you are getting close.

The generic 16x2 component uses the "4-bit" interface and uses the upper bits (D4-D7) which are pins 11-14 on the display.

A quick search on the web suggests that the chip is a clone of the Hitachi chip but I see that some people have seen some timing issues.

Regards

ctesla75
Posts: 23
Joined: Tue Nov 22, 2022 10:56 am
Been thanked: 2 times

Re: Errors while compiling

Post by ctesla75 »

Hi
Have been away from project ,just got back to trying again. I have put a usb logic analyser on the 4 bit interface , but data is only coming out of two pins. I have also put the print string comand back in a loop

Post Reply