Here I have adapted it to use the two delays the protocol requires. Although type 0 transfers have the same timing for each delay, other transfers need different delays so I am moving the loading of the counter outside the delay loop so that it can be set individually as required.