Go Down

Topic: Problem with connector between Arduino and MS SQL Server (Read 847 times) previous topic - next topic

PaulS

Quote
I got many errors, I've posted them before. (see my post # 2)
Post #2 is not yours. Post #3 is, but that code contains a whole sh*tload of #include statements.

I want to see the code, and the compiler errors, where your added #include statements include ONLY UIPEthernet.h.
The art of getting good answers lies in asking good questions.

fernando1828

OK, I get (some of them):

Quote
n file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:33:0,
                 from C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:13,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPClient.h:25:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
 #import "Client.h"
  ^
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPClient.h:26:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
 #import "utility/mempool.h"
  ^
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPClient.h:29:4: warning: #import is a deprecated GCC extension [-Wdeprecated]
   #import "utility/uip.h"
    ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:34:0,
                 from C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:13,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPServer.h:23:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
 #import "Server.h"
  ^
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPServer.h:24:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
 #import "UIPClient.h"
  ^
In file included from sqlard_test.ino:2:0:
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:97:31: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11 [enabled by default]
  SQLardRowElement<T> * prev = nullptr;
                               ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:97:31: error: 'nullptr' was not declared in this scope
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:157:31: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11 [enabled by default]
  SQLardRowElement<T> * root = nullptr;
                               ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:159:31: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11 [enabled by default]
  SQLardRowElement<T> * head = nullptr;
                               ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:160:35: warning: non-static data member initializers only available with -std=c++11 or -std=gnu++11 [enabled by default]
  SQLardRowElement<T>  * current = nullptr;
                                   ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:157:31: error: 'nullptr' was not declared in this scope
  SQLardRowElement<T> * root = nullptr;
                               ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:159:31: error: 'nullptr' was not declared in this scope
  SQLardRowElement<T> * head = nullptr;
                               ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:160:35: error: 'nullptr' was not declared in this scope
  SQLardRowElement<T>  * current = nullptr;
                                   ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h: In member function 'void SQLardRowList<T>::Free()':
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:120:18: error: 'nullptr' was not declared in this scope
   while (node != nullptr)
                  ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h: In member function 'void SQLardRowList<T>::Enqueue(T)':
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:138:15: error: 'nullptr' was not declared in this scope
   if (root == nullptr)
               ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h: In member function 'void SQLardRowList<T>::MoveNext()':
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:147:18: error: 'nullptr' was not declared in this scope
   if (current != nullptr)
                  ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h: In member function 'bool SQLardRowList<T>::isEmpty()':
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:154:34: error: 'nullptr' was not declared in this scope
  bool isEmpty() { return root == nullptr; }
                                  ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h: In static member function 'static size_t SQLardUtil::sqlard_wcslen(const wchar_t*)':
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:314:12: error: 'nullptr' was not declared in this scope
   if (s == nullptr)
            ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h: In static member function 'static wchar_t* SQLardUtil::sqlard_wmemcpy(void*, const wchar_t*, size_t)':
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:329:12: error: 'nullptr' was not declared in this scope
   if (s == nullptr || d == nullptr)
            ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h: In static member function 'static SQLardColumnData* SQLardColumnData::ParseColumnData(uint8_t*, size_t&)':
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:460:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::BITTYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:461:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::INT1TYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:462:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::INT2TYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:463:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::INT4TYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:464:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::INT8TYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:465:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::DATETIMETYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:466:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::FLT4TYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:467:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::FLT8TYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:469:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::DECIMALNTYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:470:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::NUMERICNTYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:480:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::IMAGETYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:481:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::NTEXTTYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:482:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::TEXTTYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:490:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::BIGVARBINTYPE:
         ^
C:\Users\Fer\Documents\Arduino\libraries\arduino-mssql-master/sqlard.h:491:9: error: 'SQLardDataType' is not a class or namespace
    case SQLardDataType::BIGVARCHRTYPE:
         ^
           ^
Error de compilación


PaulS

Quote
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPClient.h:25:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
 #import "Client.h"
  ^
Why don't you start by fixing this way-outdated library to use #include, instead of #import?

The art of getting good answers lies in asking good questions.

fernando1828

Ok, now i get:

Quote
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:4:18: error: conflicting declaration 'EthernetClass UIPEthernet'
 #define Ethernet UIPEthernet
                  ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:81:22: note: in expansion of macro 'Ethernet'
 extern EthernetClass Ethernet;
                      ^
In file included from sqlard_test.ino:2:0:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:125:25: error: 'UIPEthernet' has a previous declaration as 'UIPEthernetClass UIPEthernet'
 extern UIPEthernetClass UIPEthernet;
                         ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:7:21: error: redefinition of 'class UIPUDP'
 #define EthernetUDP UIPUDP
                     ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:86:7: note: in expansion of macro 'EthernetUDP'
 class EthernetUDP : public UDP {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/Dhcp.h:7:0,
                 from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:30,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPUdp.h:43:7: error: previous definition of 'class UIPUDP'
 class UIPUDP : public UDP
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:5:24: error: redefinition of 'class UIPClient'
 #define EthernetClient UIPClient
                        ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:147:7: note: in expansion of macro 'EthernetClient'
 class EthernetClient : public Client {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:33:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPClient.h:63:7: error: previous definition of 'class UIPClient'
 class UIPClient : public Client {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:6:24: error: redefinition of 'class UIPServer'
 #define EthernetServer UIPServer
                        ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:180:7: note: in expansion of macro 'EthernetServer'
 class EthernetServer : public Server {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:34:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPServer.h:26:7: error: previous definition of 'class UIPServer'
 class UIPServer : public Server {
       ^
In file included from sqlard_test.ino:4:0:
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:197:7: error: redefinition of 'class DhcpClass'
 class DhcpClass {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:30:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/Dhcp.h:139:7: error: previous definition of 'class DhcpClass'
 class DhcpClass {
       ^
Multiple libraries were found for "Ethernet.h"
 Used: C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet
 Not used: C:\Program Files (x86)\Arduino\libraries\Ethernet
Error de compilación


PaulS

Quote
Used: C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet
 Not used: C:\Program Files (x86)\Arduino\libraries\Ethernet
MightyCore? It's time you told us what board you are compiling for.
The art of getting good answers lies in asking good questions.

fernando1828

Oh I made a mistake, I was working on another project. Anyway, choosing arduino UNO I get errors.

PaulS

Quote
Anyway, choosing arduino UNO I get errors.
Feel free to share them with us. Or not.
The art of getting good answers lies in asking good questions.

fernando1828

Quote
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:4:18: error: conflicting declaration 'EthernetClass UIPEthernet'
 #define Ethernet UIPEthernet
                  ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:81:22: note: in expansion of macro 'Ethernet'
 extern EthernetClass Ethernet;
                      ^
In file included from sqlard_test.ino:2:0:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:125:25: error: 'UIPEthernet' has a previous declaration as 'UIPEthernetClass UIPEthernet'
 extern UIPEthernetClass UIPEthernet;
                         ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:7:21: error: redefinition of 'class UIPUDP'
 #define EthernetUDP UIPUDP
                     ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:86:7: note: in expansion of macro 'EthernetUDP'
 class EthernetUDP : public UDP {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/Dhcp.h:7:0,
                 from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:30,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPUdp.h:43:7: error: previous definition of 'class UIPUDP'
 class UIPUDP : public UDP
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:5:24: error: redefinition of 'class UIPClient'
 #define EthernetClient UIPClient
                        ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:147:7: note: in expansion of macro 'EthernetClient'
 class EthernetClient : public Client {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:33:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPClient.h:63:7: error: previous definition of 'class UIPClient'
 class UIPClient : public Client {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:28:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/ethernet_comp.h:6:24: error: redefinition of 'class UIPServer'
 #define EthernetServer UIPServer
                        ^
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:180:7: note: in expansion of macro 'EthernetServer'
 class EthernetServer : public Server {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:34:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPServer.h:26:7: error: previous definition of 'class UIPServer'
 class UIPServer : public Server {
       ^
In file included from sqlard_test.ino:4:0:
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet\src/Ethernet.h:197:7: error: redefinition of 'class DhcpClass'
 class DhcpClass {
       ^
In file included from C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/UIPEthernet.h:30:0,
                 from sqlard_test.ino:2:
C:\Users\Fer\Documents\Arduino\libraries\arduino_uip-master/Dhcp.h:139:7: error: previous definition of 'class DhcpClass'
 class DhcpClass {
       ^
Multiple libraries were found for "Ethernet.h"
 Used: C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\hardware\avr\2.0.0\libraries\Ethernet
 Not used: C:\Program Files (x86)\Arduino\libraries\Ethernet
Error de compilación

PaulS

Quote
C:\Users\Fer\AppData\Roaming\Arduino15\packages\MightyCore\
Still with the unexplained MightyCore...
The art of getting good answers lies in asking good questions.

fernando1828

Maybe I have a problem with the Mighty core library, later I will uninstall it. Anyway I am trying to connect the arduino with a c# program.

Thanks!!!!

PaulS

Quote
Anyway I am trying to connect the arduino
Which Arduino?
The art of getting good answers lies in asking good questions.

fernando1828


Go Up