@Crowdsourcer said in More messages than expected on application server.:
@Martijn-Kooijman Thanks for the quick response. I have found the sending data error (cmd: see a previous post)!
My correct code now is:
That doesn’t look good. You must wait for the ‘@’ before sending the payload:
I had a Serial.println("…"); statement before cmd(payload), this was not a problem with payload size 6 but did not work with a larger payload! It seems that the Ublox module wants the data immidiately after initiating the AT+USOST… command.
Are you sure Serial.println() doesn’t reuse the serial port for the u-blox module? That would explain why it works up to certain sizes.
I will look into power savings later this week. A 2Ah battery now lasts about a month and includes some solar charging days. I have a solar panel facing west and capable of charging a powerbank at >200 mA, but it only manages to charge at around 100 mA at the MKR1500. Note that the Arduino stops sending data at around 3.4 V of the LiPo, so one cannot use the full capacity!
You can include a buck/boost converter depending on the battery voltage. That will make sure the u-blox still works if the battery voltage drops below it’s minimum rated voltage. Be aware that a 3.4V battery may drop below 3V during module transmission.
Settings (every 15 minutes): 16 s at about 65 mA (switching on modem after sleep and a 4 s wait after opening a channel) ,
You don’t have to wait. If you set a greeting message via AT+CSGT you can listen for this message instead of waiting a fixed time.
then about 880 s sleeping at 1.1 mA. I don’t think I can make the 16 s shorter or the 4 s delay shorter, because in the past this has lead to loss of data or double messages. But I will check again with the improved data sending with the 16 bytes.
The 1.1mA at sleep is very high, it should be 7-8uA’s. So it looks like you have some issue with the power saving.