AT+BLEDISCONN blocking issue

espc6user
Posts: 7
Joined: Mon Oct 21, 2024 9:33 am

AT+BLEDISCONN blocking issue

Postby espc6user » Tue Oct 22, 2024 9:23 am

Hi,

I'm trying to setup an application that uses ESP-C6 with ESP-AT 4.0 for sending/receiving some data over BLE SPP.
I'm doing the following steps:
ATE0
AT+SYSLOG=1
AT+SYSMSG=5
AT+BLEINIT=2
AT+BLEADVPARAM=32,32,0,0,7,0
AT+BLEADVDATAEX=adv_params
AT+BLEADVSTART

Once connection is received from ESP via
+BLECONN:0, remote_addr

I'm setting up the SPP connection
AT+BLECONNPARAM=0,6,6,0,30
AT+BLESPPCFG=config
AT+BLESPP

After ">" response is received data is sent via SPP.
After a period of time I want shutdown the SPP and disconnect from the client and do:
+++ - for exiting the passtrough mode. I do receive the confirmation message from ESP: +QUITT
AT+BLEDISCONN=0

After sending the disconnection request AT command ESP seems to not responding anymore until I reset the ESP.

I suspected that it might be something on my end, hence I tried sending another command and seems to be working
AT+BLECFGMTU?
+BLECFGMTU:0,23

I also tried to message that sets data:
AT+BLESETPHY=0,2
+BLESETPHY:remote,2,2


What worked and triggered a disconnection, by receiving an asynchronous message, of the ESP server from the client was deinitializing the BLE
AT+BLEINIT=0

I tried to check whether sending AT+BLEDISCONN=0 might provide any response after the BLE has been deinitialized. I experienced the same issue.


Any thoughts on what I might be doing wrong here?
Is it possible that AT+BLEDISCONN=0 is intended only for client role and not for server role? The only instance I found in the manual for this commands was for client role, hence the questions.
Any advice or information is highly appreciated.

Sun
Espressif staff
Espressif staff
Posts: 336
Joined: Thu Dec 30, 2021 9:52 am

Re: AT+BLEDISCONN blocking issue

Postby Sun » Tue Mar 25, 2025 2:38 am

Tested with ESP32C6 version v4.0.0.0 AT version firmware, no related issues were found. Please use the AT firmware on the esp-at master branch to test whether this problem still exists. If this problem still exists, please provide detailed logs of the AT command port and log port with timestamps.

espc6user
Posts: 7
Joined: Mon Oct 21, 2024 9:33 am

Re: AT+BLEDISCONN blocking issue

Postby espc6user » Wed Nov 12, 2025 9:38 am

Thank you for coming back to me with your reply.
I will come back with a series of traces as soon I can. I have the ESP on a custom PCB and is controlled by a different micro controller.

What I can say is that the version I did use was a snapshot of the master branch from Sept 2024 (technically newer than the v4.0.0.0 which was released on 29Dec 2023).

Who is online

Users browsing this forum: No registered users and 1 guest