digitalRead() will probably not be fast enough as it can take several microseconds to execute. You should use the AVR registers directly so you get the tightest loop possible. For example:
pinMode(2, INPUT); // configure pin 2 as an input
while (~PIND & (1 << PD2)) // loop here while pin 2 is low
;
It might be even better if you were to use interrupts for this application. You can use an external interrupt if you connect your signal to an external interrupt pin, or you could use a pin change interrupt, which is slightly more complicated and will result in an interrupt for both the rising and falling edge but is on every pin.
- Ben