rfquack/RFQuack

Unable to flash Evil Crow RF

RChadwick7 opened this issue · 11 comments

I was able to compile fine, but when I run:

sudo PORT=/dev/ttyUSB0 make flash

It looks like it's trying to flash the Evil Crow. Lights on it are blinking. Then, I get this: Any ideas what I'm doing wrong:?

docker run --rm -it --device=/dev/ttyUSB0:/board --env-file build.env rfquack/rfquack
Installation ID is 19b4a875-dbab-4d58-a017-58220b7a2dde
Processing ESP32 (platform: espressif32; board: esp32doit-devkit-v1; framework: arduino)

Tool Manager: Installing platformio/framework-arduinoespressif32 @ ~3.10006.0
Downloading [####################################] 100%
Unpacking [####################################] 100%
Tool Manager: framework-arduinoespressif32 @ 3.10006.210326 has been installed!
Tool Manager: Installing platformio/tool-mkspiffs @ ~2.230.0
Tool Manager: tool-mkspiffs @ 2.230.0 has been installed!
Tool Manager: Installing platformio/tool-scons @ ~4.40100.2
Downloading [####################################] 100%
Tool Manager: tool-scons @ 4.40100.2 has been installed!
Verbose mode can be enabled via -v, --verbose option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32doit-devkit-v1.html
PLATFORM: Espressif 32 (3.2.0) > DOIT ESP32 DEVKIT V1
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:

  • framework-arduinoespressif32 3.10006.210326 (1.0.6)
  • tool-esptoolpy 1.30000.201119 (3.0.0)
  • tool-mkspiffs 2.230.0 (2.30)
  • toolchain-xtensa32 2.50200.97 (5.2.0)
    LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
    LDF Modes: Finder ~ chain, Compatibility ~ soft
    Found 36 compatible libraries
    Scanning dependencies...
    Dependency Graph
    |-- 0.0.1
    | |-- 0.4.5+sha.29b8ee4
    | |-- 0.6.2
    | |-- 2.4.7
    | |-- 1.6.0
    | |-- 1.0.4
    | |-- 4.3.0+sha.6e7e6be
    | | |-- 1.0
    | |-- 0.0.1+sha.925def4
    | |-- 1.0
    | |-- 1.0
    | | |-- 1.0
    Building in release mode
    Compiling .pio/build/ESP32/src/main.cpp.o
    In file included from /root/.platformio/lib/RFQuack/src/radio/RadioLibWrapper.h:17:0,
    from /root/.platformio/lib/RFQuack/src/radio/RFQRFM69.h:5,
    from /root/.platformio/lib/RFQuack/src/radio/drivers.h:4,
    from src/main.cpp:25:
    /root/.platformio/lib/RadioLib/src/RadioLib.h:50:4: warning: #warning "God mode active, I hope it was intentional. Buckle up, lads." [-Wcpp]
    #warning "God mode active, I hope it was intentional. Buckle up, lads."
    ^
    In file included from /root/.platformio/lib/RadioLib/src/TypeDef.h:4:0,
    from /root/.platformio/lib/RadioLib/src/RadioLib.h:43,
    from /root/.platformio/lib/RFQuack/src/radio/RadioLibWrapper.h:17,
    from /root/.platformio/lib/RFQuack/src/radio/RFQRFM69.h:5,
    from /root/.platformio/lib/RFQuack/src/radio/drivers.h:4,
    from src/main.cpp:25:
    /root/.platformio/lib/RadioLib/src/BuildOpt.h:124:57: note: #pragma message: RADIOLIB_PLATFORM: ESP32
    #define RADIOLIB_PLATFORM "ESP32"
    ^
    /root/.platformio/lib/RadioLib/src/RadioLib.h:55:41: note: in expansion of macro 'RADIOLIB_PLATFORM'
    #pragma message "RADIOLIB_PLATFORM: " RADIOLIB_PLATFORM
    ^
    In file included from /root/.platformio/lib/RFQuack/src/radio/drivers.h:4:0,
    from src/main.cpp:25:
    /root/.platformio/lib/RFQuack/src/radio/RFQRFM69.h: In member function 'virtual float RFQRF69::getRSSI(float&)':
    /root/.platformio/lib/RFQuack/src/radio/RFQRFM69.h:140:5: warning: no return statement in function returning non-void [-Wreturn-type]
    }
    ^
    Generating partitions .pio/build/ESP32/partitions.bin
    Compiling .pio/build/ESP32/lib0b2/Nanopb/pb_common.c.o
    Compiling .pio/build/ESP32/lib0b2/Nanopb/pb_decode.c.o
    Compiling .pio/build/ESP32/lib0b2/Nanopb/pb_encode.c.o
    Compiling .pio/build/ESP32/lib0b2/Nanopb/spm-test/objc/c-header.c.o
    Archiving .pio/build/ESP32/lib0b2/libNanopb.a
    Archiving .pio/build/ESP32/libbca/libTinyGSM.a
    Compiling .pio/build/ESP32/lib16c/MQTT/MQTTClient.cpp.o
    Compiling .pio/build/ESP32/lib16c/MQTT/lwmqtt/client.c.o
    Compiling .pio/build/ESP32/lib16c/MQTT/lwmqtt/helpers.c.o
    Compiling .pio/build/ESP32/lib16c/MQTT/lwmqtt/packet.c.o
    Compiling .pio/build/ESP32/lib16c/MQTT/lwmqtt/string.c.o
    Archiving .pio/build/ESP32/lib16c/libMQTT.a
    Compiling .pio/build/ESP32/lib2ab/Queue/cppQueue.cpp.o
    Archiving .pio/build/ESP32/lib2ab/libQueue.a
    Compiling .pio/build/ESP32/libed5/ArduinoLog/ArduinoLog.cpp.o
    Archiving .pio/build/ESP32/libed5/libArduinoLog.a
    Compiling .pio/build/ESP32/liba96/SPI/SPI.cpp.o
    Archiving .pio/build/ESP32/liba96/libSPI.a
    Compiling .pio/build/ESP32/liba25/RadioLib/ISerial.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/Module.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/CC1101/CC1101.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/ESP8266/ESP8266.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/HC05/HC05.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/JDY08/JDY08.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/RF69/RF69.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/RFM9x/RFM95.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/RFM9x/RFM96.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/RFM9x/RFM97.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX1231/SX1231.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX126x/SX1261.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX126x/SX1262.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX126x/SX1268.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX126x/SX126x.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX127x/SX1272.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX127x/SX1273.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX127x/SX1276.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX127x/SX1277.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX127x/SX1278.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX127x/SX1279.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX127x/SX127x.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX128x/SX1280.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX128x/SX1281.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX128x/SX1282.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/SX128x/SX128x.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/Si443x/Si4430.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/Si443x/Si4431.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/Si443x/Si4432.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/Si443x/Si443x.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/XBee/XBee.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/modules/nRF24/nRF24.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/AFSK/AFSK.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/AX25/AX25.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/HTTP/HTTP.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/Hellschreiber/Hellschreiber.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/MQTT/MQTT.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/Morse/Morse.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/PhysicalLayer/PhysicalLayer.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/RTTY/RTTY.cpp.o
    Compiling .pio/build/ESP32/liba25/RadioLib/protocols/SSTV/SSTV.cpp.o
    Archiving .pio/build/ESP32/liba25/libRadioLib.a
    Compiling .pio/build/ESP32/liba7b/Base64/Base64.cpp.o
    Archiving .pio/build/ESP32/liba7b/libBase64.a
    Compiling .pio/build/ESP32/lib789/WiFi/ETH.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFi.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiAP.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiClient.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiGeneric.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiMulti.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiSTA.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiScan.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiServer.cpp.o
    Compiling .pio/build/ESP32/lib789/WiFi/WiFiUdp.cpp.o
    Archiving .pio/build/ESP32/lib789/libWiFi.a
    Compiling .pio/build/ESP32/lib919/WiFiClientSecure/WiFiClientSecure.cpp.o
    Compiling .pio/build/ESP32/lib919/WiFiClientSecure/ssl_client.cpp.o
    Archiving .pio/build/ESP32/lib919/libWiFiClientSecure.a
    Compiling .pio/build/ESP32/lib14b/RFQuack/rfquack.pb.c.o
    Compiling .pio/build/ESP32/lib14b/RFQuack/utils/regex/re.c.o
    Archiving .pio/build/ESP32/lib14b/libRFQuack.a
    Archiving .pio/build/ESP32/libFrameworkArduinoVariant.a
    Compiling .pio/build/ESP32/FrameworkArduino/Esp.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/FunctionalInterrupt.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/HardwareSerial.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/IPAddress.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/IPv6Address.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/MD5Builder.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/Print.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/Stream.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/StreamString.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/WMath.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/WString.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/base64.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/cbuf.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-adc.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-bt.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-cpu.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-dac.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-gpio.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-i2c.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-ledc.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-log.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-matrix.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-misc.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-psram.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-rmt.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-sigmadelta.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-spi.c.o
    /root/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-spi.c: In function 'spiTransferBytesNL':
    /root/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-spi.c:922:39: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
    uint8_t * last_out8 = &result[c_longs-1];
    ^
    /root/.platformio/packages/framework-arduinoespressif32/cores/esp32/esp32-hal-spi.c:923:40: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
    uint8_t * last_data8 = &last_data;
    ^
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-time.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-timer.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-touch.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/esp32-hal-uart.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/libb64/cdecode.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/libb64/cencode.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/main.cpp.o
    Compiling .pio/build/ESP32/FrameworkArduino/stdlib_noniso.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/wiring_pulse.c.o
    Compiling .pio/build/ESP32/FrameworkArduino/wiring_shift.c.o
    Archiving .pio/build/ESP32/libFrameworkArduino.a
    Linking .pio/build/ESP32/firmware.elf
    Retrieving maximum program size .pio/build/ESP32/firmware.elf
    Checking size .pio/build/ESP32/firmware.elf
    Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
    RAM: [== ] 16.9% (used 55424 bytes from 327680 bytes)
    Flash: [== ] 22.9% (used 300586 bytes from 1310720 bytes)
    Building .pio/build/ESP32/firmware.bin
    esptool.py v3.0
    Configuring upload protocol...
    AVAILABLE: esp-prog, espota, esptool, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa
    CURRENT: upload_protocol = esptool
    Looking for upload port...
    Use manually specified: /board
    Uploading .pio/build/ESP32/firmware.bin
    esptool.py v3.0
    Serial port /board
    Connecting......................................_____

A fatal error occurred: Failed to connect to ESP32: Timed out waiting for packet header
*** [upload] Error 2
======================================================== [FAILED] Took 155.77 seconds ========================================================

Environment Status Duration


ESP32 FAILED 00:02:35.772
==================================================== 1 failed, 0 succeeded in 00:02:35.772 ====================================================
Makefile:56: recipe for target 'flash' failed
make: *** [flash] Error 1

I asked over at the Evil Crow Github, and it appears to be incompatible with VMWare. I'm using Windows, running Ububtu in a VM. I had the same problem with the Evil Crow firmware, but since it was an INO sketch, I could easily compile it using Arduino for Windows, and it worked fine. Is there a way to compile and flash RFQuack under Windows?

Hi @phretor

The problem is that this does not work correctly on virtual machines. I have recommended you to do this on a physical machine

I have not tested the installation on Windows, but on Ubuntu it works perfectly

@RChadwick7 Try to do this on a physical machine, don't use virtual machine

@joelsernamoreno @RChadwick7 have you solved this?

just had the same experience yesterday flashing my evil crow v2 in a VM on VMware. @RChadwick7 needs to press the button as soon as it says "Connecting" and it will flash without issues. This is not a VMware incompatibility since mine worked with the same scenario.

Hello

One person made a fork of rfquack for Evil Crow RF V2. Check this out:

https://github.com/akito45/RFQuack

I haven't had time to test this yet, but one person has confirmed that this works with Evil Crow RF V2.

Try not to use virtual machines to flash this.

Let me know if this works

Thanks

I saw a PR from @akito45 - I'm waiting for him to rebase against the newest master, which has changed a lot since the last commit.

@RChadwick7 @joelsernamoreno @imagina9900 - I encourage you to check again with the new build framework. Very likely you're not going to need any VM. Just a sane Python environment installation.

Check this out: https://rfquack.github.io/RFQuack/usage/dependencies/

Closing for no activity. @RChadwick7 @joelsernamoreno @imagina9900 let me know if you have any updates on this. So far, @jimilinuxguy has confirmed that the current version works on ECRF v2.