Connected HM-10's GPIO Control and ADC input

Hi,

I just started around with HM-10 modules and successfully connected two HM-10's using Dan Chen's method.

Everything is working great, except now, I want to control the HM-10's GPIO's and attach a sensor to one of the HM device.

At this moment, when the devices are not connected to each other, I can control the GPIO's using the code "AT+PIO2x" where x could be 1/0(HIGH/LOW). As requred, one LED attached at PIO2 clearly lights up when AT+PIO21 is passed to any of the HM device where the code is passed. But as soon as I establish a connection between both the devices, the GPIO control is lost. I can no longer control the GPIO's.

Also, I want to read Analog input received at one of the HM device. To be precise, I want to attach a Sharp proximity sensor at one of the GPIO's on HM1 device and send the sensor data to another HM2 device.

So my two questions are,

1. How to control HM-10 devices GPIO's when the two HM devices are in Duplex mode of connection as described above

2. How to make the HM device read analog inputs?

I would really appreciate if someone could help me in this. For reference I have included my setup below:

My setup:

  1. Two Chinese BLE-CC41A H(M-10) modules originally came with Bolutek, but currently flashed to JNHuaMuo.

  2. Using FTDI and have the boards as follows:

  • Both HM-10 are in "AT+MODE2" mode
  • One of the HM-10 (HM1) is set to "AT+ROLE0" role, while other HM-10 (HM2) is set to "AT+ROLE1" role.

Are the HM-10s connected to Arduinos? If so, why do you need to connect hardware to them, rather than the Arduino?

If not, why are you HERE?