SparkFun Forums 

Where electronics enthusiasts find answers.

All things pertaining to wireless and RF links
By elliotbriggs
#44654
I have a problem with remote configuration with a bluedongle USB with the RN-41 module trying to configure a remote dip module. I can see the remote module blinks its LED twice a second for the first 60 seconds after power up indicating it is ready for remote configuration. I connect to it successfully and test that the link is good by shorting the TXD to the RXD on the remote device so it echoes whatever I send to it.

I have tried to do things such as set PIO pins high or low and read them and it is only occurring on the USB dongle, I can measure this directly. I poll the device for PIO pin status and it indicates correctly that the PIO pin is where it should be.

Here is a sequence of events:
-Attach bluedongle USB
-connect with hyperterminal
-Power up remote module, and verify LED is blinking at 2 times per second indicating ready for remote configuration.
-Type $$$ in hyperterminal
-CMD response
-'C' connects the device to the remote device since the address is stored
-$$$ again since I am no longer in config mode, all characters are echoed back until '$$$'
-CMD response, USB dongle LED blinks 10 times per second, remote device is not blinking
-S*,0404 sent, response 'AOK'. should set PIO10 to output on remote device
-S&,0404 sent, response 'AOK'. should set PIO10 high on remote device.
-Measured low on remote device, but high on local device.

I can do the same thing with the switches, I can read the switch values by sending '&'. When the "reset" button is pushed "switch 1" is read high on the local device. When this IO is set high on the remote device, only the local device is being read.

It seems that when I try to enter config mode when connected, which should config the remote device as the datasheet says, it only affects the local device.

Thanks for any help!
By elliotbriggs
#44801
OK, I figured it out.

The EASIEST way to get remote configuring to work is to use the S$,<char> command to set the command characters to one of the modules to differ the other.

In my case I set the local (USB) device's command characters to '!!!' using "S$,!!!\n\r" and disabled the config timer for the remote device using "ST,255\n\r". Now, when I want to config the local device, I simply send "!!!" and when I want to configure the remote device I send "$$$" anytime since the config timer is never timed out.

Having "$$$" as the config command for both devices just didn't work for me. Now everything works perfectly.
By elliotbriggs
#45612
I'm going to bump this up since people have been having issues with bluetooth and the above post shows how I got it to work flawlessly.