For lovers of the World of the Marvel, one of the great characters is Tony Stark: The Iron Man. With his capacity and financial richness, he was able to build an artificial intelligence system to recognize his voice commands and assist him in his work.
And for those who watch the movie and program the Arduino and other Microcontrollers, there is always the desire to create a Jarvis system, to automate the house and trigger various devices.
Thinking about this great desire, Jarvis Kryptonian Company has developed the Jarvis system, which can be used for automation with Arduino and several microcontrollers, through Artificial Intelligence and Voice Command.
And now, let's introduce the features of the Jarvis System with Arduino.
Automation with Jarvis and ArduinoThe Jarvis System allows you to register all the commands in Portuguese or Italian language. Figure 1 shows the Jarvis system options menu structure.
Through these options, we can configure the operation of our commands, but in this article, we will focus on learning the process of creating the commands for controlling a lamp with Jarvis and Arduino.
If you click in option number 1 - Automation controls (Controles de Automação) and as shown in Figure 2.
We will go to the automation command register screen in Figure 3 and we should write all the voice commands we want that Jarvis to recognize when we speak in the microphone.
In this screen, is possible to configure the serial port where our Arduino is connected to the computer and configure the baud rate of serial communication.
And now, we go analyze the regions 1, 2 and 3 enumerated in the yellow circle in the image.
In the area of the yellow circle 1, you will write the command you are going to speak for the Jarvis. Already, in the area of the yellow circle 2, you'll write the answer of the Jarvis when it recognizes your voice command.
Now, you can see in the area of yellow circle 3, that we should put the character that our Jarvis System will send for our Arduino when the voice command is recognized.
The Project of the Jarvis with ArduinoIn the project, we creating two commands. If our user speaks "Ligar Lâmpada!" (Turn on the lamp), the Jarvis send character '1' and the lamp will switch on or if the user speaks "Desligar Lâmpada" (Lamp off) the Jarvis send character '0' and the lamp will switch off.
And after these configurations, we should program our Arduino to receive the characters in its serial peripheral.
Arduino ProgrammingThe first step is to assemble the circuit of Figure 4. We will use the Arduino UNO connected to the USB of our computer, to receive data from the Jarvis System and to activate the relay, which is connected to the digital pin 13 of Arduino UNO.
After finishing the assembly of the circuit, we must record the code below in the Arduino.
char Jarvis = 0; //Variable for storing received data of Jarvis
void setup()
{
Serial.begin(9600); //Sets the data rate in bits per second (baud) for serial data transmission
pinMode(13, OUTPUT); //Sets digital pin 13 as output pin
}
void loop()
{
if(Serial.available() > 0) // Send data only when you receive data:
{
Jarvis = Serial.read(); //Read the incoming data and store it into variable data
if(data == '1')
{
//Verify if the received value of the Jarvis is equal to 1
digitalWrite(13, LOW); //If value is 1 then relay turns ON
}
if(data == '0')
{
Verify if the received value of the Jarvis is equal to 0
digitalWrite(13, HIGH); //If value is 0 then relay turns OFF
}
}
}
The code is very simple! When the user speaks to turn on the light bulb, Jarvis sends character 1 and the relay is triggered. If the user says to turn off the lamp, Jarvis sends character 0 and the relay will be turned off.
Our relay module operates at a low logic level.
News for Jarvis SystemThis article was used with Jarvis in the Portuguese version, and currently, there is Jarvis in Italian and Brazilian Portuguese languages.
Also, this year will be released the packages of languages English, Spanish, Portuguese of Portugal, German and French.
Now, see the video of Jarvis controlling an office.
Through this video is possible to see the Jarvis controlling the house.
AcknowledgmentSilícios Lab appreciates the support of PCBWay companies for supporting our electronic designs, the UsinaInfo Electronic Component Store and the Kryptonian Industries for creating the Jarvis system.
Through this system, we have been able to develop several types of automation with microcontrollers and Arduino.
The Silícios Lab thanks UTSOURCE to offer the electronic components.
Comments
Please log in or sign up to comment.