Quote:
Originally Posted by Kingofl337
Code:
for ( x = 0 ; byteswaiting == x ; x++ )
This for line contains no magic I just threw this together in a rush.
|
Did you test the program you posted? Does it do what you think it's supposed to? If there's nothing unobvious about this line of code, then it looks to me like its only effect is to waste time. If you intended for this example to help me, I must disappoint you. It raises more questions than it answers.
I won't apologize for sounding frustrated here, because I
am frustrated.
Quote:
|
My function is in main() because that was the only function of the whole program. I wrote it in VEX without a competition template in FRC it's called a Standalone Project in the File menu.
|
I'm afraid that's not going to be very useful for me. I'm not trying to communicate with a VEX system, and my goal is to use serial port I/O in a competition program.
I don't yet fully regret making the decision to use EasyC this year, but I'm getting close. As I keep finding out, simple stuff is simple, but anything that doesn't fit the predefined blocks seems several times more difficult than straight C coding. If I keep running into these roadblocks I'm going to have to tell our software group to throw away everything we've done so far and go back to the MPLAB environment before the month is out.