SmartRC-CC1101-Driver-Lib icon indicating copy to clipboard operation
SmartRC-CC1101-Driver-Lib copied to clipboard

Cannot Compile Esphome

Open ginjac opened this issue 1 year ago • 1 comments

Hope someone can help. When I try to compile for esp32 in Esphome I am getting this error at the very end. Not sure how to define the pins that are need for this. Esp8266 compiles fine. Had some esp32's hanging around and want to give it a shot. Thanks. : In lambda function: :55:9: error: 'GPIO18' was not declared in this scope :55:9: note: suggested alternative: 'GPIO' :56:9: error: 'GPIO19' was not declared in this scope :56:9: note: suggested alternative: 'GPIO' :57:9: error: 'GPIO23' was not declared in this scope :57:9: note: suggested alternative: 'GPIO' :58:9: error: 'GPIO5' was not declared in this scope :58:9: note: suggested alternative: 'GPIO' :59:9: error: 'GPIO2' was not declared in this scope :59:9: note: suggested alternative: 'GPIO' :64:24: error: could not convert '{my_sensor}' from '' to 'std::vectoresphome::sensor::Sensor*' *** [.pioenvs/shit1/src/main.cpp.o] Error 1 ========================= [FAILED] Took 251.20 seconds =========================

ginjac avatar Jan 01 '24 15:01 ginjac

Fixed this issue, Do not put "GPIOXX in esphome yaml. Just needs the number like this... sensor:

  • platform: custom lambda: |- auto my_sensor = new CC1101( 18, // SCK 19, // MISO 23, // MOSI 5, // CSN 22, // GDO0 25, // GDO2 96.96, // bandwidth_in_khz 303.90 // freq_in_mhz ); Unfortunatly, my esp32's are bootlooping now. Not sure why yet. I can add the first turn_on command, then the bootloop occurs as soon as the "turn_off" section is added to the esphome yaml. Enabled GDO2 still bootlooping. Happens at transmission end to transmisson begin. If I uncomment the last 2 lines it bootloops. This is only the first switch of many in the esphome yaml. GDO0 is set for transmit GDO2 is set for receive. Stumped.
    • lambda: get_cc1101(transciver_1).endTransmission(); #turn_off_action: #- lambda: get_cc1101(transciver_1).beginTransmission();

ginjac avatar Jan 04 '24 02:01 ginjac