The application provides a
data synchronization method and device for a master side and a slave side in a power supply
system. The method comprises the following steps: when a
master controller detects a trigger event, recording an
event trigger time, generating a synchronization instruction
package containing a
total delay duration, and sending the synchronization instruction
package to a slave controller; when the slave controller receives the synchronization instruction
package, recording an instruction receiving time, analyzing and obtaining the
total delay duration, calculating a synchronization time according to the difference between the instruction receiving time and the
total delay duration, determining a target time interval according to the synchronization time and an effective data duration, and extracting slave side measurement data in the target time interval; wherein the synchronization time and the
event trigger time are the same time. The method introduces total
delay duration compensation, realizes data
backtracking alignment, accurately eliminates the data communication
delay of both sides, ensures the accurate alignment of the recorded data on the time axis of both sides, and is compatible with the existing
system without relying on the addition of a hardware interface or physical circuit modification.