Giter Site home page Giter Site logo

botletics / botletics-sim7000 Goto Github PK

View Code? Open in Web Editor NEW
18.0 3.0 9.0 130.7 MB

Arduino library repo for the Botletics SIM7000 Shield

Home Page: https://www.botletics.com/products/sim7000-shield

License: GNU General Public License v3.0

C++ 98.17% C 1.83%
arduino arduino-library cat-m1 cellular gps iot lte nb-iot wireless

botletics-sim7000's People

Contributors

bendory avatar botletics avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

botletics-sim7000's Issues

Unsolicited messages

Does this library handle unsolicited messages? Especially those that happen in-between a response from a command? Thanks

'Adafruit_FONA_LTE' does not name a type; did you mean 'Adafruit_FONA_3G'

I'm using a LilyGo T-SIM7000G and I'm having trouble compiling the AdafruitIO_MQTT_Demo example. I'm using the Arduino IDE and for troubleshooting purposes I am focusing on the following code:

`
#define AIO_SERVER "io.adafruit.com"
#define AIO_SERVERPORT 1883
#define AIO_USERNAME "MyUsername"
#define AIO_KEY "MyKey"

#include <BotleticsSIM7000.h>
#include <Adafruit_MQTT.h>
#include <Adafruit_MQTT_FONA.h>
#include <HardwareSerial.h>

HardwareSerial modemSerial(1);
Adafruit_FONA_LTE modem = Adafruit_FONA_LTE();
Adafruit_MQTT_FONA mqtt(&modem, AIO_SERVER, AIO_SERVERPORT, AIO_USERNAME, AIO_KEY);

void setup() {
//....
}

void loop() {
//....
}
`

I understand that the Adafruit FONA library must not be installed when using BotleticsSIM7000.h however I receive the following error when I attempt to compile:
demo.ino:10:\libraries\Adafruit_MQTT_Library/Adafruit_MQTT_FONA.h:26:10: fatal error: Adafruit_FONA.h: No such file or directory

and when the Adafruit FONA library is installed I get the following error:
demo.ino:14:1: error: 'Adafruit_FONA_LTE' does not name a type; did you mean 'Adafruit_FONA_3G'

Specify version of FONA this is meant to extend

I see this library is still in development but I was excited to give it a try. I installed it to Arduino IDE and also installed latest FONA (1.3.11), but it results in a ton of mismatching overload definitions between the two libraries. I also tried other versions of FONA but was unable to find a version that worked.

Sample compilation errors (there are many):

/home/nabeel/Arduino/libraries/Botletics-SIM7000-main/src/BotleticsSIM7000.cpp:3665:9: error: prototype for 'boolean Adafruit_FONA::sendCheckReply(const char*, FONAFlashStringPtr, uint16_t)' does not match any in class 'Adafruit_FONA'
 boolean Adafruit_FONA::sendCheckReply(const char* send, FONAFlashStringPtr reply, uint16_t timeout) {
         ^~~~~~~~~~~~~

This being I assume because that overload doesn't exist for sendCheckReply and a new overload (or any definition) cannot occur outside of the class definition.

How can I properly compile this library?

The sleep mode

Hi there,

I've tried using the SIM7600 to complete my project using the codes herein and it worked perfectly.
However, I've found the SIM7600 would enter the sleep mode automatically and that will stop other modules working.
I noticed there is a code " modem.enableSleepMode(true)", and it is supposed to control the sleep mode on or off, correct? Not sure, if I need to switch it off all the way.
Hope to get your suggestion for it. I intend to apply for the SIM7600 to send an SMS message when a defined condition is triggered.

Many Thanks

Example does not compile with esp32 v2.0.8

/private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino: In function 'void setup()':
/private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino:171:41: error: no matching function for call to 'Botletics_modem_LTE::setNetworkSettings(const char [9])'
   modem.setNetworkSettings(F("hologram")); // For Hologram SIM card
                                         ^
In file included from /private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino:26:
/Users/foo/src/arduino/libraries/BotleticsSIM7000/src/BotleticsSIM7000.h:191:8: note: candidate: 'void Botletics_modem::setNetworkSettings(FStringPtr, FStringPtr, FStringPtr)'
   void setNetworkSettings(FStringPtr apn, FStringPtr username=0, FStringPtr password=0);
        ^~~~~~~~~~~~~~~~~~
/Users/foo/src/arduino/libraries/BotleticsSIM7000/src/BotleticsSIM7000.h:191:8: note:   no known conversion for argument 1 from 'const char [9]' to 'FStringPtr' {aka 'const __FlashStringHelper*'}
/private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino: In function 'void loop()':
/private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino:748:61: error: no matching function for call to 'Botletics_modem_LTE::enableNTPTimeSync(bool, const char [13])'
         if (!modem.enableNTPTimeSync(true, F("pool.ntp.org")))
                                                             ^
In file included from /private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino:26:
/Users/foo/src/arduino/libraries/BotleticsSIM7000/src/BotleticsSIM7000.h:179:11: note: candidate: 'boolean Botletics_modem::enableNTPTimeSync(boolean, FStringPtr)'
   boolean enableNTPTimeSync(boolean onoff, FStringPtr ntpserver=0);
           ^~~~~~~~~~~~~~~~~
/Users/foo/src/arduino/libraries/BotleticsSIM7000/src/BotleticsSIM7000.h:179:11: note:   no known conversion for argument 2 from 'const char [13]' to 'FStringPtr' {aka 'const __FlashStringHelper*'}
/private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino:942:122: error: no matching function for call to 'Botletics_modem_LTE::HTTP_POST_start(char [80], const char [11], uint8_t*, size_t, uint16_t*, uint16_t*)'
         if (!modem.HTTP_POST_start(url, F("text/plain"), (uint8_t *) data, strlen(data), &statuscode, (uint16_t *)&length)) {
                                                                                                                          ^
In file included from /private/var/folders/rq/8_0g107d1r5dvgg16qdb41cc0000gn/T/.arduinoIDE-unsaved2023326-3354-u5nuf.5rcti/ESP32_LTE_Demo/ESP32_LTE_Demo.ino:26:
/Users/foo/src/arduino/libraries/BotleticsSIM7000/src/BotleticsSIM7000.h:260:11: note: candidate: 'boolean Botletics_modem::HTTP_POST_start(char*, FStringPtr, const uint8_t*, uint16_t, uint16_t*, uint16_t*)'
   boolean HTTP_POST_start(char *url, FStringPtr contenttype, const uint8_t *postdata, uint16_t postdatalen,  uint16_t *status, uint16_t *datalen);
           ^~~~~~~~~~~~~~~
/Users/foo/src/arduino/libraries/BotleticsSIM7000/src/BotleticsSIM7000.h:260:11: note:   no known conversion for argument 2 from 'const char [11]' to 'FStringPtr' {aka 'const __FlashStringHelper*'}

Using library BotleticsSIM7000 at version 1.0.6 in folder: /Users/foo/src/arduino/libraries/BotleticsSIM7000 
exit status 1

Compilation error: no matching function for call to 'Botletics_modem_LTE::setNetworkSettings(const char [9])'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.