| ??? 05/06/03 21:45 Read: times |
#44923 - only bit monitoring software Responding to: ???'s previous message |
erik malund,
i think you are some one i know...coz every one reply me with a good mood but you always rudely reply..why ... if you just guide me or write a code for the following condition this will help me to learn ...instead of saying other things just guide me a example...i have seen the bible and swaer its really hard for me to under stand this as i have no teacher or any one who has done work on this assembly ... if i child is not understanding by reading text book a teacher alway provide some example which helps him to learn in future... please consider the following:-Suppose, I have connected Four Door Sensing Device and there out -put is connected with controller P2.0 P2.1 P2.2 P2.3 Now when ever any door is opened a siren starts to ring for 6 seconds and under two conditions it is turned off: 1) if no one close the door up till 6 seconds, or 2) the door is closed before 6 seconds. using crystal of 11.05KOH in designing software in assembly for 89c52 i only don't understand how to write code for monitoring all doors , if any one of the door is opened also the controller should perform the siren task but also keep on monitoring other ports if a high signals comes on them.. suppose high comes on P2.0 , sirens starts to ring but at the same time or within 6 seconds High also comes on P2.1 and P2.3 then also the controller should starts the siren for these pins and at the same time look which door is need to be disconnected from the siren considering the above mentioned conditions. I know i have to use timer to keep on monitoring the bits as fast as possible, lets say 10 micro-seconds... after every 10 seconds controller controller should see if any bit is set or not. i only need help for the monitoring part...? also if i use timer 0 for monitoring and timer 1 for generating the siren for 6 seconds, can the same timer 1 interrupt be use for the above four doors ... Like if a door is opened and the next door is opened after 3 seconds of the first door then also the siren should provide same timing for 6 seconds to all doors in case if all doors are opened at the different times... what i mean to ask is will the same timer 1 will provide 6 seconds interval for different door opening conditions...or is there any other technqiue.. looking to get help in code for monitoring the pins...only this monitoring using timer is causing the trouble...a little example will really help me through |



