delete no use code

This commit is contained in:
zhujisheng 2019-07-09 19:10:29 +08:00
parent df96b1eb0d
commit a899f6c7cb
2 changed files with 1 additions and 34 deletions

View File

@ -15,35 +15,6 @@ bool SIM7000::begin(Stream &port)
return false;
}
bool SIM7000::checkSIMStatus(void)
{
int count = 0;
while(count < 3){
if(check_send_cmd("AT\r\n","OK")){
break;
}else{
count++;
delay(300);
}
}
if(count == 3){
return false;
}
count = 0;
while(count < 3){
if(check_send_cmd("AT+CPIN?\r\n","READY")){
break;
}else{
count++;
delay(300);
}
}
if(count == 3){
return false;
}
return true;
}
bool SIM7000::check_send_cmd(const char* cmd, const char* resp, unsigned int timeout, unsigned int chartimeout)
{
char SIMbuffer[100];

View File

@ -9,15 +9,11 @@
class SIM7000
{
public:
bool begin(Stream &port);
bool check_send_cmd(const char* cmd, const char* resp, unsigned int timeout = DEFAULT_TIMEOUT, unsigned int chartimeout = DEFAULT_INTERCHAR_TIMEOUT);
void sendCmd(const char* cmd);
int readBuffer(char *buffer, int count, unsigned int timeout = DEFAULT_TIMEOUT, unsigned int chartimeout = DEFAULT_INTERCHAR_TIMEOUT);
bool setBaudRate(long rate);
bool checkSIMStatus(void);
bool begin(Stream &port);
private:
char latitude[8];
char longitude[8];
SoftwareSerial* mySerial;
};