Glad that I had my second cup of coffee before I watched this video. Yes it is technical but you did a good job of explaining the process. This is a great feature to add to the IoTT stable. Once you get the higher current motor driver working, I just might consider replacing my NCE PowerHouse system with my Red Hat. All of these features and it’s open source concept make it a very versatile product. Perfect for upgrading DCC. Love what you are doing Hans! Please keep it coming!
Hi Hans. Yes exactly. As an ex electronics engineer I used to design sampling systems and one of the golden rules is that you need to sample at at least twice the frequency of the waveform in question to get meaningful results as determined by a fellow named Nyquist. .....................John
Excellent, but complex, obviously. Don't forget that DCC-EX is also planning on adding support for multiple power districts, and that implementation will probably require more work for current measurements. With the base system, 2 current gauges makes sense, but with more than 2 power districts, external metering would be more practical in use. Those external meters obviously could be in JMRI, but physical meters driven by a wireless microcontroller placed around the layout sounds like a project that you might consider. Using BT LE instead of WIFI would make more sense because it would negate the need for complicated configurations. You continue to impress the engineer in me. Your ability surpasses what I can do by an embarrasing level. I can get things done by brute force software, but your soluitions are elegent, if not too complex.
Thanks. For me, the aha-effect really came when I recognized that the current measurement input needs to be treated as periodic signal and Fourier rules would apply. From then on it was just application of what I learned 40 years ago about periodic signals. It still worked ;-) DCC EX will have 16 analog inputs in the future, and I guess all of them could be used to measure H bridge current. We will see how to deal with that as it becomes more clear what the DCC EX software will support. What is already clear is that the timing of the sampling will dramatically improve at it will be driven from the timer interrupt. That's a big plus for the precision of the meters.
Hans ... a very thorough, thoughtful, and appreciated video regarding DCC-EX current measurement. In addition to a loco(s) running on the track, a user might have one or more lighted cars ... and/or ... one or more stationary decoders connected to the track. Does the presence of either of these affect the current measurement? Would a current measurement as you described in this video include these? Thanks for your attention ... all the best.
Thanks. Yes, I did not show that in the video, you switch the headlights of the locomotive on, the meter goes up 100mA. And yes, it measures the total current that goes out from the driver. For the video I had to disconnect some current sensor modules as they are powered from track and lead to a current consumption while no loco was moving.
@@IoTT Thanks for your reply. You gave me a new winter project!!! Bought a hardware DCC power meter, but never liked it. Just wondering ... if the DCC-EX team expands hardware to include an ESP32 of some sort, that should help your power measurement method ... at least I think it would.
That depends what the ESP32 is used for, we will have to see. What definitively helps is making the sampling part of the timer interrupt because it makes the sampling interval much more stable. The quality of the current measurement will increase.
Hans, this is Absolutely fascinating. The whole project has certainly come a long way. Well done.
Thank you.
Glad that I had my second cup of coffee before I watched this video. Yes it is technical but you did a good job of explaining the process. This is a great feature to add to the IoTT stable. Once you get the higher current motor driver working, I just might consider replacing my NCE PowerHouse system with my Red Hat. All of these features and it’s open source concept make it a very versatile product. Perfect for upgrading DCC. Love what you are doing Hans! Please keep it coming!
Thanks. Unfortunately, the IBT-2 is somewhat a different animal. We will see what's possible.
@@IoTT Yes, I can see that although, with your skills, I can see you succeeding where others have failed. I will patiently wait.
Hi Hans. Yes exactly. As an ex electronics engineer I used to design sampling systems and one of the golden rules is that you need to sample at at least twice the frequency of the waveform in question to get meaningful results as determined by a fellow named Nyquist. .....................John
Yep. Fourier and Nyquist rate. There's a reason they teach you that in EE schools ;-)
Excellent, but complex, obviously. Don't forget that DCC-EX is also planning on adding support for multiple power districts, and that implementation will probably require more work for current measurements.
With the base system, 2 current gauges makes sense, but with more than 2 power districts, external metering would be more practical in use. Those external meters obviously could be in JMRI, but physical meters driven by a wireless microcontroller placed around the layout sounds like a project that you might consider. Using BT LE instead of WIFI would make more sense because it would negate the need for complicated configurations.
You continue to impress the engineer in me. Your ability surpasses what I can do by an embarrasing level. I can get things done by brute force software, but your soluitions are elegent, if not too complex.
Thanks. For me, the aha-effect really came when I recognized that the current measurement input needs to be treated as periodic signal and Fourier rules would apply. From then on it was just application of what I learned 40 years ago about periodic signals. It still worked ;-)
DCC EX will have 16 analog inputs in the future, and I guess all of them could be used to measure H bridge current. We will see how to deal with that as it becomes more clear what the DCC EX software will support. What is already clear is that the timing of the sampling will dramatically improve at it will be driven from the timer interrupt. That's a big plus for the precision of the meters.
Hey, you've got my same bench supply.
It's a pretty good one for the price.
Hans ... a very thorough, thoughtful, and appreciated video regarding DCC-EX current measurement. In addition to a loco(s) running on the track, a user might have one or more lighted cars ... and/or ... one or more stationary decoders connected to the track. Does the presence of either of these affect the current measurement? Would a current measurement as you described in this video include these? Thanks for your attention ... all the best.
Thanks. Yes, I did not show that in the video, you switch the headlights of the locomotive on, the meter goes up 100mA. And yes, it measures the total current that goes out from the driver. For the video I had to disconnect some current sensor modules as they are powered from track and lead to a current consumption while no loco was moving.
@@IoTT Thanks for your reply. You gave me a new winter project!!! Bought a hardware DCC power meter, but never liked it. Just wondering ... if the DCC-EX team expands hardware to include an ESP32 of some sort, that should help your power measurement method ... at least I think it would.
That depends what the ESP32 is used for, we will have to see. What definitively helps is making the sampling part of the timer interrupt because it makes the sampling interval much more stable. The quality of the current measurement will increase.
i’ll be honest, i accidentally clicked on this video and i have no idea what’s going on but it’s kinda interesting 🙂
Stuff happens ;-)) Thanks for watching and feel free to come back, maybe even on purpose ;-)