Compile MMS file

Compile MMS file SearchSearch
Author Message
Marty
Posted on Wednesday, September 03, 2003 - 02:45 pm:   

Hello,

at the moment I am doing some research on the creation of an MMS message. I've been reading some topics on it on this board but a few things are not totally clear yet.
I am planning to send the MMS from a GSM (with GPRS module) modem and I am trying to create the .mms message by hand. The MMS has to be sent as an MMS to an end-user's mobile phone. The problem is that I do not understand how the included image/sound data has to be encoded in the .mms file. Is it HEX encoding or binary? I know there are some compilers which work fine for it but I need a library (preferably C/C++) to get the compiling working on a Linux-based system.

And how does the completed message have to be sent. Can I send it as a PDU from my modem by Hayes-commands (AT-commands) and how should the file be encoded then?

Any comments or advice would be welcome.

Cheers
Marty
Posted on Wednesday, September 03, 2003 - 07:43 pm:   

Anyone? Maybe some useful URLs?
Marty
Posted on Wednesday, September 03, 2003 - 07:43 pm:   

Anyone? Maybe some usefel URLs?
Bryce Norwood - NowSMS Support
Posted on Friday, September 05, 2003 - 09:19 pm:   

Marty,

This link talks about how things are done with our product, that might be a helpful starting point:

http://support.nowsms.com/discus/messages/1/589.html

You're not going to send it with an AT command. You could create a binary MMS message file ... store it on a web server with the appropriate content type (application/vnd.wap.mms-message) ... and you could send an MMS notification message out over SMS (via AT commands) to tell a recipient mobile to fetch the URL that contains the MMS message content.

But many network operators block MMS messages that originate from external MMSCs. (The phone receives the notification, but it is unable to retrieve the message URL.)

The other approach is to initiate a GPRS connection. And then open a connection to the operator WAP gateway over GPRS ... and send the MMS message content to the operator MMSC via WAP protocols and GPRS. Again, not simple AT commands.

-bn
Marty
Posted on Monday, September 08, 2003 - 08:44 am:   

Thanks for your answer Brice. It is clear now that I first need to contact some GPRS providers here in Holland to see what they offer in the cas of MMS messaging. Can you point to some information or website how an MMS message should be encoded to be able to 'send' it to a phone? Can you send the contents and message body as seperate files or is it really necessery to compile it as 1 MMS message file? I was thinking about that last case. Probably someone on the board knows about it.
Bryce Norwood - NowSMS Support
Posted on Wednesday, September 10, 2003 - 10:43 pm:   

Marty,

Now you're asking the tough questions. Here is a thread that might help you with the connectivity questions. Establishing connections is more difficult than the content itself.

http://support.nowsms.com/discus/messages/1/589.html

The MMS Encapsulation Specification, published by the Open Mobile Alliance (http://www.openmobilealliance.org) defines the MMS message format. This specification makes reference and uses other WAP specifications published by the OMA, including the WSP, WTP and WDP specifications.

If you're talking about MMS at a raw level, then it is a binary file encoded according to this MMS Encapsulation format. The MMS message that a phone retrieves from an MMSC is in that format.

How the message is encoded when connecting via a service provider could vary.

When a phone actually sends an MMS message to another phone, it sends a binary compiled MMS message to an MMSC over an interface known as "MM1". The MMSC handles ultimate delivery of the message.

Some providers might provide other interfaces for submitting messages into their systems. For example, MM7 (published by ETSI in TS 23.140) is the suggested standard for application to MMSC communication. This format is XML/SOAP based and the MMS content is in multipart MIME format.

-bn
Marty
Unregistered guest
Posted on Wednesday, October 22, 2003 - 01:25 pm:   

It is still not completely clear to me what happens at which place. Let's assume there is a WTP Post to the MMSC's WAP Gateway. What should happen in my application at the code level and what happens physically in the modem. What commands are done by the modem and what should the application. Could anyone clarify this?
Emanuele Vittore
New member
Username: Emavit

Post Number: 1
Registered: 10-2003
Posted on Wednesday, October 22, 2003 - 03:15 pm:   

I have same problem; which commands AT, and as, I must use AT GPRS commands to send via modem to MMSC a MMS message
Emanuele Vittore
New member
Username: Emavit

Post Number: 2
Registered: 10-2003
Posted on Wednesday, October 22, 2003 - 03:34 pm:   

My Hyper Terminal answers therefore to my comands :

at+cgdcont?
+CGDCONT: 3,"IP","WAP.OMNITEL.IT","",0,0
OK
at+cgatt=1
OK
at+cgact=1,3
OK
at+cgdata=?
+CGDATA: ("PPP")
OK
at+cgdata="PPP",3
ERROR

I ask you, are correct my steps?
Marty
New member
Username: Marty

Post Number: 1
Registered: 10-2003
Posted on Wednesday, October 22, 2003 - 03:41 pm:   

OK, the case is sending an MMS massage to the WAP gateway of the MMSC. This is a WSP Connect//Post//Disconnect. Which are on its turn WTP invoke/ack//invoke//ack messages to the WAP Gateway but how should these messages be programmed in speaking of protocols (OSI).

Could anyone show with some example sourcecode maybe what the program does in practice in relation to the modem and to the gateway. I assume the first step would be building up a GPRS connection to the gateway. But from that point, how is information transmitted through the modem and what programming steps should be done at that point?

Someone on this board should have experience on it I hope or what tools could be used. Any help would be very welcome, escpecially on the signals that are sent between Client (OA) and Gateway.
Marty
New member
Username: Marty

Post Number: 2
Registered: 10-2003
Posted on Thursday, October 23, 2003 - 08:53 am:   

OK,

I think I am 1 step further. It seems that you could draw this picture in the case of WDP.

In case of GSM CSD:
Layer 4: UDP
Layer 3: Internet Protocol (IP)
Layer 2: Point-to-Point Protocol (PPP)
Layer 1: GSM CSD

In case of GSM GPRS:
Layer 4: UDP
Layer 3: IP
Layers 1 and 2: GSM and GPRS
Since GPRS works on Layers 1 and 2 PPP is not necessary. Please correct if I am wrong.

So WDP would be the transport protocol of the WAP technology. Where would WSP and WTP fit in?

There are 2 ways of WSP: a connection-oriented session service protocol over WTP and a connectionless service protocol over the WDP. WTP on its turn works over WDP. (When a connectionless service is used would WTP be left out?) So how do WTP and WSP work. How could WSP and WTP be put into layers.
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 995
Registered: 10-2002
Posted on Tuesday, October 28, 2003 - 06:03 pm:   

Emanuele,

I'm not sure what result you are expecting from the AT+CGDATA command ... but basically, as I mentioned in another thread, you generally issue the AT*99# command to start a data connection, and at that point the PPP protocol takes over, and you start talking PPP instead of AT commands.
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 996
Registered: 10-2002
Posted on Tuesday, October 28, 2003 - 06:13 pm:   

Marty,

Unfortunately, my mind isn't geared properly to think in terms of OSI layers.

I can tell you that most GSM/GPRS modems implement PPP, so when you want to go on-line with GPRS over a GSM/GPRS modem, you issue the AT*99# command, and PPP takes over.

I believe you are correct, however, that PPP is not strictly needed in this environment. It's just that this is the best way to present it over a modem interface, so that conventional dial-up networking clients can connect via GPRS.


quote:

There are 2 ways of WSP: a connection-oriented session service protocol over WTP and a connectionless service protocol over the WDP. WTP on its turn works over WDP. (When a connectionless service is used would WTP be left out?) So how do WTP and WSP work. How could WSP and WTP be put into layers.




Right, WTP is left out completely in connection-less WSP.

Since I don't have an OSI brain, I'm not sure how to map these into layers, but I'll try to provide some simple examples of how each of these protocols is used.

WDP is a simple datagram service. It has a concept of source and destination port numbers (and an address space which might be phone numbers in the SMS world or IP addresses in the IP world), but that's about it. When you send a WDP packet, it is an unreliable datagram from the source to the destination.

WTP adds a reliable transaction layer (at least in Class 2). So a higher layer protocol can issue a transaction request, and WTP manages the retry logic and acknowledgements to ensure reliable delivery. WTP also provides segmentation and re-assembly so that it can manage the sending of larger transactions over smaller sized datagrams at the WDP layer. All WTP transactions are sent over WDP.

WSP adds a session layer, but considering that it also defines a connection-less service, the "session" concept in the name doesn't seem clear to me.

In connection-less WSP, a limited subset of WSP PDUs can be sent directly over WDP.

In connection-oriented WSP, WSP PDUs are sent over WTP. (WTP manages retry logic and segmentation and re-assembly.)

Does that help?
Marty
New member
Username: Marty

Post Number: 14
Registered: 10-2003
Posted on Tuesday, November 11, 2003 - 02:59 pm:   

Yep, that helped. But I am wondering, when developing an application, should I use connection-less or connection-oriented transfers? Do operators require a certain type. Does for example Vodafone use connectionless or oriented method to communicate? Will one of the two types work in all situations?
Emanuele Vittore
New member
Username: Emavit

Post Number: 17
Registered: 10-2003
Posted on Thursday, November 13, 2003 - 01:26 pm:   

excuse me, I would need to know how I what send wap gateway:
1. wsp connect = ?
2. wsp post= ?
Thanks
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 1121
Registered: 10-2002
Posted on Thursday, November 13, 2003 - 08:15 pm:   

Marty,

You'll likely run into problems (and size limitations) if you use connection-less WSP. Connection-oriented WSP operates of WTP, which offers segmentation-and-reassembly functionality for transferring larger amounts of data.

-bn
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 1122
Registered: 10-2002
Posted on Thursday, November 13, 2003 - 08:22 pm:   

Emanuele,

One of the things that you'll notice about me is that vague questions get vague responses. I'm not trying to be smart ... I just have quite a bit of work to do, so more specific technical questions get more specific technical answers.

Connection oriented WSP is defined in section 7.1 of the WAP WSP specification (WAP-230). The WSP Connect PDU format is defined in Section 8.2.2.1.

The WSP Post PDU format is defined in Section 8.2.3.2.

I suspect what you are really after is an example of these transactions. using the Ethereal line analyser is a great tool for capturing this type of data ... while I'm not aware of any MMS client simulators which simulate actual MMS network traffic, you can see WAP session traffic using a WAP client simulator.

However, since so many people seem to want to see a sample session, I captured one and posted it at the bottom of the following thread:

http://support.nowsms.com/discus/messages/12/522.html

Cheers!

-bn
Marty
New member
Username: Marty

Post Number: 19
Registered: 10-2003
Posted on Tuesday, November 18, 2003 - 09:55 am:   

What would be the recommended WTP Class (0, 1 or 2) be on sending MMS messages over WAP to the WAP GW? Reading the specs Class 1 sounds suitable or would it be better to leave the choise of a WTP Class open?

What would be the default choice?
Bryce Norwood - NowSMS Support
Board Administrator
Username: Bryce

Post Number: 1217
Registered: 10-2002
Posted on Friday, November 21, 2003 - 08:38 pm:   

Marty,

You need to use Class 2, as a response is expected.

When you issue the M-send.req, you want to get an M-send.conf response to know that the message was accepted (or rejected) by the MMSC.

In practice, you don't see the other classes very widely used. The only time I've ever seen Class 0 or Class 1 used is with the Disconnect PDU. (There is no response defined for the WSP disconnect PDU.)

Within MMS, there is no response defined for the M-acknowledge.ind transaction that a client generates ... but you'll generally find that MMS clients still issue this as a Class 2 transaction, and just ignore the response.