 void readData() {
 
   while (conn.available()) {
-    Serial.println(F("Received message"));
+    Serial.println(F("!!!RECEIVED MESSAGE!!!!"));
     Serial.flush();
 
     if(pseudopod.readMessage() == TentacleMessageTopic_action) {

void setup() {
  Serial.begin(9600);
  Serial.println(F("The Day of the Tentacle has begun!"));
  debugPhoton();
  connectToServer();
}

void loop() {
  if (!conn.connected()) {
    conn.stop();
    connectToServer();
  }
  Serial.println(F("In loop."));
  Serial.flush();
  delay(2000);
  readData();

  if(pseudopod.shouldBroadcastPins() ) {
    delay(pseudopod.getBroadcastInterval());

// This #include statement was automatically added by the Spark IDE.
#include "tentacle-particle.h"

#define server "tentacle.octoblu.com"
#define port 80


IPAddress localServer(192, 168, 0, 104);
#define localPort 8111

static const char uuid[]  = "ff12c403-04c7-4e63-9073-2e3b1f8e4450";
static const char token[] = "28d2c24dfa0a5289799a345e683d570880a3bc41";

TCPClient conn;

bool hasConnectedToServer = false;
bool hasAuthenticated = false;

TentacleArduino tentacle;
Pseudopod pseudopod(conn, conn, tentacle);
