This paper proposes a white-box approach for identifying the parameters of DC-DC buck and boost switch mode power converters. It is based on discretizing the differential equations that describe the dynamic behavior of the converters. From the discretized equations and experimental data, the parameters of the converters are identified, thus obtaining both the values of the passive components and the transfer function coefficients of the controller. To this end, steady state and transient experimental signals are analyzed, including the input and output voltages and the inductor and output currents. To determine the accuracy of the proposed method, once the parameters are identified, a simulation with the identified parameters of the converter is run and compared with experimental signals. Such results show the accuracy and feasibility of the approach proposed in this work, which can be extended to other converters and electrical and electronic devices.