EasyManua.ls Logo

SunFounder GalaxyRVR - 3.4 Lesson 4: Mastering the TT Motor

Default Icon
120 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
SunFounder GalaxyRVR Kit for Arduino, Release 1.0
Just like a spell book, you can find all these spells and many more in the . The more spells you know,
the more exciting your Arduino adventures can be!
Comments: Our Secret Messages
We also have a secret language in coding, called comments. These are messages that we can write
in our code using // or /* */. The magic part? The Arduino completely ignores them! Its a great
place to leave notes for yourself or others to explain what the tricky parts of the code are doing.
Code Readability: Making Code Friendly
While you can write your code in any manner you want (for example, placing semicolons on a separate
line wont cause any errors), it’s important to keep in mind the readability of the code.
Just like writing a good story, the way we write code can make it either fun and easy or boring and
difficult to read. Here are some ways to make your code more friendly:
Use proper indentation to arrange your sentences into neat paragraphs. It helps the reader under-
stand where one section ends and another begins.
Use variable names that make sense. It’s like calling a character by a fitting name in a story.
Keep your functions small and simple, like short and sweet chapters in a book.
Leave comments for the tricky parts. It’s like leaving a footnote to explain a difficult word.
Remember, were not only coding for machines but also for humans, so let’s make sure our code tells a clear and
understandable story!
Step 7: Reflect and Improve
Taking a moment to reflect on our journey can provide us with insights that we might miss in the flurry of exploration.
Ask yourself:
What was the most interesting part of this Arduino adventure?
Were there any challenges along the way? How did you overcome them?
Could you explain to a friend what Arduino is, what the Arduino IDE does, or how to run Arduino code?
How would you describe your first Arduino programming experience?
What more do you want to learn about Arduino?
By thinking about these questions, you are deepening your understanding and preparing yourself for future explorations.
Always remember, there’s no “wrong” answer in reflection it’s your personal journey after all!
3.4 Lesson 4: Mastering the TT Motor
In the previous lessons, we explored Mars rovers, their suspension systems, and delved into knowledge about Arduino.
In this exciting course, we’ll explore the workings of motors, a key component that drives Mars rovers. We’ll understand
the principles that power these motors and learn to control them using SunFounder R3 board and a GalaxyRVR Shield.
By the end of this course, you’ll have a solid understanding of motor operation and hands-on experience in motor
control.
Lets dive in!
Note: If you are learning this course after fully assembling the GalaxyRVR, you need to move this switch to the right
before uploading the code.
32 Chapter 3. Course Mode

Related product manuals