Sorry, I can’t answer in the forum you assigned your thread to because it can only be replied to by RobotC staff. As for your problem, would it be possible for you to post the code in question? It would be a lot easier to dissect the problem if we could see what was actually going on.
As far as your programming routine, it seems to be doing everything it should. I suspect the issue probably lies with how you reset the encoder values, but I can’t tell for sure without seeing the actual code.
Would it be possible to also provide the turnRight and turnLeft functions? That’s probably where your issue is, then. Perhaps not using absolute value or something like that. Everything else looks fine.
the turnLeft and turnRight functions are a part of natural language 2.0 so i did not create them. In robotc if you go to the tab at the top labeled robot it should open a drop down menu with a tab labeled platform type where you can select natural language 2.0. once you have done this your text functions library should change where you can then find turnLeft and turnRight
also i should note that before creating the 15-second autonomous i had no issue with setting it to turn either direction. the issue only arose when i had it turn two separate times
Alright so I took a look at the RobotC code for Natural Language 2.0, and let’s just say their functions for turning are interesting to say the least. I think what may be causing an issue is that your second turn says to turn 460 degrees. I’ve never worked with these functions as the most optimal thing to do is just create your own (because you can control how they work), but it may be the fact that you’re telling it to turn more than 360 degrees. Try setting it to lower than 360 and see if it does anything then. If not, I’ll have to take a closer look at their functions. They’re monsters to dissect, though.
the encoders are not on the same axle or shaft as the drive wheels being as we added them so late in the season and did not have room for them so we had to improvise. the way we have it setup is we have a 60 tooth gear on the axle with the drive wheel on each side of the drive. then the 60 tooth gear is touching another 60 tooth gear which is on the axle with the encoder. its hard to explain but this causes the sensor readings to not be what they should e.g. 360 is not a circle. Well anyway thank you for your time and help. it is much appreciated