Bluetooth support on MT1300

Hi,
He has been trying to add Bluetooth support to this device for several days.
The easiest way would be to connect bluetooth to USB.
However, it does not want to deprive itself of free USB ports via a Bluetooth adapter.
I don’t want to use USB hubs because it looks ugly and inconvenient.
I want to use the built-in Bluetooth module in the Beryl MT1300.
This router contains the TLSR8251 model which is responsible for Bluetooth in this device.
This module is also found in very popular bluetooth thermometers that also measure humidity.
My reason for wanting to use built-in Bluetooth is very simple. I want to read temperature and humidity from thermometers with Beryl and then send them to InfluxDB.

From what I was able to determine, the application with this name manages Bluetooth in this device:
/usr/sbin/ble_config_wifi

This application connects to / dev / ttyS1 to establish a connection with the bluetooth module.
Console bandwidth is: 115200

The app’s source code is included in the attachment.

I tried to upload new software directly from the router to this module using GitHub - pvvx/TLSRPGM: TLSR SWire programmer project, but I did not succeed.

I was looking on the internet for information about this module and its HCItool integration. However, I couldn’t find any useful information.

If I understand the GL.inet code correctly, the application communicates with the module via a proprietary API.

To be able to use bluetooth natively on this device, you would have to do the following:

  1. Upload the firmware compatible with HCItool to the Bluetooth module. - Very difficult.
  2. Installing hcitool on OpenWRT. - Very easy.
  3. Use Bluetooth conveniently.

Has anyone already worked on this?
If I have made any mistakes in this post, please let me know.
ble_config_wifi.1.c.zip (13.5 KB)

I would love this. I use a pi for this but I’d like to do it on the router as well because why not .

1 Like

Good morning,
Below I am attaching the source code of the /usr/sbin/ble_config_wifi file
ble_config_wifi (1).zip (13.4 KB)

/usr/bin/gl_ble_ubus
gl_ble_ubus.zip (4.7 KB)

Has anyone been able to find out more about how Bluetooth works on this device?

What do you want to use the Bluetooth for? It is now only used to configure the wifi for the first time setup. But most people just use cable/wifi to configure the router.

1 Like

I would like to use this to collect data from IoT sensors. Additionally, I would like to use Router to control bluetooth devices.
Using Bluetooth only for the first configuration of the router is a very modest solution.
Support for standard Bluetooth will allow me to exchange proprietary gates for open source considerations.
I could still connect a regular USB Bluetooth adapter to Beryl and I will probably do it when I fail to change the purpose of the built-in Bluetooth module.
There are also alternatives based on ESP32 and the Raspberry Pi.
In the case of ESP32, we have another device that clutters our radio bands and consumes electricity.
The Raspberry Pi has the same disadvantages as the ESP32 and a big issue with availability and pricing.

Beryl with its built-in bluetooth module is the best solution for me. One device with a free USB port that serves as an IoT network and gateway.

In my case, I want to get the values ​​broadcast by thermometers and smart flower sensors. I have many other bluetooth devices but they are less important to me.
I want to send data from these devices via Beryl to InfluxDB or Home assistant.

Unfortunately we don’t support BLE for other purpose on MT1300.

This is a different topic and we have IoT devices to do that.