HC05 Pin EN

Hi!
I am working with an Arduino Nano and HC05 Bluetooth module.
I want to put HC05 to sleep mode, so I need to enter in configuration mode to use AT commands.
I want to do that by sofware (using EN pin).

I connect EN pin to either 3.3V or 5V arduino outputs and I power the Arduino, and HC05 starts in configuration mode without problem. But if I use a digital pin (configurated as output and writing it as HIGH) connected to EN, it doesn’t work (just starts in user mode).
I don’t understand why.

My code is this:

#include <SoftwareSerial.h>

SoftwareSerial miBT(10, 11);
const int pin = 6;

void setup()
{
Serial.begin(9600); // comunicacion de monitor serial a 9600 bps
pinMode(pin , OUTPUT);
digitalWrite(pin,HIGH);

miBT.begin(38400); // comunicacion serie entre Arduino y el modulo a 9600 bps
delay(4000);
}

void loop()
{

}

I can’t understand why using a digital output doesn’t work as 3.3 V output.

I only played once with Bluetooth so take this for what it is ( aka please research yourself :wink: ).

From memory, I'm reasonably sure that the enable pin is only read by the HC05 during a power up of the module. Please take into account the boot time of the Nano before it starts executing your code.

To use AT mode, you need to control the power supply to HC-05 as well as the EN pin, i.e. to get out of comms mode, reconfigure, then restart in comms mode.

I'm not sure what you are about, but I think you are kidding yourself anyway. IF you want to send data at regular intervals, you could still do that simply by turning the normally-off power on for a short period at those times - no configuration required.

@valhadiel

Other post/duplicate DELETED
Please do NOT cross post / duplicate as it wastes peoples time and efforts to have more than one post for a single topic.

Continued cross posting could result in a time out from the forum.

Could you also take a few moments to Learn How To Use The Forum.

Other general help and troubleshooting advice can be found here.
It will help you get the best out of the forum in the future.