First let me say what a blast electronics is, this coming from somebody who's really just getting into it. The Boe-Bot kit is amazing and I'm starting to get my head around programming but I have a question I was hoping somebody could shed some light on.
it's regarding the exercise Roaming With Whiskers and the BS2 code. I would like to add a servo-ramping up routine to the Forward, left, right, and back subroutines. After all Parallax recommends doing this to extend the life of the servos. I'm going to assume that you know which exercises I’m talking about as I haven't included any code in this post.
So i cut and paste the code from the ramping up BS2 exercise program and I put it into the forward_pulse subroutine. It works, but once it ramps up and the Pulse_Count variable hits 100, it starts all over again. so in other words it stops for about a half a second and ramps up again.
So i'm thinking what I need here is an IF...THEN statement that will determine that once the servos are at full speed forward (650,850) it keeps it at that speed until one of the whiskers is pressed and the respective subroutine is executed.
So I guess I'm asking: Is this the correct approach with a conditional IF...THEN, or am I over thinking it. I'd like to figure it out myself but if anyone has a few hints to move me a long that would be great.