Main Site Documentation

C++ driver for Sim900 - breathing new life into the cellular module?


#1

In my frustration with the cellular module, I have been beating the bush for alternatives.

We need a cool driver. (period!)

I have found this code by Libelium, which seems to be of pretty high quality. https://github.com/Libelium/waspmoteapi/tree/master/libraries/GPRS_Pro

Would it be feasible to port this, or can it be used as is for non-commercial purposes?


#2

I am also frustration with the cellular module too.
I Just find this?

Libelium has many good boards ,sensors and also drivers,
But a little expensive.


#3

I think the ideal modem hardware would be to use USB thumb drive style modems on mainboards that supports USB host. These types of modems are small, elegant and most supports 3G or better these days. And Telco’s often give them away for free with data plans. I would like to see a good netmf library that works with those types of modems. Especially the more popular ones from the big telco’s


#4

My only concern with these thumb type models is that very few, if any, have an external antenna connection. Most of my remote units are located inside a metal cabinet to protect from the elements so I need to connect up an external antenna.

I’d be interested to know what issues you guys are having. I am using an Itead Studio board with a SIM900 and it works well. Granted I don’t have the high speed port due to driver issues but I have a reliable SMS capability which is what I need.

On the ChipworX based design I use a custom based board with the SIM900B and again, it works well with the driver I use. I found this on codeshare and did quite a few modifications to it to work with my board.

I am working with another Cobra 2 board and a SIM900 module to use the built in TCP/IP stack as currently there is no PPP support in 4.2

This will be a home project board so I will be willing to post the code for this but it may be a couple of months before the project is completed and working.


#5

Dave I think the issue is for GPRS data mode with and without TCP/IP.
I also use SIM900 board without problems, but only for SMS and this works fine.
I have used TELIT and SONY-ERICSONN m2m modems years ago and always it’s a problem to keep a riliable data transfer with cell modems. It’s good idea to use “data keys” like HUAWEI but most of them needs drivers for USB.
I successfully used 1 year ago a HUAWEI E220 (Vodafone) USB terminal key for data send/receive, but just for very small msg and e220 is a CDC like connection to USB (the code was not for NETMF) .


#6

Hmm, thanks for the feedback, but no-one really got back to me on the cpp-driver-code.

The existing driver for the cellular module needs a serious re-design, and some major improvements.

The existing driver DOES support simple SMS functionality, which is fine for simple alert stuff. But the really powerful stuff is when you have the option of creating a tcp/ip connection with a server and upload a picture, sensor data etc.

Byron has built a driver version which supports a tcp/ip connection, and I have gotten it working. But it is unpredictable, and it is hard to ensure you have the right exception handling in place.

Would it be feasible to port the C++ driver to C# and NetMF?


#7

I have just bought a SIM900 module, and I want SMS+TCP functionality, so I kinda feel concerned now when you say both drivers are not of good quality.

I took a look. That C++ drivers doesn’t look hard to port, yet still there’s plenty of work. Are you sure it is what you (and now me :slight_smile: ) want?


#8

There is plenty of work, and I am not capable of doing it myself. But I am sure there is others out there that would be interested in helping out. Logitechs and Byron, and quite a few other really competent guys. If we split it into sections, and coordinated it well, it should be a relatively small task to do.

I would love to test and debug.


#9

I read some about porting from C++ http://msdn.microsoft.com/en-us/magazine/cc301520.aspx

I am thinking, can we keep it in C++ and just compile it? Any chance?


#10

No, compiling without changes won’t work. Even if it did, the resulting code would be totally not C#-ish.

I’ll take a deeper look over the weekend.


#11

I meant tweaking the C++ code to match the gadgeteer settings, and re-write certain parts. And then compiling it as driver, is that possible?


#12

Guys, I’d be interesting in helping out with this. I use the SIM900 and if I am going to move to the G400 from ChipworX I am going to need to use something for the TCP/IP seeing as 4.2 does not support it.

Once I receive some mounting boards from Juston, I am going to be putting together a Cobra 2 board with a SIM900 based board from Itead Studio so I will then be in a position to work on this. I already have SMS working but it uses ASCII mode which limits the text to 140 characters so I am looking to switch this over to using PDU mode. I have C code for this so just needs porting.

After I get that working I want to look at the TCP/IP side. What features are we wanting to have with this?


#13

Dave McLaughlin:
looking forward to see your porting
Ialso need PDU mode for Chinese character and if the driver have httpclient implemented would be good.


#14

Hmm, by accident the following codeshare entry has slipped my attention: https://www.ghielectronics.com/community/codeshare/entry/622

Does anybody have any experience with that piece of code?


#15

Here there’s a discussion about that:
https://www.ghielectronics.com/community/forum/topic?id=8721

But I missed this driver ! Interesting to discover !


#16

Anyone seeing clearly what to do now?


#17

Hi njbuch,

I have ordered 2 modules from Seeed last week and expecting them to arrive this week so I’ll be on the code once I get them.


#18

What route have you chosen?


#19

I am going to have a look at the one you posted and see if I can expand it to handle PDU mode etc.

https://www.ghielectronics.com/community/codeshare/entry/622


#20

Brilliant, I am in for testing.

Aim for stability and error handling!