Discussion in "Embedded GSM Development" started by    Alvanbert    Feb 10, 2012.
Sat Mar 10 2012, 01:29 AM
#41
The reason for missing the 2nd and 4th lines are (my opinion) the 20x4 LCD adress ranges are different.

like this :

0,1,2...........17,18,19
64,65,.........81,82,83
20,21,.........37,38,39
84,85,.....101,102,103

After writing to position 19, you must jumpt0 64th position, so u need to command the LCD
to reposition to 64 and after writing to position 83 , u need to jump to 20th position.

So u can make a function for this... Hope i am not wrong



[ Edited Sat Mar 10 2012, 01:33 AM ]
Sun Mar 11 2012, 10:41 PM
#42
you're right firoz.. Alvanbert needs to write a function that takes care of printing string and wrapping them to new line when they reaches the end of first line or say 20 characters.
Mon Mar 12 2012, 07:26 AM
#43
Yes Ajay. Am really trying to figure out how to do that. Bt need ur help on this as well
Mon Mar 12 2012, 11:49 AM
#44
u can take 4 varialbles as LINE1 , LINE2, LINE3 and LINE4 and save ur message in them with 20 charactes each.
supose ur sms is in SMS_INFO character:

for(int i=0;i<20;i++)
    LINE1[i]=SMS_INFO[i];

for(int i=0,j=20;i<20;i++,j++)
    LINE2[i]=SMS_INFO[j];

for(int i=0,j=40;i<20;i++,j++)
    LINE3[i]=SMS_INFO[j];

for(int i=0,j=60;i<20;i++,j++)
    LINE4[i]=SMS_INFO[j];


then u can write a small routine that wil send all 4 variables to 4 lines.

LCD_4line(){
LCD_Add(0x00);
for(int i=0;i<20;i++)
      LCD_data(LINE1[i]);

LCD_Add(0x64);
for(int i=0;i<20;i++)
      LCD_data(LINE2[i]);

LCD_Add(0x20);
for(int i=0;i<20;i++)
      LCD_data(LINE3[i]);

LCD_Add(0x84);
for(int i=0;i<20;i++)
      LCD_data(LINE4[i]);
}

If i were to write , then i would do something as this. May be there are easy ways, but am not sure


[ Edited Mon Mar 12 2012, 12:11 PM ]
Mon Mar 12 2012, 12:10 PM
#45
Y do i write codes in long ways

hehe this is moe simple
LCD_4line()
{
LCD_Add(0x00);
for(int i=0;i<20;i++)
      LCD_data(SMS_info[i]);

LCD_Add(0x64);
for(int i=20;i<40;i++)
      LCD_data(SMS_info[i]);

LCD_Add(0x20);
for(int i=40;i<60;i++)
      LCD_data(SMS_info[i]);

LCD_Add(0x84);
for(int i=60;i<80;i++)
      LCD_data(SMS_info[i]);
}


Some one Give proper way here , else i might spam here with all sorts of stupid coding of mine


[ Edited Mon Mar 12 2012, 12:23 PM ]
Mon Mar 19 2012, 06:44 PM
#46
Thanks Alot firoz3321, your code worked just fine for me. Now i can display the whole message on the four lcd lines.

i however still have some issues. I would love the message to start from the last point on the last line and then scroll from down upwards both horizontally to the left and upwards with each word following each other. Is it possible.

Secondly, can someone write me a function to delete sms from sim memory after a specified period of time(e.g After 5 Hours). THANK YOU ALL FOR BEING HELPFUL.
Wed Mar 21 2012, 02:26 AM
#47
Great!. Feel free to share with us...
Wed Mar 21 2012, 11:07 AM
#48
what is the best way i can use to filter my messages as they are outputting to the lcd screen. i want it to only display the content between the"#" symbol and another "#" symbol at the end. i dont want it to display anything else.

so that only messages sent with # at the beginning and at the end can be displayed. pliz help
Sun Mar 25 2012, 01:38 PM
#49
@ Alvanbert
first step is to extract relevant message from sms
after that u has to check first # then display whole message till the 2nd #
i think when u extract message from sms
that will be ur real message that u want to display
i think no need of two #
Mon Mar 26 2012, 02:22 AM
#50
@Majoka how can i do this without using the #'s because my main aim is to only display the sent sms. I dnt wnt the display to include the date, time.... I wnt only the msg as sent by the user. Thanx

Get Social

Information

Powered by e107 Forum System

Downloads

Comments

jasmeet_singh
Thu Apr 17 2014, 10:19 AM
embeddevil
Thu Apr 17 2014, 08:44 AM
viniciusheidrun
Wed Apr 16 2014, 07:32 AM
Colbee
Tue Apr 15 2014, 04:12 PM
sanket400
Tue Apr 15 2014, 11:21 AM
irfanahmed11
Mon Apr 14 2014, 10:00 PM
my_love
Sun Apr 13 2014, 02:59 PM
manpreet.31
Sun Apr 13 2014, 12:41 PM

Conversation

ExperimenterUK
Thu Apr 17 2014, 01:23 PM
@mba Great .. please do.
Thu Apr 17 2014, 12:27 AM
mba'
like the forum and wish to participate
ExperimenterUK
Wed Apr 16 2014, 04:45 PM
@viniciusheidrun..you should read my comment just before your post
viniciusheidrun
Wed Apr 16 2014, 01:43 PM
I'm doing a drive system with SIM900D modem and microcontroller AT89S52 via sms. I'm having trouble can not generate the. Hex to send to the microcontroller, whenever I compile the error, I'm using MCU 8051 IDE, what should I do so that my system receive sms and perform my task?
ExperimenterUK
Mon Apr 14 2014, 01:00 PM
@Haranadh,bipin chandra etc. Create threads for your questions.
Sun Apr 13 2014, 04:05 AM
Haranadh
we bought HC 06 Bluetooth modem instead of Module ,Can any one help me of using it as bluetooth module since i am doing this project?
Sun Apr 13 2014, 03:58 AM
Haranadh
Hi,Actually we bought Bluetooth modem instead of Bluetooth Module
ajay_bhargav
Sat Apr 12 2014, 02:55 PM
Please use forum if you want to ask a question.
Sat Apr 12 2014, 01:06 PM
Dpk
Hi Ahana,I can Help you on this
Sat Apr 12 2014, 03:51 AM
bipin chandra
can anybody help me. we are making a project to control the position of dc motor. so there we need to interface lcd screen and the 4X3 memberane keypad and a dc motor driver chip. can anybody please give me the complete circuit diagram connection of these components with the 8051.and alse help in the programming. my email id is bipin.chandra666@gmail.com
  Choose Skin