RaceCar timer Problem
Hello all,
I am doing a project for a derby which has four lanes and the circuit will detect the car and give it a place in the race·then display it.
I am just playing around with the detection portion of the code and I can not get it to detect one lane.
The way I have wrote the code it should stay in the main loop and wait for one of the lanes to detect the car.
Then its suppose to go into a subroutine that gives its position and then to display (which right now I'm using the debug).
Now·the problem with my code is that if ANY input goes low then all lanes are displaying the same Rank without them even being triggered.
I thought that by creating an integer with the names PlaceXX = Rank for each lane would separate them but it still only displays all the lanes
any Input would be Greatly appreciated
Also I keep going back to the Parallax Tutorial on Keypads.
I am doing a project for a derby which has four lanes and the circuit will detect the car and give it a place in the race·then display it.
I am just playing around with the detection portion of the code and I can not get it to detect one lane.
The way I have wrote the code it should stay in the main loop and wait for one of the lanes to detect the car.
Then its suppose to go into a subroutine that gives its position and then to display (which right now I'm using the debug).
Now·the problem with my code is that if ANY input goes low then all lanes are displaying the same Rank without them even being triggered.
I thought that by creating an integer with the names PlaceXX = Rank for each lane would separate them but it still only displays all the lanes
any Input would be Greatly appreciated
Also I keep going back to the Parallax Tutorial on Keypads.
bs2
![](/plugins/FileUpload/images/file.png)
786B
Comments
Since all your places display the variable "rank" they will all be the same. You need to display place1 for lane1 and place2 for lane2 and so on.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen