-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[HELP] How to compile this correctly #12
Comments
Hello. I have make lot of test. But was is this Error? undefined reference to and a lot more. --- LONG --- /home/ls/.arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/3.0.4-gcc10.3-1757bed/bin/../lib/gcc/xtensa-lx106-elf/10.3.0/../../../../xtensa-lx106-elf/bin/ld: /tmp/arduino-sketch-F6DF9EA8EA0AD8A141217D84F3C1ACEB/sketch/BresserWeatherSensorMQTT.ino.cpp.o: in function exit status 1 Compilation error: exit status 1 # |
Hi, I just tried it with Arduino 1.8.19 and an empty Arduino library directory and it worked as follows:
Please check that your pinning matches the default:
You can of course copy the secrets to
Hope this helps! Best regards |
Thank you for the detailed instructions. I noticed a small error:
The original entry works Maybe there is a possibility to add this instruction to the wiki. Best regards |
Hello. I have made file test today. It is not working properly yet.
After that reboot:
I have a D1 mini from AZ Delivery. Which ESP8266 + CC1101 do you use and how does the pinout look like? Gruß |
Therefore I have added the comment
in the tutorial and changed NUM_SENSORS and the number of entries to 1. Presumably most users might want to start with one sensor.
At least I have added a link to the tutorial to the README.md. Regarding LoRaWAN and TTN (and Helium Network): see https://github.com/matthias-bs/BresserWeatherSensorTTN 😉 |
Here you can find my pinout: https://github.com/matthias-bs/BresserWeatherSensorReceiver/blob/main/ESP8266_WeMos_D1-Mini_pinout_cc1101_v2.pdf (My ESP8266 was actually from BerryBase, but I also ordered some stuff from AZ Delivery.) For debugging, I suggest you switch to BresserWeatherSensorBasic and enable Maybe something is still wrong with the SW, maybe your CC1101 or ESP8266 is broken. (I spent a lot of time with a CC1101 which was dead-on-delivery. And just recently I pulled my hair out with a partially defect ESP32 module.) |
Hello. I tested three different ESP8266 boards. On "uPesy ESP32 Wroom DevKit" the software runs without reboot. I used the BresserWeatherSensorBasic & BresserWeatherSensorMQTT for testing. |
Hello. I have successfully tested with an older version the ESP8266 + cc1101. Here the reception works and data is transmitted via MQTT. The current version has a bug? ----- DEBUG Mode ----- |
Did you receive any debug messages with the current version? |
With the current version I did not get a DEBUG message.
|
Hi @gitpower2017 , do you use a USB cable for the power? Sometimes cheap USB Cable does not give enough power. Just try a different one. I had same issues with other software, and I am using this software with same devices like you without any problem since weeks. Br. Frank |
24.10.2022 An older software version works without any problems. |
Hi @gitpower2017 , I tested the new version again and got also a WDT Error. What is happening is that the state for the radio Lib returns -2 if the CC1101 is not correctly working. Hope this helps |
I am currently tracking this down... I am quite sure that the way I try to use |
Yes, I can confirm the expected root cause. |
I hope I can provide a clean solution now.
|
Hello. The bugfix seems to work. The version "BresserWeatherSensorBasic" & "BresserWeatherSensorMQTT" still brings the error "Soft WDT reset". PS: I use "USE_WIFI" however the name is (I think) inappropriate. Is perhaps "MQTT_NOSECURE" better? Is there an example for the secure.h? |
Hi @gitpower2017 , your settings for the CC1101 seems to be still not OK. I would suggest to check the cable (But I think you already did this). Can you tell us what setting you are using in WeatherSensorCfg.h ? |
Enclosed is my file. I am checking my pinout. |
Hi @gitpower2017 , you should choose the right device at: If you have a older device use for a newer one use: to figure out what device you have look at " Readme" Your pinout should be like https://github.com/Man-fred/culfw-esp8266/wiki/Hardware |
I have "70-02510" => 5in1 'll build myself another CC1101 + D1mini. |
Did you receive any debug messages with the current version?
Presumably you have an RF signal quality issue. If you get the RSSI value, the communication between ESP and RF transceiver seems to be o.k.
These examples use the default WeatherSensorCfg.h which will not match your setup. You get a WDT reset, because RF transceiver initialization gets stuck in an endless loop, because the wrong transceiver response is expected.
Please see #12 (comment) for the contents of |
You do not have to select the decoder any more. The SW tries the first one; if decoding fails it tries the other one. |
I have now done some test. With the version "Bresser_Weather_Sensor_CC1101_MQTT" I get value displayed. I have to reboot the ESP most 2-3x. LOG:
I have attached my sketch including the console output. With the same hardware and the "BresserWeatherSensorMQTTCustom" version I get only the rssi values displayed. LOG:
I have attached my sketch including the console output. |
Oh, I put the Can you please increase From your sensor ID (length: 1 byte), I assume that you have a sensor using the 5-in-1 protocol. That's good, because all data is contained in one RF message as opposed to the 6-in-1 protocol where the data is contained in two messages. Just to be sure, you could change the line no. 624 in WeatherDataMQTTCustom.ino The default line tries to receive all values even if contained in two separate messages until a timeout occurs ( |
Here are some hints about improving the radio signal range: |
Hi @gitpower2017 , I tested your code (BresserWeatherSensorMQTTCustom) and for me it is working fine with a bresser 6in1. sensor ESPWeatherLSD-BABA07/data/14200203: {"id":14200203,"ch":0,"battery_ok":1,"temp_c":16.0,"humidity":78,"wind_gust":0.7,"wind_avg":0.7,"wind_dir":22.0,"uv":0.0,"rain":709.6,"rain_d":0.0,"rain_w":0.0,"rain_m":0.0} |
And now come the strange thing : I also have a bresser 5in1 Sensor (was a cheap offer at Bresser so I could not resits) and this sensor is also not recognize.! |
It look like that the switch between the 6in1 and 5in1 does not work. And than I receive the 5in1 data and 6in1 |
In another cc1101 bresser project, you can set a FrequencyOffset. |
I would prefer to move some items to separate issues... I have successfully used the same code with two different kinds of sensors - one is using the 5-in-1 protocol, the other one the 6-in-1 protocol. But - after reviewing it, I found the following issue: We have the following initialization:
Then we have
If we did not define BRESSER_6_IN_1 (i.e. we changed the default config), then Fixed in: 3c5dde5 In the default configuration, both decodeBresser6In1Payload() will return one of the following:
Actually DECODE_PAR_ERR is not used in |
Which project are you referring to? How is the offset determined? May I ask you to open another issue as a request for a new feature? |
This leads to another situation - did you change NUM_SENSORS to 2?
Ah - and in case of the soil moisture sensor, also the 6-in-1 protocol is used, but all data is contained in a single message. |
I am now flooded with a bit much info. |
Sorry about this. Some comments have been more directed at @franki29. :-) |
Hi @matthias-bs , yes I changed it to NUM_SENSORS to 2. But the code that gitpower2017 was using did not work without changing the line 240 to 245. |
I fetched the current GIT, increased the value for RX timeout to 100 & 120 sec. Nothing has changed, I only see the RSSI value. If I enable #define DEBUG_MODE in the src/WeatherSensorCfg.h it does not compile.
So that one can use the secret.h, still a #define SECRET is missing I guess the code for the secret.h should look like this:
|
Hi @gitpower2017 for testing just do following:
This is of course not a final solution but it should work for you |
The same. I will rebuild the CC1101+esp8266 this weekend. |
I have added comments about secrets.h in the sketches and renamed the define to be consistent with the file name, i.e. In the sketch:
|
I have performed many tests.
I have entered the frequency 868.4 in the WeatherSensor.cpp (line 82). Your implementation receives mostly one correct packet, but also many wrong ones. In conclusion, YES it does work occasionally. Maybe you can create a 5in1 and a 6in1 version. Very few probably have both. Postscript: I may have found my problem! |
Regarding your Postscript: Does it fix your reception problem and/or the protocol switching issue? I have used the library with both protocols without changes. I'm also planning to use it with a 5-in-1-protocol weather station and a 6-in-1-protocol soil moisture sensor, therefore two versions are not an option for me. If you still think the protocol switching does not work, just disable the unwanted protocol in the header file. |
My problem is the USB power supply. Thanks for the great project. I think the ticket can be closed. Greetings |
Hello.
I could not find any instructions in the wiki on how to compile the software.
In the file "WeatherSensorCFG.h" I have defined my ESP8266, cc1101 and the 5in1 sensor.
Only how does it go on then?
Greetings Lothar
The text was updated successfully, but these errors were encountered: