what input pin is it using?

sounds like more code i dont understand, or know how to write lol currently havent done any testing but i do have a sensor and trigger wheel to play around with.
basically this is for a 4wd system in a car i have written a code already to control it manually but i want to now be able to conrtol it automatically so to look at the 2 rear wheel speeds and pick the fastest travelling one and compare it to the speed of the propshaft and if it is going slower execute it into another piece of code to lock the diff up.