wait instead of deay_ms
-
- Posts: 34
- Joined: 30 Aug 2011 07:03
wait instead of deay_ms
is there any command, function or routine, instead of delay_ms, in order to make code wait without sleep.
- janko.kaljevic
- Posts: 3565
- Joined: 16 Jun 2011 13:48
Re: wait instead of deay_ms
Hello,
Delay_ms function will make MCU loop until desired time interval pass.
Sleep will make your controller wake up at appropriate time.
And you should use any of those according to your needs.
From your post I can not conclude what exactly do you need.
Best regards.
Delay_ms function will make MCU loop until desired time interval pass.
Sleep will make your controller wake up at appropriate time.
And you should use any of those according to your needs.
From your post I can not conclude what exactly do you need.
Best regards.
-
- Posts: 34
- Joined: 30 Aug 2011 07:03
Re: wait instead of deay_ms
You know when we use delay_ms(2000), program wait or sleep during this 2 seconds, I do not know interrupt can still work during this 2 seconds.
Re: wait instead of deay_ms
You guys amaze me !!!
This is certainly something you can find the answer for yourself ,
Why dont you program you development board to blink a led in Timer1 interrupt and in the main code you use the delay and see if the led blink because if it does then
the interrupts happen regardless of the delay routine
OR READ the device documentation ,
This is certainly something you can find the answer for yourself ,
Why dont you program you development board to blink a led in Timer1 interrupt and in the main code you use the delay and see if the led blink because if it does then
the interrupts happen regardless of the delay routine
OR READ the device documentation ,
P.Erasmus
Saratov,Russia
--------------------------------------------------------------
Saratov,Russia
--------------------------------------------------------------