Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: C027_Support
Fork of C027_SupportTest by
Revision 30:062717f25e41, committed 2015-08-21
- Comitter:
- mazgch
- Date:
- Fri Aug 21 09:14:03 2015 +0000
- Parent:
- 28:334263983fcd
- Child:
- 33:e27f40fada64
- Commit message:
- clean-up
Changed in this revision
| C027_Support.lib | Show annotated file Show diff for this revision Revisions of this file |
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/C027_Support.lib Fri Dec 12 07:54:19 2014 +0000 +++ b/C027_Support.lib Fri Aug 21 09:14:03 2015 +0000 @@ -1,1 +1,1 @@ -http://mbed.org/teams/ublox/code/C027_Support/#e347ed0fab5e +http://mbed.org/teams/ublox/code/C027_Support/#7b747676de86
--- a/main.cpp Fri Dec 12 07:54:19 2014 +0000
+++ b/main.cpp Fri Aug 21 09:14:03 2015 +0000
@@ -20,7 +20,7 @@
// These parameters are ignored for LISA-C200 variants and can be left NULL.
//------------------------------------------------------------------------------------
//! Set your secret SIM pin here (e.g. "1234"). Check your SIM manual.
-#define SIMPIN NULL
+#define SIMPIN "1922"
/*! The APN of your network operator SIM, sometimes it is "internet" check your
contract with the network operator. You can also try to look-up your settings in
google: https://www.google.de/search?q=APN+list */
@@ -47,7 +47,7 @@
GPSSerial gps;
#endif
// Create the modem object
- MDMSerial mdm;
+ MDMSerial mdm(D1,D0);
//mdm.setDebug(4); // enable this for debugging issues
// initialize the modem
MDMParser::DevStatus devStatus = {};
@@ -76,14 +76,6 @@
}
if (mdmOk)
{
- // http://www.geckobeach.com/cellular/secrets/gsmcodes.php
- // http://de.wikipedia.org/wiki/USSD-Codes
- const char* ussd = "*130#"; // You may get answer "UNKNOWN APPLICATION"
- printf("Ussd Send Command %s\r\n", ussd);
- ret = mdm.ussdCommand(ussd, buf);
- if (ret > 0)
- printf("Ussd Got Answer: \"%*s\"\r\n", ret, buf);
-
// join the internet connection
MDMParser::IP ip = mdm.join(APN,USERNAME,PASSWORD);
if (ip != NOIP)
@@ -178,7 +170,16 @@
// disconnect
mdm.disconnect();
}
+
+ // http://www.geckobeach.com/cellular/secrets/gsmcodes.php
+ // http://de.wikipedia.org/wiki/USSD-Codes
+ const char* ussd = "*130#"; // You may get answer "UNKNOWN APPLICATION"
+ printf("Ussd Send Command %s\r\n", ussd);
+ ret = mdm.ussdCommand(ussd, buf);
+ if (ret > 0)
+ printf("Ussd Got Answer: \"%s\"\r\n", buf);
}
+
printf("SMS and GPS Loop\r\n");
char link[128] = "";
unsigned int i = 0xFFFFFFFF;
