You have probably seen our robot moving, walking, catching a ball or triggering an elevator. But have you ever stopped to think what happens behind all this? How do we get a mechanical and electronic system moving? And that's what we’re here to discuss!
After the robot is assembled and with the electronics ready, the programming division is responsible for bringing it to life!
Programming logic
Imagine this simple activity: replacing a light bulb. To do this, you need to see that the lamp has burned out, buy a new one, turn off the house circuit breaker, take a ladder, climb it and replace it.
This process is one of the examples of programming logic applied in our daily lives! It can be defined as a set of instructions for carrying out an activity, from basic to advanced
But how do we pass these instructions on to a computer, for example? That's what programming languages are for!!
Programming languages are used to communicate with the computer and turn it into a language that is understandable to the machine, because, by itself, it does not have the capacity to do something.
But, how is this transformation made to the computer’s comprehension? That’s simple! after the code is ready it is compiled and / or interpreted to the bytecode model. Don't be alarmed by the name, you have probably heard of it as binary code.
History of programming
The computer programming style we know today emerged from the 1950s with programming languages such as: FORTRAN, LISP and COBOL.
The first language was created between 1942 and 1946 by the German engineer and inventor of the world's first computer, Konrad Zuse (1910-1995), and was called Plankalkül. Before that, cardboard cards were used to build the code, which, when punched through, passed on an instruction to the machine.
It was only in the 70s that more innovative models were created, their language being more similar to those of today. It is also important to mention two languages that played fundamental roles in this period: Simula which was the first to incorporate the concept of classes and C, one of the first languages made for the programming of systems.
A evolução continuou crescente nos anos 80 com o surgimento de ramificações dessas linguagens, como Perl (recomendada para códigos com sobrecargas grandes) e C++ (criada a partir de C, ela é mais dinâmica e simples). Percebe-se que a partir dessa década as linguagens buscam se especializar em determinadas áreas de atuação, como criação de jogos e websites, movimentação de robôs, criação de sistemas…
However, it was with the arrival of the Internet in the 1990s that this variety became even greater, with the arrival of languages related to the Internet, such as Java (object-oriented), JavaScript (oriented to the interactivity of websites) and PHP (website building, among others).
As we have seen, programming is hidden in all electronic devices and is increasingly dynamic and simple in its writing and interpretation. Every year, languages incorporate new functions to facilitate the work of the programmer and their usefulness has become indispensable in our lives.
Java: a brief summary
The Java programming language is the most used language in our team!
It was created in 1995 by Sun Microsystems on a mission led by Canadian James Gosling. The team's goal was to create a language that ‘runs’ in any environment without the need for an electronic device
It is considered to be of a high level, that is, it has a form of writing closer to the programmer than to the computer and is one of the most famous and studied today. Its best known use is in the manufacture of applications for Android, but it is not limited to this area.
O famoso símbolo da linguagem é uma xícara de café pois os criadores queriam nomeá-la com aquilo que gostassem muito e pensaram em café, mas não queriam chamá-la de “coffee”. Então lembraram de uma gíria para café forte em inglês chamada ‘Java Coffee’ e a linguagem foi batizada como Java.
Programming in robotics
Now that you have a greater sense of what programming is, it will be easier to understand how we bring it to robotics!
As already mentioned, when using the Java programming language, we “translate” what we want the robot to do into a language understandable by the robot's “computer”.
Through this, we are able to implement other technologies that make our systems more intelligent, such as computer vision - responsible for giving eyes to our robot!
Got any questions? Leave it in the comments or send a message on our social media (@frc5800)!