The jdelay library provides busy delay routines. Each routine delays the amount of time indicated by its name, multiplied by its argument.
The busy delay routines require a clock frequency of either 10MHz or 4MHz.
These delay routines are accurate to a few percent. For more accuracy interval delays should be used.
The delay_1us (which is the most accurate) has a minimum delay time (3.6mS for 10MHz and 9mS for 4MHz) and a step (2mS for 10MHz, 4mS for 4MHz), and rounds the delay to the nearest possible value.
procedure delay_1us( byte in x = 1 )
procedure delay_2us( byte in x = 1 )
procedure delay_5us( byte in x = 1 )
procedure delay_10us( byte in x = 1 )
procedure delay_20us( byte in x = 1 )
procedure delay_50us( byte in x = 1 )
procedure delay_100us( byte in x = 1 )
procedure delay_200us( byte in x = 1 )
procedure delay_500us( byte in x = 1 )
procedure delay_1ms( byte in x = 1 )
procedure delay_2ms( byte in x = 1 )
procedure delay_5ms( byte in x = 1 )
procedure delay_10ms( byte in x = 1 )
procedure delay_20ms( byte in x = 1 )
procedure delay_50ms( byte in x = 1 )
procedure delay_100ms( byte in x = 1 )
procedure delay_200ms( byte in x = 1 )
procedure delay_500ms( byte in x = 1 )
procedure delay_1s( byte in x = 1 )
procedure delay_2s( byte in x = 1 )
procedure delay_5s( byte in x = 1 )