Can´t conect my Arduino UNO+Ethernet W5100 to Cayenne. Waiting for Response


#1
  • Device & model: ARDUINO UNO + Ethernet W5100

  • What dashboard are you using? Trying to connect my Arduino to the Cayenne Cloud using the Web.

I have connection to the internet, I have already run a WebChecker Sketch on the Arduino and a Ping to www.google.com got success.

I am also able to run a webserver in local and light a Led by a web page.

What I cannot is to connect my arduino to Cayenne.

I am using the “Manual Sketch” were I have put the MAC and the IP properly, I reckon.

There is a WAINTING all the time lighting in the screen.

I have checked the Serial Monitor and it is blank all the time. So info on it.

Has someone the same problem??

Thank you very much :smiley:

#include <SPI.h>
#include <Ethernet.h>
//#define CAYENNE_DEBUG // Uncomment to show debug messages
#define CAYENNE_PRINT Serial // Comment this out to disable prints and save space
#include <CayenneEthernet.h> // Comment this out if you uncomment a different Ethernet device below.
//#include <CayenneEthernetW5500.h> // Uncomment this and comment out CayenneEthernet.h to use an Ethernet 2 shield or other Ethernet W5500 shield.
_ // You will need the Ethernet2 library installed. See the ArduinoEthernetW5500 example sketch for more info._
//#include <CayenneEthernetW5200.h> // Uncomment this and comment out CayenneEthernet.h to use an Ethernet W5200 shield.
_ // You will need the EthernetW5200 library installed. See the ArduinoEthernetW5200 example sketch for more info._

// Cayenne authentication token. This should be obtained from the Cayenne Dashboard.
char token[] = “200fc1hyjs”;

// Mac address should be different for each device in your LAN
byte arduino_mac[] = {0x00, 0xAA, 0xBB, 0xCC, 0xDE, 0x02};
IPAddress arduino_ip(10, 123, 24, 240);
IPAddress dns_ip(10, 123, 24, 252);
IPAddress gateway_ip(10, 123, 24, 252);
IPAddress subnet_mask(255, 255, 255, 0);

void setup()
{
_ Serial.begin(9600);_
_ Cayenne.begin(token, arduino_ip, dns_ip, gateway_ip, subnet_mask, arduino_mac);_
}

void loop()
{
_ Cayenne.run();_
}


#2

Just want to double check with you, are the _'s part of the sketch, or a copy/paste error?


#3

They are copy/paste errors. I had no problem compiling the sketch.

Ill try to copy/paste the code properly.

#include spi.h
#include ethernet.h


char token[] = "200fc1hyjs";

byte arduinomac[] = {....................................};
IPAddress arduinoip(.........................);
IPAddress dnsip(..................);
IPAddress gatewayip(..........................);
IPAddress subnetmask(.................);

void setup()
{
	Serial.begin(9600);
	Cayenne.begin(token, arduino_ip, dns_ip, gateway_ip, subnet_mask, arduino_mac);
}

void loop()
{
	Cayenne.run();
}