Short intro:
HMI is a human machine interface, usually in the shape of a panel with display and keypad for a human operator to interface with a machine, such as changing program parameters. A simple example a lot of us have done is an LCD and a few keys for a simple menu.
I have been on menus, LCDs, keypads, buttons, phi_prompt library etc. for ever (AKA just lately) and an idea hit me: My codes are still too difficult for newbies to use, which require some background in programming. What if I made interaction with LCD and keypad dead easy?!
So someone has to program all the software and connect all the hardware for others (any arduino project developer) to not be bothered with these details, and the same someone loads the program in an ATMEGA328 chip on a panel with hardware so there is no need for an arduino project developer to compile these long codes with libraries etc. The interface has to be intuitive and easy but expandable for veteran programmers.
So, tada! CLICK the picture for you tube videos:
This panel is powered by an ATMEGA328 running arduino bootloader for future firmware upgrade. The panel is connected to an arduino or other MCUs or a computer via serial. The firmware on the on board ATMEGA328 controls the LCD, keypad, buzzer, 4 LEDs, and an optional EEPROM. The arduino can simply dump info via serial to this panel for display purposes and the panel takes care of wrapping long lines into multiple rows, auto scroll like old dos window, and interprets return, back space, space, tab etc. for formatting on the LCD so that the arduino project doesn't have to think about all these details at all. There are also functions to control cursor position, clear screen, turning on and off the display or changing back light commands all in the form of standard ANSI escape sequence, instead of some manufacturer-special code for these controls.
Sensing the keypad is dead easy. On the arduino side, you just wait until a character pops up on the serial and that is a key press, translated into '0' to '9' and such. You can also do multi-tap input on the keypad. The arduino again waits for characters to pop up on serial as the panel does all the footwork of the multi-tap logic. You can make up a simple menu on this panel within one minute of your time:
On arduino, do a few Serial.println() to output a menu on the display. Since when does lcd.println() work? Well, mine does.
Then on arduino, you do a wait till a character gets back to you via serial, then decide which function to run:
Sample arduino code to get a menu up and running:
Serial.println("Menu:");
Serial.println("1.Display GPS info");
Serial.println("2.Record GPS info");
while(1) {
if (Serial.available()) { // Make sure there is a key press
char response=Serial.read(); // Read key press from phi-panel
if (response=='1') display_GPS();
if (response=='2') record_GPS();
break;
}
}
I have been on this project for a couple of months now. The hardware was not the most difficult project I did but firmware is a lot to do. I implemented most of the ASCII control codes and ANSI escape sequences plus my 'private' ANSI escape sequence to invoke phi_prompt for interactive lists and else. Here is the webpage:
I have a long manual which I am uploading to this page so you can see what you could do with this panel.
Link to a youtube playlist of all my examples: