Newhaven Products > Evaluation Tools

NHD-4.3CTP-Shield -- Hello world example compilation fails

(1/3) > >>

Tim_Cole:
Greeting folks
It looks like I've fixed my library installation finger trouble, which has moved me ahead to another problem. I've started with the venerable "Hello, world" example. Compiling produces the following errors, copied from the IDE with the "Copy error messages" button.

Help!

----


Arduino: 1.6.12 (Windows 10), Board: "Arduino/Genuino Uno"

WARNING: Category '' in library OneWire is not valid. Setting to 'Uncategorized'
In file included from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/FT_NHD_43CTP_SHIELD.h:67:0,

                 from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801\examples\FT_NHD_43CTP_SHIELD\Basic\HelloWorld\HelloWorld.ino:30:

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_Transport_SPI/FT_Transport_SPI.h:215:37: error: 'prog_uchar' has not been declared

  void Writefromflash(uint32_t Addr, prog_uchar *Src, uint32_t NBytes)

                                     ^

In file included from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/FT_NHD_43CTP_SHIELD.h:68:0,

                 from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801\examples\FT_NHD_43CTP_SHIELD\Basic\HelloWorld\HelloWorld.ino:30:

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:330:32: error: 'prog_uchar' has not been declared

  FT_GEStatus WriteCmdfromflash(prog_uchar *Src,uint32_t NBytes);

                                ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:334:35: error: 'prog_uchar' has not been declared

  FT_GEStatus TransferCmdfromflash(prog_uchar *Src,uint32_t NBytes);

                                   ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:372:71: error: redeclaration of 'FT_Status FT_GC<FT_Trans>::Init(uint8_t, uint16_t)' may not have default arguments [-fpermissive]

 FT_Status FT_GC<FT_Trans>::Init(uint8_t ResType, uint16_t options1 = 0)

                                                                       ^

In file included from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/FT_NHD_43CTP_SHIELD.h:68:0,

                 from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801\examples\FT_NHD_43CTP_SHIELD\Basic\HelloWorld\HelloWorld.ino:30:

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:410:258: error: redeclaration of 'FT_Status FT_GC<FT_Trans>::Init(uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint8_t, uint8_t, uint8_t, uint16_t)' may not have default arguments [-fpermissive]

 FT_Status FT_GC<FT_Trans>::Init(uint16_t hperiod,uint16_t vperiod,uint16_t hfrontporch,uint16_t hbackporch,uint16_t hpulsewidth,uint16_t vfrontporch,uint16_t vbackporch,uint16_t vpulsewidth,uint8_t polarity,uint8_t swizzle,uint8_t fps, uint16_t options1 = 0)

                                                                                                                                                                                                                                                                  ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1670:52: error: 'FT_GEStatus FT_GC<FT_Trans>::TransferCmdfromflash' is not a static member of 'class FT_GC<FT_Trans>'

 FT_GEStatus FT_GC<FT_Trans>::TransferCmdfromflash( prog_uchar *Src,uint32_t NBytes)

                                                    ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1670:52: error: template definition of non-template 'FT_GEStatus FT_GC<FT_Trans>::TransferCmdfromflash'

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1670:52: error: 'prog_uchar' was not declared in this scope

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1670:64: error: 'Src' was not declared in this scope

 FT_GEStatus FT_GC<FT_Trans>::TransferCmdfromflash( prog_uchar *Src,uint32_t NBytes)

                                                                ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1670:77: error: expected primary-expression before 'NBytes'

 FT_GEStatus FT_GC<FT_Trans>::TransferCmdfromflash( prog_uchar *Src,uint32_t NBytes)

                                                                             ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1780:49: error: 'FT_GEStatus FT_GC<FT_Trans>::WriteCmdfromflash' is not a static member of 'class FT_GC<FT_Trans>'

 FT_GEStatus FT_GC<FT_Trans>::WriteCmdfromflash( prog_uchar *Src,uint32_t NBytes)

                                                 ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1780:49: error: template definition of non-template 'FT_GEStatus FT_GC<FT_Trans>::WriteCmdfromflash'

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1780:49: error: 'prog_uchar' was not declared in this scope

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1780:61: error: 'Src' was not declared in this scope

 FT_GEStatus FT_GC<FT_Trans>::WriteCmdfromflash( prog_uchar *Src,uint32_t NBytes)

                                                             ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT_GC.h:1780:74: error: expected primary-expression before 'NBytes'

 FT_GEStatus FT_GC<FT_Trans>::WriteCmdfromflash( prog_uchar *Src,uint32_t NBytes)

                                                                          ^

In file included from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/FT_NHD_43CTP_SHIELD.h:69:0,

                 from C:\Program Files (x86)\Arduino\libraries\FTDI_FT801\examples\FT_NHD_43CTP_SHIELD\Basic\HelloWorld\HelloWorld.ino:30:

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT801/FT801Impl.h:124:73: error: redeclaration of 'FT_Status FT801Impl<FT_Trans>::Init(uint8_t, uint16_t)' may not have default arguments [-fpermissive]

 FT_Status FT801Impl<FT_Trans>::Init(uint8_t ResType, uint16_t options1=0)

                                                                         ^

C:\Program Files (x86)\Arduino\libraries\FTDI_FT801/libraries/FT_GC/FT801/FT801Impl.h:133:71: error: redeclaration of 'FT_Status FT801Impl<FT_Trans>::Init(uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint16_t, uint8_t, uint8_t, uint8_t, uint16_t)' may not have default arguments [-fpermissive]

       uint8_t polarity,uint8_t swizzle,uint8_t fps,uint16_t options1=0)     

                                                                       ^

exit status 1
Error compiling for board Arduino/Genuino Uno.

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Paul_B:
Morning Tim,

Can you please try installing version 1.0.6 of the Arduino IDE?

https://www.arduino.cc/en/Main/OldSoftwareReleases

It appears there was a change in the syntax, I'll look into this change further and provide a fix.

Tim_Cole:
I'll give it it a shot on a laptop I don't normally use for programming. Call me paranoid, but I don't want to muck up my existing setup.

Tim_Cole:
Okay, I just installed the Arduino 1.0.6 IDE on my laptop, installed the FTDI 800/801 library and compiled the HelloWorld example. That worked properly. So, something got broken between 1.0.6 and 1.6.12.

Paul_B:
Glad to hear you are up and running! The library was originally written with the old IDE, and since then the avr-gcc compiler has changed and certain keywords/datatypes give errors in the new Arduino IDE’s.

Navigation

[0] Message Index

[#] Next page

Go to full version