I am making a MIDI program change pedal that will interact one way with software for a band I work with. That's all fine, but I've been asked to create 2 identical pedals for both sides of the stage. One of them being the master unit that sends the MIDI command via standard DIN cable to the software, and then a second remote unit that wirelessly communicates with the master. It will need to display the preset bank and currently activated preset. Whatever happens on one, needs to be reflected on the other.
I've attached a snapshot of the schematic I'm in process of creating for the master unit. Using 2 shift registers for LED and foot switch's, and a MAX7219 for the 4 segment preset display. Since the TX will be sending the MIDI command, what do you think the most straight forward approach would be?
I've considered adding a second Atmega328 via I2C to the master unit, and then utilizing the RX/TX for communication there (either via bluetooth, XBee, etc). The remote unit will only be used to speak with the master, so it won't need to use MIDI out. Wireless is a new area to me, so I'm hoping to get some guidance so I don't do things the hard way first.
Bluetooth is simple to implement. It is really just serial-by-wireless. If a wired serial connection would be OK then a Bluetooth link should also be OK.
Another option is the cheap nRF24L01+ 2.4GHz transceivers which work well and have longer range than Bluetooth. However it is probably a little more complex than Bluetooth.
PaulS - The amount of data will be really minimal, and the range will be no further than 10-20 meters, line of sight, maybe a few speakers here and there, floor level. This band plays big festivals, so even on the widest stages, it couldn't exceed that. The way it will function is one press, one MIDI program change message, with a bank indicator and LED showing what preset is currently selected. No continuous data back and forth, only when a change happens. Once every 30 seconds or so- But they will always need to match up without anything lost.
Robin2 - With bluetooth, will I be able to send and transmit via the A4 and A5 pins on the atmega? If so, that just might be my answer!
PaulS:
If they are not otherwise being used, yes.
If you can live with the 10 meter range...
If it is going to be be at the max end of its range, then it might not be.
As far as the nRF24 route goes, I'm seeing that it uses the MOSI, MISO, and SCK connections- As I am already using those for the Max7219/4-Digit number display, would it be a case of a second Atmega328 used exclusively for radio communcations on both circuits, connected to the master Atmega via i2c?
My rough understanding of the communication link-
nRF24 sends and receives data to/from remote unit into slave Atmega328 -> i2C communication of that data to Master Atmega328 -> final command to MIDI out. Something like that?
My apologies if that is completely wrong, still finding my way around
Apart from nRF24, there's also the RFM69 that works on sub-GHz frequency, had built-in encryption and offers great range/reliability. Here some "Arduino" boards with RFM69 built-in available: