ble 2 sensors and 1 station?

The official PYBD running MicroPython, and its accessories.
Target audience: Users with a PYBD
Post Reply
IHOXOHI
Posts: 119
Joined: Sat Apr 25, 2020 7:31 am

ble 2 sensors and 1 station?

Post by IHOXOHI » Thu Dec 30, 2021 9:08 am

Hi,

I tried to use 2 pyb-d, each one with a ble temperatre sensor and one pyb-d like station...
The ble station no check the second ble sensors...
Is it possible to find a way for doing that?

Thanks.

lofer
Posts: 13
Joined: Tue Mar 31, 2020 5:17 am

Re: ble 2 sensors and 1 station?

Post by lofer » Fri Jan 07, 2022 3:35 am

I am not able to understand your question, unfortunately. Could you please try to re-write it with more details?

IHOXOHI
Posts: 119
Joined: Sat Apr 25, 2020 7:31 am

Re: ble 2 sensors and 1 station?

Post by IHOXOHI » Fri Jan 07, 2022 10:47 am

Hi Lofer,
Thanks for your attention,

Bluetooth works fine with one pyb-d wich have a sensor, and one other pyb-d wich receive data from the first one pyb-d.
I would like use 2, or more, pyb-d wich one with a sensor, and one pyb-d wich receive all data from others pyb-d.

For moment when I tried to do it, the station no check a second pyb-d...
My phone and my computer could have more than just one bluetooth connection... I suppose that it could be possible too with a pyb-d...

A part of the "ble library" wich could be change (the stop scanning):

Code: Select all

# Found a potential device, remember it and stop scanning.
                self._addr_type = addr_type
                self._addr = bytes(
                    addr
                )  # Note: addr buffer is owned by caller so need to copy it.
                self._name = decode_name(adv_data) or "?"
                self._ble.gap_scan(None)
Thanks,

IHOXOHI
Posts: 119
Joined: Sat Apr 25, 2020 7:31 am

Re: ble 2 sensors and 1 station?

Post by IHOXOHI » Wed Jun 08, 2022 7:18 am

Hi,

Is there an other way for make a station with a classical computer (like a raspberry for example) wich can received data from several pyb-d ?

Thanks a lot.

User avatar
OlivierLenoir
Posts: 126
Joined: Fri Dec 13, 2019 7:10 pm
Location: Picardie, FR

Re: ble 2 sensors and 1 station?

Post by OlivierLenoir » Wed Jun 08, 2022 7:22 pm

Did you look for MQTT and MQTT Mosquito server?
MicroPython implement umqtt/simple and umqtt/robust.
Oups, I thought it was ESP32.

Post Reply