Hi Murali-
This problem is somewhat difficult to implement but can be accomplished using both of the counters on your board.
For the counter that will not be delayed you can simply create the pulse train of user-specified pulse width as you have done in your code above. To generate the delayed pulse train you will need to generate single pulses of appropriate pulse width and with appropriate delays set. You will then trigger these single pulses from the original signal and the specified delay will result in the delayed operation you desire. I'm not sure exactly what you mean by a 90 degree shift, but if you are attempting to delay 0.25 periods this delay will be easy to calculate based on your main constant output frequency.
The example "DigPulse.prj" in the NI Example Finder (Help>Find Examples in CVI) under Hardware Input and Output>DAQmx>Generating Digital Pulses shows how to create a pulse of specified delay on a counter output line. I have added the following line in the Generate callback to specify triggering for the PFI0 line:
DAQmxErrChk (DAQmxCreateCOPulseChanTime(taskHandle,chan,"",DAQmx_Val_Seconds,idle,initialdelay,lowtime,hightime));
DAQmxErrChk (DAQmxCfgDigEdgeStartTrig (taskHandle, "PFI0", DAQmx_Val_Rising));
You will need to find an available PFI line for your device and route the first counter output to this line externally.
Best regards-
Tom W
National Instruments