Mixly: A Powerful Graphical Programming Tool for Arduino

Mixly: A Powerful Graphical Programming Tool for Arduino

The open-source strategy of Arduino hardware and software has quickly attracted a large number of loyal supporters, among whom the geeks have developed dozens of different types of hardware boards according to open protocols, which in turn expanded the application scenarios of Arduino. With this good interaction, Arduino continues to improve and has undoubtedly become the preferred platform for geek enthusiasts due to its continuously enriched extensibility and applicability.

An excellent and open platform also attracts many outstanding manufacturers, whether it is makerblock or mCookie, their products can be programmed based on Arduino to achieve creative functions.

Arduino is getting more and more popular, and the number of people wanting to learn is also increasing. However, when opening the official programming software Arduino IDE and viewing the examples that come with the program, after quickly browsing through lines of text code and feeling confused, one might feel overwhelmed. This is to become a programmer, so they silently close the program again.

As a programming platform, text programming for Arduino is not an easy hurdle for many people without programming basics.

Fortunately, we have Mixly, and programming is really as simple as building blocks.

Introduction

Mixly is a free and open-source graphical Arduino programming software developed by Professor Fu Qian’s team from the Maker Education Laboratory of Beijing Normal University based on Google’s Blockly graphical programming framework.

Mixly: A Powerful Graphical Programming Tool for Arduino

Advantages

When it comes to graphical programming software for Arduino, the first thing that comes to mind is the official release of Ardublock and S4A (Scratch for Arduino) based on Scratch.

Mixly: A Powerful Graphical Programming Tool for ArduinoComparison of S4A, Ardublock, and Mixly

Unable to run offline is a major flaw of S4A(Note 1), we will exclude it. So why do we choose the third-party Mixly instead of the official Ardublock?

Mixly: A Powerful Graphical Programming Tool for Arduino Comparison of Ardublock and Mixly

Mixly is powerful enough to be irresistible.

Interface

Let’s take a look at the interface of Mixly:

Mixly: A Powerful Graphical Programming Tool for Arduino

The programming interface is simple and clear.

The left area is the Blocks classification area; the middle is the programming area; the rightmost icons correspond to centering the program, enlarging, reducing display, and deleting program blocks; the bottom gray toolbar is the function menu; the bottommost is the information display area.

Powerful preset modules

In addition to common if/else conditional statements, for/while loops, mathematical operations, port read/write, boolean operations, and other basic program operations, Mixly also supports:

1. Complete types of variable declarations:

Mixly: A Powerful Graphical Programming Tool for Arduino

2. Complete subroutines (can return data):

Mixly: A Powerful Graphical Programming Tool for Arduino

3. Array/list support:

Mixly: A Powerful Graphical Programming Tool for Arduino

4. Trigger interrupts and timer interrupts:

Mixly: A Powerful Graphical Programming Tool for Arduino

5. Serial communication (supports soft serial!):

Mixly: A Powerful Graphical Programming Tool for Arduino

6. Pulse detection:

Mixly: A Powerful Graphical Programming Tool for Arduino

7. Fan-out:

Mixly: A Powerful Graphical Programming Tool for Arduino

Mixly is rich in features that are hard to refuse.

Extensions

Similar to Ardublock, Mixly also supports a series of rich corporate library extensions such as Makeblock, DFroboot, microduino, seeedstudio.

Mixly: A Powerful Graphical Programming Tool for Arduino

Rich extension libraries

In actual use, it is found that although Ardublock’s product library has a large quantity, there may be cases where the components of various entry kits are incomplete or mismatched. For graphical programming, if there is no corresponding component block, the component cannot be used, directly limiting the user’s creative realization. However, although Mixly’s corporate library is small in number, the components in various entry kits are complete, making it very suitable for beginners.

Smooth operation

Mixly: A Powerful Graphical Programming Tool for ArduinoComparison of right-click options between Mixly (left) and Ardublock (right)

  1. Mixly supports four ways to delete program blocks: dragging them out of the programming window, dragging them to the trash can, using the delete key, and right-clicking to delete. Ardublock only supports the first method;

  2. Mixly supports freezing unused blocks with disable, and frozen blocks do not generate code; when you need to compare test different ideas or write multiple comparison programs at once, it feels great!

    Mixly: A Powerful Graphical Programming Tool for ArduinoThe left is the normal program, the right is the frozen program, which will not generate Arduino code

  3. Supports program folding

    When writing long programs or programs containing different subroutine modules, the completed program can be folded, making it clear and easy to read.

    Mixly: A Powerful Graphical Programming Tool for ArduinoThe upper right corner shows the folded program

Examples

After all this, let’s write a program to practice hands-on and create a Useless machine.

The so-called Useless machine is that when you turn on the switch, the machine turns off the switch by itself, cycling back and forth, which is indeed Useless.

Required components:

Arduino UNO ×1

Arduino Shield ×1

Servo ×1

Button ×1

Green LED ×1

Mixly: A Powerful Graphical Programming Tool for Arduino

Component diagram

Using Mixly programming, drag and drop various blocks into the programming area, set ports, loops, and complete programming:

Mixly: A Powerful Graphical Programming Tool for ArduinoMixly program and the generated Arduino code

After uploading to the Arduino board, it runs like this:

Mixly: A Powerful Graphical Programming Tool for Arduino

A tool for spending time alone.

Conclusion

Mixly is currently the most feature-rich and smoothest graphical programming software for Arduino, which can almost replace the Arduino IDE programming tool(Note 2). If you want to get started with Arduino without writing code, then try Mixly!

Follow the public account and reply “Mixly” to get the program download address.

Note 1: When Scratch was initially designed, it did not consider communication with hardware, and the emergence of S4A allowed Scratch to communicate with Arduino through serial ports. This means that S4A acts as an information intermediary throughout the process. Scratch issues control commands, and the program pre-written on the Arduino board parses the commands and executes them, returning data. Therefore, programs written in S4A stop running when the Scratch software is closed and cannot run independently on the Arduino board.

The domestic manufacturer MakerBlock developed mBlock based on Scratch, which can achieve similar Scratch programming, adding its own product component control modules, and can generate Arduino code in real-time and upload the generated code to the Arduino board. Considering the compatibility of many brands of Arduino peripheral products, it was not included in the comparison.

Note 2: Almost is to express rigor. The programs in the previous DM lab topic “When LEGO Meets Arduino” can all be completed by Mixly.

Previous article links

  1. “When LEGO Meets Arduino: How to Control LEGO Components Externally”

  2. “When LEGO Meets Arduino: LEGO PM2.5 Detector”

  3. “When LEGO Meets Arduino: LEGO Wants You to Eat~”

  4. “When LEGO Meets Arduino: Infrared Control for Proximity Control”

  5. “When LEGO Meets Arduino: Bluetooth Control for Proximity Control”

  6. “To Listen to Christmas Vinyl Records, We DIYed a Turntable”

  7. “Wearable and Washable Arduino–Lilypad & Flora”

Mixly: A Powerful Graphical Programming Tool for Arduino

Science and Technology Classroom

Online Learning Platform for Science and Technology Instructors

WeChat ID: sciclass

Mixly: A Powerful Graphical Programming Tool for Arduino

Leave a Comment

×