Click here to Skip to main content
Click here to Skip to main content

Converting image files to OTA file format (Mobile Picture Message)

, 8 Jul 2005
Rate this:
Please Sign up or sign in to vote.
A simple code for converting image files to OTA file format (Mobile Picture Message).


I searched the internet for a program to convert the image files to the OTA file format, but there was none!!! So, I began researching for OTA file format details... finally, I wrote a program with C# to do this...

The source code and binary files are ready for download...

The main logic of this program is an algorithm for converting images. Mobile picture messages (OTA or OTB files) have a standard size: 72x28. First of all we must create a file (*.ota) and then write 4 standard bytes into it.

byte0 -> 0000 0000 (0)
byte1 -> 0100 1000 (72)
byte2 -> 0001 1100 (28)
byte3 -> 0000 0001 (1)

Now read image, pixel by pixel, from left to right and top to bottom, every 8 pixel makes a byte for writing to the file:

black pixels = 0
Other pixels = 1

An image with size 72x28:

has 72*28 = 2016 (bits)
every 8 bits = 1 byte => 2016 / 8 = 252
and 252(bytes) + 4(standard bytes) = 256 bytes

Finally, the file size is 256 bytes.

Download and read my source code to see this program working...


This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here


About the Author

Alireza Naghizadeh
Software Developer (Senior)
Iran (Islamic Republic Of) Iran (Islamic Republic Of)
Alireza Naghizadeh

Comments and Discussions

Questionhi Pinmembermohamad milaki7-Sep-11 3:08 
AnswerRe: hi PinmemberAlireza Naghizadeh7-Sep-11 19:31 
GeneralThank's - Saber Hayati Pinmemberbazyrayaneh15-Jun-11 13:15 
Generalwant a program in java to convert .jpg image into .ota format Pinmembershoaib_bagwan8-Sep-09 23:50 
GeneralRe: want a program in java to convert .jpg image into .ota format Pinmemberprabha vd15-Sep-10 20:19 
Generalhi, Pinmemberprashant.patel31@gmail.com13-Apr-09 3:22 
GeneralRe: hi, Pinmembermusyab17-Apr-09 22:10 
GeneralHello Sir Pinmemberoviyaa16-Feb-09 19:03 
QuestionHow to send pic msgs (.ota) By Nokia E51 ? Pinmemberundead_fred11-Nov-08 3:45 
AnswerRe: How to send pic msgs (.ota) By Nokia E51 ? PinmemberAlireza Naghizadeh11-Nov-08 5:18 
GeneralTrouble with creating picture msg with my n70 PinmemberNikhil Dhotre15-Jul-08 7:44 
GeneralRegarding OTA PinmemberMuthuganesh12-Jul-08 2:44 
GeneralSending OTA file via SMPP protocol to NOKIA SMSC PinmemberIftee17-Jan-08 3:51 
GeneralAbout OTA file PinmemberTa Hoang Van9-Jan-08 15:58 
GeneralRe: About OTA file Pinmembervenki_pandi3-Feb-08 23:57 
GeneralNeed more idea Pinmembertykea_khy11-Dec-07 17:38 
GeneralSend Picture SMS as 1 SMS ( instead of conventional 3 SMS) PinmemberNight Safari3-Nov-07 23:33 
GeneralRe: Send Picture SMS as 1 SMS ( instead of conventional 3 SMS) Pinmemberstyle of worlds19-Jan-08 22:12 
QuestionFor this .OTAfile i have to instal any software in my mobile? PinmemberNarendra Mahalik24-Aug-07 2:56 
AnswerRe: For this .OTAfile i have to instal any software in my mobile? PinmemberAlireza Naghizadeh9-Sep-07 5:48 
Questionhow to send image ? PinmemberShakeel Mumtaz10-Jun-07 19:58 
AnswerRe: how to send image ? Pinmemberadnaneco18-Apr-09 20:13 
GeneralRe: how to send image ? PinmemberShakeel Mumtaz19-Apr-09 20:47 
GeneralRe: how to send image ? Pinmemberadnaneco20-Apr-09 3:54 
GeneralPicture message Pinmemberteznin5-Jan-07 2:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

| Advertise | Privacy | Terms of Use | Mobile
Web01 | 2.8.141216.1 | Last Updated 9 Jul 2005
Article Copyright 2005 by Alireza Naghizadeh
Everything else Copyright © CodeProject, 1999-2014
Layout: fixed | fluid