I'm a software engineer wanting to get into IoT / embedded systems. I was thinking about a project lately, but I have only a vague idea on how it could be done, and I thought that maybe Arduino could be the right starting point to make a proof of concept.
What I want to do is a USB dongle that fakes its capabilities. That is, once inserted, I want it to present itself to the OS as a headset (microphone + speaker), or maybe, to start with something easier, as a keyboard. I want it to be able to be used with standard drivers at least on Linux.
The full project I have in mind is this: I want it to pretend to be a headset, so the OS sends it an audio stream and expects from it another audio stream. Also, I would simultaneously need another two data streams from/to the arduino (on the same USB, is it even possible?), call them DATA_IN and DATA_OUT. So four in total.
What I would like to do is something along this lines: some application on the machine is sending the Arduino an audio stream since it thinks it is a speaker; I take this audio on the arduino and loop it on DATA_OUT. At the same time, I inject data in DATA_IN and the Arduino loops it back on the microphone interface, and the application takes it.
Is this possible at all? I had a quick look at Arduino Nano Every, and I read that the firmware on the USB microcontroller SAMD11 can be customized, maybe that's the starting point to be able to make it present itself as a USB HID of some kind?
Thank you very much,