Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/arduino/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Esp8266-01阿杜伊诺乌诺。Firebase的状态_Firebase_Arduino_Esp8266_Arduino Uno_Arduino Esp8266 - Fatal编程技术网

Esp8266-01阿杜伊诺乌诺。Firebase的状态

Esp8266-01阿杜伊诺乌诺。Firebase的状态,firebase,arduino,esp8266,arduino-uno,arduino-esp8266,Firebase,Arduino,Esp8266,Arduino Uno,Arduino Esp8266,我无法将我的Esp8266-01连接到我的Arduino Uno。我希望能够将其连接起来,以便它能够将以下微动开关代码发送到Firebase(+LLC)。我没有从串行监视器中的AT命令得到任何响应,并且尝试了NL和CR以及从9600更改为115200波特率。我的esp只显示红色led,而不是蓝色led int pressSwitch = 0; void setup() // put your setup code here, to run once: { Serial.begin(9600)

我无法将我的Esp8266-01连接到我的Arduino Uno。我希望能够将其连接起来,以便它能够将以下微动开关代码发送到Firebase(+LLC)。我没有从串行监视器中的AT命令得到任何响应,并且尝试了NL和CR以及从9600更改为115200波特率。我的esp只显示红色led,而不是蓝色led

int pressSwitch = 0;
void setup()
  // put your setup code here, to run once:
{
Serial.begin(9600);
}

void loop()
 // put your main code here, to run repeatedly:
{
pinMode(LEVER_SWITCH_PIN,INPUT);
pressSwitch = digitalRead(LEVER_SWITCH_PIN);
  if(pressSwitch == HIGH)
{
Serial.println("CLOSED");
delay(1000);
}

if(pressSwitch == LOW)
{
Serial.println("OPEN");
delay(1000);
}
}```

您的代码无法与ESP-01通信,为此,您需要与ESP-01建立软件串行连接。您的Arduino如何与ESP-01进行物理连接?请注意,Arduino是5V MCU,而ESP-01是3V3 MCU,在Arduino Tx和ESP-01 Rx之间需要一个分压器。您的代码不与ESP-01通信,为此,您需要与ESP-01建立软件串行连接。您的Arduino如何与ESP-01进行物理连接?请注意,Arduino是5V MCU,ESP-01是3V3 MCU,您需要在Arduino Tx和ESP-01 Rx之间安装分压器。