We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
i get the error "main() auto segment too large" for the given program which should be run on atmet 89c51 how to fix it thanks.........
#include <reg51.h> void Delay(); char serialsend(char []);
void main () { char z; char command1[]={"AT+CGATT=1\r"}; char command2[]={"AT+CSTT= \"ufone.pinternet\"\r" }; char command3[]={"AT+CIICR\r"}; char command4[]={"AT+CIFSR\r"}; char command5[]={"AT+CIPSTART=\"TCP\"\"121.52.147.94\"800\r"}; char command6[]={"AT+CIPSEND\r"}; char command7[]={"GPRS is Activated"}; char command8[]={"26"}; TMOD = 0x20; TH1 = 0xFD; SCON = 0x50; TR1 = 1; serialsend(command1); Delay(); serialsend(command2); Delay(); serialsend(command3); for(z=0; z<3; z++) { Delay(); } serialsend(command4); Delay(); serialsend(command5); for(z=0; z<10; z++) { Delay(); } serialsend(command6); for(z=0; z<5; z++) { Delay(); } serialsend(command7); serialsend(command8);
} char serialsend(char array[]) { int i=0; while(array[i] != '\0') { SBUF = array[i]; while(TI == 0); TI = 0; i++; } }
void Delay() { unsigned char x; for(x=0; x<40; x++) { TMOD=0x10; TL1=0xFE; TH1=0xA5; TR1=1; while (TF1==0); TR1=0; TF1=0; } }
My note: With you representing us, we, as a group (of let's say the worlds programmers) would win because no one can beat you at "most stupid".
Hans-Bernhard Broeker's note: The only way we (anyone but you) can win, is if we don't need to compete with you. Because no one can beat you at "most stupid".
I must assume that you are a troll. But trolls are normally way more clever.
If you are a troll, then you are a person who intentionally try to fool other people into selecting a very stupid solution.
If you aren't a troll, then god bless your poor parents.