Simulate tachometer varying refresh rate
3 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi,
I am simulating a DC motor controller. The real application will use an optical tachometer, where the measured period of the pulses is used to calculate the motors angular velocity. Since the angular velcoity is calculated with every pulse width measure, the refresh rate of the angular velocity measurement will vary, ie higher refresh rate at higher angular velocity and vice-versa.
Is there a way to simulate this on mathlab?
Thanks
0 commentaires
Réponses (1)
Mathieu NOE
le 17 Mar 2022
hello
why not using a counter ? sampled at a high (fix) frequency rate.
This simulink code attached is a demo (Fs = 100 kHz, adapt to your needs)
the output is the frequency (or RPM if you prefer, multiply by 60 the freq output)
All the best
2 commentaires
Mathieu NOE
le 18 Mar 2022
hello
a techometer is always built around a (fast) counter - so it's fixed sampling rate.
a variable step size simulation / solver is IMHO just a simulation / computation time saving tool
if you want to turn that into a prototype control system is gonna be anyway fixed sampling process.
so IMHO your code could / should have multiple rates ( fix ) as this is going to be how it will work in "real" .
Voir également
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!