Basically I'm trying to use a computer to control a model railroad. I have one motor controller (http://www.phidgets.com/products.php?product_id=1060) with 2 outputs for controlling 2 blocks of track. The output is PWM and it drives the locomotive whithout a problem. However when the locomotive crosses from one segment of track to the other, it almost doubles its speed. Once it has crossed over with all wheels, the speed returns to normal. I believe this happens because when the locomotive is crossing the gap, it puts the 2 outputs in parralel, and the PWM outputs are somehow "superimposed", and so a double duty cycle results for the composed PWM signal.
My question is how can I convert the PWM signal to pure analogue DC voltage on both outputs. Basically I'm looking for some sort of "RC filter", but in this case the PWM signal is powerful enough to drive the motor just fine; if I add even a small resistor in a RC filter, then already the voltage drops significantly, and the locomotive moves considerably slower. Also i would like to keep this circuit because it has an USB interface and a good API behind.
My question is how can I convert the PWM signal to pure analogue DC voltage on both outputs. Basically I'm looking for some sort of "RC filter", but in this case the PWM signal is powerful enough to drive the motor just fine; if I add even a small resistor in a RC filter, then already the voltage drops significantly, and the locomotive moves considerably slower. Also i would like to keep this circuit because it has an USB interface and a good API behind.