Easy C Flywheel RPM??

How would i input the flywheel RPM from Robot C into Easy C??? I cant figure out how to even input calculations.

I have been trying to figure that out as well.

same

Set the encoder measurement as a variable and use assignment(i think) to do your calculations and stuff.
You could also use the text editor to type it up.

I use easy C mainly because almost everyone in my region uses easy C and the way I calculate rpm is that I set two variables for the same encoder (Enc_Old and Enc_New) and between those “get_encoders” you put a delay(Wait) of 20ms-50ms. After this step you use an assignment to a variable called “raw_encoder_ticks” to start converting your value into rpm. You can use multiple assignments to calculate rpm but in this case I’m only going to use 2. First we find the difference in ticks of the “Enc_Old” and “Enc_New”. Next step we start the dimensional analysis and divide the difference in ticks by the ms we used (in the example 50ms) and multiply it by 1000 to convert it into seconds and then multiply it by 60 to turn it into minutes. We then divide the result according to the type of encoder( optical shaft encoder is 360 ticks per revolution I think). At the end it should look like this…
Get_encoder= Enc_Old(1)
WaitTime=50ms
Get_encoder=Enc_New(1)
raw_encoder_ticks= (Enc_New- Enc_Old)
Rpm=(((raw_encoder_ticks/50)100060)/360)
I’m not used to writing the code so I’am awarethere are errors in the order of the encoder ports and stuff.

I have noticed a lot of teams use EasyC… is there any particular reason?

Some people just start with it and never change. Most of the teams I talk to use ROBOTC so it is definitely a matter sampling bias either way. I would say that the most competitive teams all use ROBOTC.

Both me and the programmer for 6430B use ROBOTC, I was just wondering if there was a benefit.

EasyC is graphical, meaning it uses drag and drop blocks, so it’s easier to learn. This makes it great for new teams, or teams that don’t have people who enjoy programming. However, it does have limitations. For example, RobotC makes advanced math far simpler, you don’t need to search for blocks on the side (imagine using RobotC with a mouse, but no keyboard, and that’s basically a graphical language), and RobotC makes learning other languages easier, since it becomes a matter of just memorizing the functions. I would definitely recommend RobotC to people who already know another programming language, but EasyC is great for teams that don’t have people who want to learn programming.

I’m currently (got roped into it) teaching ROBOTC graphical to 2 kids that are 7. Not as hard as you would imagine to do simple stuff. I just really wish they knew multiplication. Dam you Nevada for being 49th in country for education.