Project advice for system with Micro Pro and two incoming wireless data streams?

Hi,

I am fairly new to and illiterate in electronics. But I can be stubborn and am able to learn. I have set my mind to building the following device:

SHORT PROJECT DESCRIPTION

My goal is to have a programmable controller device which incorporates two element groups: 1: An acceleration-sensor and 2: a group of push-buttons and which acts in the following two scenarios (with scenario 1 being my intermediate goal, and scenario 2 another, more advanced goal) :

Scenario 1:
(1) Map Push-Buttons on the controller to keyboard keyboard-keys on a pc/laptop and
(2) map acceleration-sensor data to KEYBOARD KEYS on a pc/laptop

Scenario2:
(1) Map Push-Buttons on the controller to keyboard keyboard-keys on a pc/laptop and
(2) map acceleration-sensor data to MOUSE-MOVEMENT on a pc/laptop

ADDITIONAL CONDITIONS:

  1. The controller must transmit the data wirelessly.
  2. By programmable I mean e.g. something like a Sparkfun Pro Micro (https://www.sparkfun.com/products/12640) so I can configure different mappings of buttons to keys and different settings for how to handle the acceleration-sensor data.
    (Like, control different games with the same device and be able to adjust sensitivity / acceleration-sensor data processing)
  3. Acceleration sensor and the push buttons are disjoint - they do not reside in the same place and are not connected by cables. Actually, they behave like two different, isolated controllers which transmit their data independently and wirelessly. The push buttons form a group (like a handheld device with a few buttons).
  4. Acceleration sensor and the push buttons send data simultaneously and it must be processed simultaneously.

For clarification and to explain what I have thunk so far, please consider the attached image below.

WHAT I HAVE THUNK SO FAR:

  1. A pro micro seems to be a cost-efficient device which comes pre-configured to act as a keyboard, so I don’t have to mess with firmware and bootloaders to convince another board to act as a keyboard. Also, I have a pro micro, and the button-press to keyboard-mapping works like a charm (albeit, not wirelessly yet).
  2. There are so many wireless solutions. Which ones are best suited for my project?
    2.1. Infrared looks tempting. Seems easy to use and the range limitations are not a problem. I dont need the controller more than a few feet away from the receiver. But it is only a solution for the push-buttons, right? Will I have to aim with the infrared transmitter, or will it work regardless of where I point it at?
    2.2. For 433 MHz there are many ready-made solutions cheaply available, e.g. with four push-buttons. But I have read about regulatory limitations. 433 MHz can only be used for signalling for a short period of time and then it must be silent. I think.
    2.3. 2.4 GHz seems to be the gold standard, which comes at a prize (in terms of being complicated to use/program and expensive equipment/modules)
    2.4. Bluetooth for the acceleration-sensor data (and maybe also for the push-buttons? HC-05 modules seem inexpensive.
  3. Why an accelerometer and no Gyro? Accelerometers seem easier to use and inexpensive. The adxl 345 looks very promising for my needs (love the built-in tap and double-tap functionality!): http://bildr.org/2011/03/adxl345-arduino/

MY QUESTIONS, WOES AND WORRIES:

a. Can the pro micro receive, process and transmit all this data simultaneously? It seems like it can, but I am not sure if with all wireless-technologies (e.g. only one Rx pin on the pro micro) chatting simultaneously if this will work.
b. What are the appropriate wireless-technologies for my uses?
c. Is bluetooth my solution? Is it possible to have two incoming bluetooth data-streams into my Pro Micro?
d. am I am on a stupid track with the Pro Micro, and there are much better solutions?

Any help would be greatly appreciated.

Thanks and regards!

Schroedingers_Kater

Schroedingers_Kater:
Also, I have a pro micro, and the button-press to keyboard-mapping works like a charm (albeit, not wirelessly yet).

This caught my eye.

A pro-micro can pretend to be a keyboard by virtue of its USB connection. There is no simple way to convert that to wireless. When you have (say) a wireless keyboard it is the dongle (or whatever) that is plugged into the PC that appears to the PC to be a keyboard.

What should work is to use two Arduinos. Have a pro-micro connected by USB and communicating by wireless with another Arduino. That would be functionally similar to a wireless keyboard.

...R

Thank you for your thoughts, Robin!

So, you are suggesting I use two other arduinos to communicate with my Pro Micro? Sounds like the way to go, since the push-button-device and the acceleration-sensor need some platform to communicate through I guess. That means two other little boards, which sounds okay, since I am sure they can be lightweight (simple, I mean).

But what wireless technology to use for each of them? How (by which wire(less)) do I get them to communicate with the Pro Micro - in the easiest and cheapest way?

Infrared for the buttons and SOMETHING (for the acceleration-sensor?). 433 MHz for the buttons? (e.g. buy one of those cheap 4-push-button-devices on 433 MHz and teach my Pro Micro to read those buttons?

I like the schematic. That shows me lots of useful information. I think you are on the right track there.

There's lots of choices for the radio* part of the project. I'm sure Sparkfun has a guide that's helpful.

The basic 433MHz "garage door opener" type things basically do just on and off. Useful for a button. Also useful for Serial data, which is just a stream of on and off.

As you step up in capability, the radio starts to manage the Serial data by itself. You send it a byte and it ensures that the same 8 bits come out the other end, with some random delay depending on how many times it had to re-send any missing data.

Some radios make a "mesh network" which allows them to automatically route a message through several hops to get to its destination.

Bluetooth and WiFi add more layers of connections, primarily for privacy. Nobody can eavesdrop on your Bluetooth data.

However, something like the ADXL345 requires either I2C or SPI. That's synchronous serial or "serial with a clock". Most radios I know don't do this natively. Or if they are SPI devices (like most Ethernet chips used with Arduino) then the SPI is for talking to the device, not for sending through unmolested to the other end. So you basically have to have a small Arduino at the 'sensor end' of the link to manage the sensor and transcribe the data onto Serial for the radio.

*My grandma used to have a "wireless"

Schroedingers_Kater:
So, you are suggesting I use two other arduinos to communicate with my Pro Micro?

I am a bit confused. Your diagram was not there when I replied and I don't know if you have made other changes to your Original Post. For the future don't make changes to existing posts other than to correct typos. Put new information in a new Reply.

I had assumed you wanted to replace the wired connection between the Pro-Micro and the PC and I was saying that that would not be easy.

And I was suggesting that you leave the Pro-Micro connected to the PC using the USB cable and create a wireless link between it and another Arduino. I did not interpret the original version of your Original Post to mean that you wanted multiple wireless links.

Of course there is no reason why you cannot have multiple Arduinos with wireless links to a Pro-Micro connected to your PC. The cheap and effective nRF24L01+ modules are one way to do that. Have a look at this Simple nRF24L01+ Tutorial

...R