cbqmp27 Posted August 15, 2020 Posted August 15, 2020 Ok, I’m new here but not new to Lego. However, I am converting, slowly to Powered Up for use with my trains. Like many of you seem to do, I would like to have a train that has an engine at each end so that I can control them with ONE throttle. The problem I have currently is how do I reverse the rear locomotive’s direction from within the Powered Up app? I’ve searched, I really have and nothing comes up that seems to answer how you do it. Perhaps I’m doing the searching wrong. Ok, my set up is two locomotives, each with their own hub. I know how to get both hubs to respond to one throttle in my app BUT how do I reverse the rear locomotive, so that it pushes while the front locomotive pulls? I use an iPhone with the Powered Up app and it works great for one motor. Any help is appreciated and forgive me if this has been asked before. Quote
Elphiel Posted August 15, 2020 Posted August 15, 2020 You simple give the motor negative values. So while one motor gets values from 1 to 100 the other will get values from -1 to -100. Use a variable for that. the throttle controls the variable. one motor gets the pure variable value while the other gets the value multiplied by -1. Quote
Lok24 Posted August 15, 2020 Posted August 15, 2020 (edited) Hi, put the value for the speed in a variable, then use a motor block with that variable as input, and a second, where you multiply this value by -1 Edited August 15, 2020 by Lok24 Quote
cbqmp27 Posted August 15, 2020 Author Posted August 15, 2020 Thank you to both Elphiel and Lok24 for your explanation. I realize now I have a lot more to do, I was hoping I could have used one of the already made apps (such as for the Passenger Train) to do what I wanted. So now, it’s off to “school” to learn another programming technique. Thanks again for your help. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.