I want to create a virtual keyboard by interfacing a Raspberry Pi with an Arduino and an ultrasonic sensor.
To make the experience fit your profile, pick a username and tell us what interests you.
We found and based on your interests.
I ran into a bit of a wall with the Arduino Uno. It turns out as much as it is easy to interface with the Pi Zero W it has the wrong chipset and won't allow me to run the Keyboard.h or Mouse.h libraries. A few nights ago I stumbled on to the Seeeduino Xiao which might have just made the project better. It is ultra small, inexpensive and comes equipped with the chipset I need. I will find out more when it comes in the mail.
A typical Arduino IDE has a serial monitor but the CLI doesn't have that option. After doing some digging I found I was able to mimic the monitor by way of a cat command. I hooked up the ultrasonic sensor and ran:
stty -F /dev/ttyUSB* 1000000 raw -clocal -echo cat /dev/ttyUSB*
This allowed me to see in real-time what was going on with the sensor proving that they had interfaced properly. My next step is overlapping a keyboard with the sensor.
I am farther along in this project than I expected. Last night I interfaced my Pi Zero W to my Arduino Uno via the adapter and cable with no power supply problems. The board itself reads correctly on the Raspbarian desktop due to the installation of the Arduino CLI. There's no Arduino IDE available on the Pi Zero W but the CLI does the job.
Create an account to leave a comment. Already have an account? Log In.
I've seen a keyboard that projects an image of each key on a flat surface and then uses some kind of gesture detection to see which "keys" have been touched. Will this be something similar?
Become a member to follow this project and never miss any updates
It's very much the same idea. I saw that too ages ago and became fascinated with it. In theory, combining it it with a Pi should create a much much smaller working computer. Still trying to figure out the screen part though. In my head I'd like to make it a watch but the sensors and the Uno are too big for that.