Wemos D1 and E220-900T22D

Tagged: 

Viewing 4 reply threads
  • Author
    Posts
    • #24736
      Dusan
      Participant

        Hi Renzo, first of all, thank you for the great libraries. I tried to replace the E32 module with the E220 module in the LoRa-Reffil-And-Waterlevel project. Everything worked fine with the E32-900t30D module. After replacing it with the E220-900t22D module and modifying part of the code (configuration, configuration output…), the server starts without problems, but when the “Start pump” command is executed, the library returns the error “Timeout!!”. I couldn’t get the client to start, as there was a cyclic restart (rst cause:2, boot mode:(3,5)). Initially, I suspected a power circuit issue, but after measuring with an oscilloscope, I found that the voltage was stable (I used an LM1084 regulator). Then I tried to measure the values on each port. Ports M0 and M1 were fine. After measuring AUX, I found some glitches (oscilloscope outputs are attached). I managed to get the client to work with the E220 module only by “forcing” it 🙂 I connected the module after booting the Wemos D1. Interestingly, everything works fine with the E32 module, but there are problems with the E220 module. Can you think of any reason for these issues? Thank you!

      • #24739
        Renzo Mischianti
        Keymaster

          Hi Dusan,
          It’s very strange, but sometimes I get an error that I resolved with the use of the reduction of pull-up resistor on M0 and M1.
          When M0 went HIGH also the M1 went HIGH.
          With only this information I don’t have any additional ideas.

          but the problem is very strange and I also like to know the reason.
          Bye Renzo

        • #24743
          Dusan
          Participant

            Hello Renzo, the cyclic restarting issue was solved by adding delay(4000) at the beginning of the setup sequence. During my attempts, I found out that ESP8266 won’t boot when pin D5 is in a low state at the moment of the setup procedure. The difference in behavior between E32 and E220 modules is probably caused by different booting speeds or perhaps different hardware designs.I haven’t been able to solve the Timeout!! error on the server side yet…. This error is interesting because the module sends out WOR and data (attachment from SDR) and data from client are received. 🤔 Have a nice day!

          • #24751
            Dusan
            Participant

              Hi Renzo, today I was trying to solve the problem with the Timeout error!! I managed to fix the error in the code // wait until aux pin goes back low
              Status res = this->waitCompleteResponse(2000);
              if (res == E220_SUCCESS) {
              this->mode = mode;
              }

              return res;
              } in the cpp file. By changing the value from 1000 to 2000 and changing WOR to the value WOR_1000_001. I wasn’t able to find the correct value for WOR_2000_011. At the same time, I confirmed that the cyclic restarting of ESP8266 is indeed caused by the library. :/ If the value of waitCompleteResponse() was too high, the ESP8266 would cyclically restart. I’m not a good programmer, so I have no idea how to fix this error. Have a nice day.

              • #24893
                Renzo Mischianti
                Keymaster

                  Hi Dusan,
                  Does It possible that you don’t set the correct mode for the devices?

                  E220 and E32 have different management of WOR, and you must manage with the correct setMode.

                  Bye Renzo

              • #24873
                george_santiago
                Participant

                  I had loop reset (Watchdog triggering) issues with the NodeMCU (esp8266) when sending a message with the LoRa_E220::sendMessage function. The message was sent, but the last character of the String was truncated. Then the ESP8266 restarted because of the Watchdog.
                  Found out this was caused by not connecting the AUX pin to a GPIO. After connecting AUX from E220, ESP8266 stopped resetting.

                  My current builder setup:

                  #include <SoftwareSerial.h>
                  SoftwareSerial mySerial(D5, D6); // Arduino RX <-- e220 TX, Arduino TX --> e220 RX
                  //LoRa_E220 e220ttl(&mySerial, D0); // AUX M0 M1 . // Se não incluir o AUX no MCU, provoca WatchDOG.
                  LoRa_E220 e220ttl(&mySerial, D0, D7, D8); // AUX M0 M1 . // Se não incluir o AUX no MCU, provoca WatchDOG
              Viewing 4 reply threads
              • You must be logged in to reply to this topic.
              Exit mobile version