A “Hello, World!” lesson is usually designed for beginners to learn new programming languages. In addition, A “Hello, world!” program is also used as a sanity test to make sure that a programming tool is properly installed and standard output hardware works well.
So let’s do a “Hello World” project with Mixly as the starting point of Arduino graphical programming tutorial and test the Arduino Serial port I/O function.
- OSOYOO UNO Board (Fully compatible with Arduino UNO rev.3) x 1
- USB Cable x 1
- PC x 1
Not much is needed for this lesson, Make sure you have a good quality syncing cable,do not pick a ‘charge only’ USB cable
Connect your OSOYOO UNO board to the Computer via a A to B USB cable,then double click the Mixly software icon on your desktop.
- Click the “SerialPort” block;
- Choose the “Serial baud rate” module;
- Drag the “Serial baud rate” module to the blank area, default baud rate is 9600 hz;
- Click the “SerialPort” block again;
- Choose the “Serial println” module;
- Drag the “Serial println” module under the “Serial baud rate” block , fit the bulge and combine two blocks together.
- Click the “Text” block;
- Choose the “hello” module;
- Drag the “hello” module to the position shown below and change the text to “Hello World!”(3);
This program will print “Hello World!” on the serial port.
- After programming is completed, you can click the “<" button to check the corresponding code on the right bar.
- Click “Save” after programming is done.
- Select the board type:
In this lesson, we are using a Uno board, so just select “Arduino/Genuino Uno” from drop-down menu (1);
- Select the serial port from the COM menu:
This is likely to be COM3 or higher (COM1 and COM2 are usually reserved for hardware serial ports). To find out, you can disconnect your Arduino board and re-open the menu; the entry that disappears should be the Arduino board. Reconnect the board and select that serial port.
- Upload the code. If the uploading fails, check board type and COM port setting in 1) 2) are all correct, also check USB cable type and connection is correct and then try again.
Finally, the status should change to ‘Upload success!’.
A few seconds after uploading finishes, you should see the TX LED on the board start to blink (in orange).
- Click the Serial Monitor button (1);
- Make sure the serial monitor’s COM port is corresponding to your Arduino port, and check if the serial monitor baud rate is same as your sketch setting.
- If you have successfully completed all the operations and procedures, you will see the Arduino serial continuously output the string “Hello World”.
Congratulations! You have graphically programmed a “hello world” project in your Arduino!