Pages: [1]   Go Down
Author Topic: SIMCOM SIM900 library to gprs  (Read 2745 times)
0 Members and 1 Guest are viewing this topic.
Portugal
Offline Offline
Edison Member
*
Karma: 37
Posts: 1573
Pretending you know everything then you will learn nothing.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello friends
I'm looking for a library to work with SIM900.I need to use GPRS to do a method get at Internet ip.
I found some libraries but they just implement send SMS and phone features(dial, answer ..)
I need one that can establish a gprs connection
Any help?
Here is a photo of my shield



* modem.png (680.45 KB, 1217x861 - viewed 71 times.)
« Last Edit: August 22, 2013, 03:07:23 pm by HugoPT » Logged

Debian,Mint,Ubuntu
Arduino Mega 2560
Arduino Nano
Arduino Duemilanove
MAC OS Montain Lion
Raspberry PI Model B


Offline Offline
God Member
*****
Karma: 9
Posts: 550
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Is this shield designed by seeedstudio? I think that you can take the official library,change some part(e.g. startup step) and maybe you'll ok..you should also look about pin used by Serial connection.
if you'll use only general method like call a phone,send sms,connection internet, probably you won't have problem..if you want also use GPIO and similar things, you must extend the library.

If you want to implement your library, please DON'T use string and malloc,but only array of chars..
« Last Edit: August 28, 2013, 12:48:22 pm by m_ri » Logged

Portugal
Offline Offline
Edison Member
*
Karma: 37
Posts: 1573
Pretending you know everything then you will learn nothing.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks for your answer.I already accomplished the task of do a http get just using the AT commands with no library.
Quote
If you want to implement your library, please DON'T use string and malloc,but only array of chars..
Uhmm Do you mean Strings, not strings right?

Logged

Debian,Mint,Ubuntu
Arduino Mega 2560
Arduino Nano
Arduino Duemilanove
MAC OS Montain Lion
Raspberry PI Model B


Offline Offline
God Member
*****
Karma: 9
Posts: 550
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ye sorry..I meant the type String..there are two main reasons:
String is heavier than char[]
there is a problem with dinamic allocation of the memory..is not impossible that the arduino couldn't allocate other vectors while the ram is partially free
Logged

Portugal
Offline Offline
Edison Member
*
Karma: 37
Posts: 1573
Pretending you know everything then you will learn nothing.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Ye sorry..I meant the type String..there are two main reasons:
String is heavier than char[]
String is not a type it's an Object.
Quote
there is a problem with dynamic allocation of the memory..
What problem?
Logged

Debian,Mint,Ubuntu
Arduino Mega 2560
Arduino Nano
Arduino Duemilanove
MAC OS Montain Lion
Raspberry PI Model B


Offline Offline
God Member
*****
Karma: 9
Posts: 550
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

where is the problem? String could be considered as a type,but not as a native type..and String is also a class,NOT an object..in addition, in C++ there are fewer difference between structures and class than common people thinks..

if you'll make some research, you'll see that there are some problem with String(especially during deallocation and subsequent allocation, if I remember correctly), and I don't know if they were fixed..in some cases, especially with an heavy usage of String, the arduino cannot allocate new block..
« Last Edit: August 28, 2013, 05:32:41 pm by m_ri » Logged

Portugal
Offline Offline
Edison Member
*
Karma: 37
Posts: 1573
Pretending you know everything then you will learn nothing.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes you are right.I almost never use Strings in arduino.I avoided it at all cost because I know the collateral damage they have in memory consumption.
 smiley-wink
Logged

Debian,Mint,Ubuntu
Arduino Mega 2560
Arduino Nano
Arduino Duemilanove
MAC OS Montain Lion
Raspberry PI Model B


Offline Offline
God Member
*****
Karma: 9
Posts: 550
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

good..I've also a seedstudio..I've token the library of open-eletronic, changed startup code and reduced various delays..

in any case, consider that all gsm modules use a set of common AT command(and AT extended), plus some personalized command, so you don't need to change lot of things, expect pins and switch-on/off
« Last Edit: August 29, 2013, 03:48:12 am by m_ri » Logged

Pages: [1]   Go Up
Jump to: