Alexa is not connecting to IOT cloud

I wrote this script. It works just fine in the IOT cloud dashboard. But when I use it with an Alexa, Alexa couldn't find a new device to connect. I don't know how to fix it.

#include "thingProperties.h" // Include the thingProperties.h file

void setup() {
  // Initialize serial communication
  Serial.begin(9600);

  // Initialize the cloud properties
  initProperties();

  // Connect to Arduino IoT Cloud
  ArduinoCloud.begin(ArduinoIoTPreferredConnection);

  // Set pin 3 as an output
  pinMode(13, OUTPUT);

  // Give some time for Serial Monitor to start
  delay(1500);
}

void loop() {
  ArduinoCloud.update(); // Keep the connection to the Arduino IoT Cloud active
}

// This function will be called every time the variable 'light' changes its value
void onLightChange() {
  if (light) {
    digitalWrite(13, HIGH);  // Turn the light on
  } else {
    digitalWrite(13, LOW);   // Turn the light off
  }
}

It might be because I am using two bands of internet and my Arduino and My phone is connected to the 2ghz one but all the Alexas are using 5g? I dont know.

Hi! Which property type did you used for 'light' variable?
Did you selected 'Alexa light'?
Screenshot 2024-08-19 085504
And then, remember to select 'Alexa' in smart home integration
Screenshot 2024-08-19 085558
Cheers

1 Like

no, thanks!

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.