how to give delay of 1 nano seconds

AWOL:

1 nHz timing resolution requires a 1GHz clock

Don't be silly - 1nHz is one cycle every 31 years eight and-a-half months.
It's not a crystal you need, it's a calendar.

It took me a while before the laugh emerged :slight_smile:

In any case to get a calculated time measured to +/- 1 nS ns I reckon you would need a 4GHz or maybe 10GHz clock. Almost certainly the OP can't afford the oscilloscope that would allow him to verify his timing.

...R