Rev 240 Rev 245
Line 170... Line 170...
170 delay_ms(150); 170 delay_ms(150);
171 output_high(PIN_A4); 171 output_high(PIN_A4);
172 delay_ms(150); 172 delay_ms(150);
173   173  
174   174  
175 set_pwm1_duty(500); -  
176 set_pwm2_duty(500); -  
177   -  
178 fprintf(VRTULE,"ABABABABAB"); -  
179   -  
180 Delay_ms(5000); -  
181   -  
182   -  
183 /* if(check_new_sms()) // Je odpoved "OK"? 175 if(check_new_sms()) // Je odpoved "OK"?
184 { 176 {
185 // printf(lcd_putc,"736 655 250"); 177 // printf(lcd_putc,"736 655 250");
186 delay_ms(1000); 178 delay_ms(1000);
187 } 179 }
188 else 180 else
189 { 181 {
190 read_sms(); 182 read_sms();
191   183  
192 if (odp[0] == 'A' || odp[0] == 'a') 184 /* if (odp[0] == 'A' || odp[0] == 'a')
193 { 185 {
194 set_pwm1_duty(500); 186 set_pwm1_duty(500);
195 set_pwm2_duty(500); 187 set_pwm2_duty(500);
-   188 Delay_ms(10000);
-   189 fprintf(VRTULE,"JACK[BARmk"); // "JACK BAR :)"
-   190 Delay_ms(2000);
-   191 fprintf(VRTULE,"JACK[BARmk"); // "JACK BAR :)"
196 Delay_ms(5000); 192 Delay_ms(5000);
197 fprintf(VRTULE,"ABABABABAB"); -  
198 Delay_ms(20000); -  
199 set_pwm1_duty(0); 193 set_pwm1_duty(0);
200 set_pwm2_duty(0); 194 set_pwm2_duty(0);
-   195 }*/
-   196  
-   197 /* if (odp[1] == 'h')
201 } 198 {
-   199 set_pwm1_duty(500);
-   200 set_pwm2_duty(500);
-   201 Delay_ms(10000);
-   202 fprintf(VRTULE,"[ERROR[d[["); // " ERROR 3 "
-   203 Delay_ms(2000);
-   204 fprintf(VRTULE,"[ERROR[d[["); // " ERROR 3 "
-   205 Delay_ms(2000);
-   206 fprintf(VRTULE,"[OVERFLOW["); // " OVERFLOW "
-   207 Delay_ms(2000);
-   208 fprintf(VRTULE,"[OVERFLOW[");
-   209 Delay_ms(5000);
-   210 set_pwm1_duty(0);
-   211 set_pwm2_duty(0);
-   212 }*/
202   213  
203 if (odp[0] == 118 && odp[1] == 121 && odp[2] == 112 && odp[3]== 49) 214 if (odp[2] == 'o')
204 { 215 {
-   216 set_pwm1_duty(500);
-   217 set_pwm2_duty(500);
-   218 Delay_ms(10000);
-   219 fprintf(VRTULE,"[ERROR[e[["); // " ERROR 4 "
-   220 Delay_ms(2000);
-   221 fprintf(VRTULE,"[ERROR[e[["); // " ERROR 4 "
-   222 Delay_ms(2000);
-   223 fprintf(VRTULE,"[OPAKUJTE["); // " OPAKUJTE "
-   224 Delay_ms(2000);
205 fprintf(VRTULE,""); 225 fprintf(VRTULE,"[OPAKUJTE[");
206 } 226 Delay_ms(2000);
207   -  
208 if (odp[0] == 97 && odp[1] == 104 && odp[2] == 111 && odp[3]== 106) 227 fprintf(VRTULE,"[[VOLBU[[["); // " VOLBU "
209 { 228 Delay_ms(2000);
210 fprintf(VRTULE,""); 229 fprintf(VRTULE,"[[VOLBU[[[");
-   230 Delay_ms(3000);
-   231 set_pwm1_duty(0);
-   232 set_pwm2_duty(0);
211 } 233 }
212 } 234 }
213 /* read_time(); 235 read_time();
214 time=strtoul(odp,&ptr,10); 236 time=strtoul(odp,&ptr,10);
215 if((time >= 30 && time <= 35) || (time >= 0 && time <= 5)) 237 if((time >= 30 && time <= 35) || (time >= 0 && time <= 5))
216 { 238 {
217 set_pwm1_duty(500); 239 set_pwm1_duty(500);
218 set_pwm2_duty(500); 240 set_pwm2_duty(500);
219 } 241 }
220 else 242 else
221 { 243 {
222 set_pwm1_duty(0); 244 set_pwm1_duty(0);
223 set_pwm2_duty(0); 245 set_pwm2_duty(0);
224 }*/ 246 }
225   247  
226 delay_ms(1000); 248 delay_ms(1000);
227 } 249 }
228 } 250 }