Alarm Clock that runs CPU exe | High School Project Help


My students made a functioning arduino alarm clock and they want it to run an executable file on a computer when the buzzer goes off.

Any help, or direction to guides/relevant programs would be greatly appreciated.

Thanks in advance!

You'll need a program running on the PC listening to the serial port. The Arduino can send it a message telling it to launch the required exe.

You might be able to do it with Processing - disclaimer: never used it.

Thanks, that is helpful, as I know how to print to serial. Is Processing a program? I think I am more lost where to start on making the CPU program that listens to the Arduino.

Read about processing here.

Personally, since I haven’t used it, I would use visual studio and write a little forms program. Communication using the serial port is pretty easy to do in C# or VB.

Python’s another popular choice. Forum member Robin2 has posted about using it.

I except opening the port will reset the Arduino, just as the IDE’s serial monitor does.


Thanks so much I will get reading & testing!

I except opening the port will reset the Arduino, just as the IDE's serial monitor does.

But that may be suppressed by a modification to the Arduino.

Another option is to use an Arduino board that can do keyboard emulation via the Keyboard library (Leonardo, Micro, Pro Micro, Zero, MKR) and then program the Arduino board to send a unique keyboard shortcut (e.g. Ctrl + Alt + Shift + W) to the computer, which is configured to run desired program when that shortcut is detected.

In Windows, you can easily assign keyboard shortcuts to any program by creating a shortcut (or using an existing shortcut in the Start menu), right clicking on the shortcut, selecting "Properties" from the context menu, then entering the desired shortcut into the "Shortcut key" field. You can do the same on other operating systems, though the procedure may be different.