HC-06 Bluetooth replacing current joystick for arduino?

My current arm is conroled via joystick, and I don't want that functionality to go away. However, I'd like to be able to have the user switch to using bluetooth.

I'm having a problem with coding this though.
Even when I comment out my joystick analog reads (which is necessary for controlling my robot, as I center the analog read and then scale it for geometric use later).

But when I try to do an analog read of the HC-06, it doesn't translate so easily. Is it possible to do accurate analogReads of the bluetooth joystick? Does it need to be centered differently?

My wiring:
GND -> GND).
VCC -> 5v.
TX/TXD -> Analog 14
RX/RXD -> Analog 15
//TX/TXD -> 4.
//RX/RXD -> 2.

This is an example of what I do with my joystick x and y position readings, just to show that I'm manipulating them later:

  pos_X_2 = (analogRead(X_pin_2) - 512.0); 
  pos_Y_2 = (analogRead(Y_pin_2) - 512.0);

HC-06 does not have any analog to digital converters on it (or at least broken out for general use). It is simply a device used for UART serial communication.

Please post a schematic of your current/intended setup AND please post your entire code in tags.

Doing both will help us to help you :wink: