By setting small electromechanical systems such as wireless sensors in the traffic environment to realize traffic condition monitoring, system management and facility health monitoring, etc., the traffic system can be operated in a safer, orderly and efficient manner. However, how to power these widely distributed small electromechanical systems? This paper proposes a magnetic coupling road energy harvesting design to collect vehicle rolling energy and convert it into electricity. The device transmits non-contact energy through magnetic coupling, which reduces the impact on the device and makes it have a good seal, so as to improve the robustness. The vehicle rolling excitation is converted into high-speed one-way rotation through the up-frequency gear and the ratchet mechanism, and the reversing gear mechanism can continue to collect the reset elastic potential energy, which improves the output power of the device. Based on the working principle of the system, the electromechanical coupling dynamics model is established. The numerical simulation explored the impact of key design parameters such as the limit distance of the speed bump and the stiffness of the resetting spring on the dynamics and electrical performance of the energy harvesting system. When the vehicle speed is 50 km/h, the maximum output voltage of the system is 76.28 V and the maximum power is 59.94 W. The magnetic coupling road energy harvesting device can become an important part of the intelligent traffic system in future, harvesting the energy of the traffic environment and providing sustainable green carbon-free power for small and medium electromechanical systems in the traffic environment.