BluetoothSerial.connect(address) return value

sporked
Posts: 5
Joined: Fri May 08, 2020 6:30 am

BluetoothSerial.connect(address) return value

Postby sporked » Sat May 09, 2020 6:37 am

I'm using an ESP32 NodeMCU to connect to an HC-05 module. All is working well. But I have a question... The connect() method returns a bool value, but in my case it seems to return TRUE whether it connects or not. My apologies if I'm being dense, but would love some input on what the return value should indicate.

Thanks!

ESP_Sprite
Posts: 9727
Joined: Thu Nov 26, 2015 4:08 am

Re: BluetoothSerial.connect(address) return value

Postby ESP_Sprite » Sat May 09, 2020 8:17 am

Moved to the Arduino subforum.

sporked
Posts: 5
Joined: Fri May 08, 2020 6:30 am

Re: BluetoothSerial.connect(address) return value

Postby sporked » Sat May 09, 2020 9:24 am

I'm curious as to why this would be moved to the arduino sub-forum. None of the hardware mentioned uses an arduino. Is it because this module is programmed through the arduino IDE or because it's an arduino-like module?

Just asking so I can try to post in the appropriate area in the future. Thanks.

ESP_Sprite
Posts: 9727
Joined: Thu Nov 26, 2015 4:08 am

Re: BluetoothSerial.connect(address) return value

Postby ESP_Sprite » Sat May 09, 2020 1:29 pm

If I'm not mistaken, BluetoothSerial.connect() is part of the Arduino api, I don't recall it being in ESP-IDF. If I am mistaken and you are using ESP-IDF instead, I can move it to a more relevant subforum.

sporked
Posts: 5
Joined: Fri May 08, 2020 6:30 am

Re: BluetoothSerial.connect(address) return value

Postby sporked » Sat May 09, 2020 4:05 pm

You're probably right. I've only worked in the arduino api, so I don't know any different. Thanks.

Who is online

Users browsing this forum: Majestic-12 [Bot] and 51 guests