12-21-2022, 04:32 PM
I am embarrassed to ask this and have flashed many ESP32s with far more complicated code but I am just trying to load one of the demo sketches provided by KinCony just to test my 868-A6.
I get this:
Connecting.....Traceback (most recent call last):
File "esptool.py", line 34, in <module>
File "esptool/__init__.py", line 1004, in _main
File "esptool/__init__.py", line 790, in main
File "esptool/loader.py", line 1108, in flash_set_parameters
File "esptool/loader.py", line 406, in check_command
File "esptool/loader.py", line 375, in command
File "esptool/loader.py", line 307, in read
StopIteration
[94734] Failed to execute script 'esptool' due to unhandled exception!
I am using "cu.usbserial 14620" drivers and they work with my ESP32's. Can anyone tell me what might be wrong?
The script is:
Blink led on PIN0
by Mischianti Renzo <http://www.mischianti.org>
I have a lot to learn
/*
Blink led on PIN0
by Mischianti Renzo <http://www.mischianti.org>
https://www.mischianti.org/2019/01/02/pc...asy-usage/
*/
#include "Arduino.h"
#include "PCF8574.h"
// Set i2c address
PCF8574 pcf8574(0x24,4,15);
void setup()
{
Serial.begin(115200);
//delay(1000);
// Set pinMode to OUTPUT
pcf8574.pinMode(P0, OUTPUT);
pcf8574.pinMode(P1, OUTPUT);
pcf8574.pinMode(P2, OUTPUT);
pcf8574.pinMode(P3, OUTPUT);
pcf8574.pinMode(P4, OUTPUT);
pcf8574.pinMode(P5, OUTPUT);
pcf8574.digitalWrite(P0, HIGH);
pcf8574.digitalWrite(P1, HIGH);
pcf8574.digitalWrite(P2, HIGH);
pcf8574.digitalWrite(P3, HIGH);
pcf8574.digitalWrite(P4, HIGH);
pcf8574.digitalWrite(P5, HIGH);
Serial.print("Init pcf8574...");
if (pcf8574.begin()){
Serial.println("OK");
}else{
Serial.println("KO");
}
}
void loop()
{
delay(300);
pcf8574.digitalWrite(P0, LOW);
delay(300);
pcf8574.digitalWrite(P1, LOW);
delay(300);
pcf8574.digitalWrite(P2, LOW);
delay(300);
pcf8574.digitalWrite(P3, LOW);
delay(300);
pcf8574.digitalWrite(P4, LOW);
delay(300);
pcf8574.digitalWrite(P5, LOW);
delay(300);
}
I get this:
Connecting.....Traceback (most recent call last):
File "esptool.py", line 34, in <module>
File "esptool/__init__.py", line 1004, in _main
File "esptool/__init__.py", line 790, in main
File "esptool/loader.py", line 1108, in flash_set_parameters
File "esptool/loader.py", line 406, in check_command
File "esptool/loader.py", line 375, in command
File "esptool/loader.py", line 307, in read
StopIteration
[94734] Failed to execute script 'esptool' due to unhandled exception!
I am using "cu.usbserial 14620" drivers and they work with my ESP32's. Can anyone tell me what might be wrong?
The script is:
Blink led on PIN0
by Mischianti Renzo <http://www.mischianti.org>
I have a lot to learn
/*
Blink led on PIN0
by Mischianti Renzo <http://www.mischianti.org>
https://www.mischianti.org/2019/01/02/pc...asy-usage/
*/
#include "Arduino.h"
#include "PCF8574.h"
// Set i2c address
PCF8574 pcf8574(0x24,4,15);
void setup()
{
Serial.begin(115200);
//delay(1000);
// Set pinMode to OUTPUT
pcf8574.pinMode(P0, OUTPUT);
pcf8574.pinMode(P1, OUTPUT);
pcf8574.pinMode(P2, OUTPUT);
pcf8574.pinMode(P3, OUTPUT);
pcf8574.pinMode(P4, OUTPUT);
pcf8574.pinMode(P5, OUTPUT);
pcf8574.digitalWrite(P0, HIGH);
pcf8574.digitalWrite(P1, HIGH);
pcf8574.digitalWrite(P2, HIGH);
pcf8574.digitalWrite(P3, HIGH);
pcf8574.digitalWrite(P4, HIGH);
pcf8574.digitalWrite(P5, HIGH);
Serial.print("Init pcf8574...");
if (pcf8574.begin()){
Serial.println("OK");
}else{
Serial.println("KO");
}
}
void loop()
{
delay(300);
pcf8574.digitalWrite(P0, LOW);
delay(300);
pcf8574.digitalWrite(P1, LOW);
delay(300);
pcf8574.digitalWrite(P2, LOW);
delay(300);
pcf8574.digitalWrite(P3, LOW);
delay(300);
pcf8574.digitalWrite(P4, LOW);
delay(300);
pcf8574.digitalWrite(P5, LOW);
delay(300);
}