Hi !
I am using the PSIM software interrupt to detect rising and falling edges of a signal.
The DSP I am working with is a TI f28335.
In the event of rising / falling edge I am entering its routine via subcircuit.
The routine goal is to calculate the time (and hence the phase) between two rising or tho falling edges of two separated signals.
Inside the routine I am using a simplified C block to calculate the time difference but for the moment I struggle to obtain this desired time difference due to the inability to get the absolute time at which interrupt occured.
In PSIM simulation without interrupts I could just use the "t" parameter offered by the C block, or by using an integrator summing up the time passed, but these are not accessible using the interrupt block in the simulation.
I would like to know how can I obtain that time, what tools do I have ?
any help would be beneficial,
Thanks !