Question: write a C function void waitForSignature ( unsingned cher pinNum , unsigned int min , unsigned int max ) where pinNum is a number from

write a C function void waitForSignature ( unsingned cher pinNum , unsigned int min , unsigned int max ) where pinNum is a number from 0to 7 representing PD0 toPD7 . The function simply waits for a pulse of width in the range (min - max ) appar on pinNum (in port d ) for example . waitForSignature (5 , 20 , 90 ) means wait for a pulse of width in the range 20 - 90 millisecond to appear on pin PD5 .

a . use the timer to measure time . you do not need to setup the timer , Assume you have a function called startTimer() which initializes the time to zero . Also assume a function call stopTimer() which will return the number of CPU clocks ( Assume Clock speed is 16MHZ ) since startTimer () function was called

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!