Navigation

    Welcome to the Pycom forum

    Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    1. Home
    2. Tags
    3. ble
    Log in to post

    • franman

      Trying to connect LoPy4 to Xiaomi MiBand 2
      LoPy • lopy4 firmware ble • • franman  

      1
      1
      Votes
      1
      Posts
      544
      Views

      No one has replied

    • D

      What is needed to link up with WiPy 2?
      WiPy 2&3 • ble • • d2xhale  

      6
      0
      Votes
      6
      Posts
      1378
      Views

      livius

      @d2xhale said in What is needed to link up with WiPy 2?: The LCD I plan to use is just a 2 digit screen, so I'm looking for a unit that is a little smaller I do not know details about your project but starting point and final point many times provide different result :) e.g. you start with two digit but maybe better is OLED ;-) You can draw there what you need and show more details on it.
    • S

      BLE Features - non-blocking connects, char presentation format
      WiPy 2&3 • ble bluetooth • • semireg  

      1
      1
      Votes
      1
      Posts
      949
      Views

      No one has replied

    • S

      Callback when BLE client subscribes to notify characteristic?
      WiPy 2&3 • ble bluetooth • • semireg  

      8
      1
      Votes
      8
      Posts
      3364
      Views

      jmarcelino

      @semireg Thank a lot, looks great. Good call on catching the descriptor write in modbt.c We'll review it and it should make into the next release.
    • P

      Explain BLE Example Code
      Discussion • ble bluetooth wipy 2.0 • • panos29  

      1
      0
      Votes
      1
      Posts
      1469
      Views

      No one has replied

    • M

      BLE Error
      LoPy • ble • • misterlisty  

      3
      0
      Votes
      3
      Posts
      859
      Views

      M

      Problem..solved due to your suggestion!
    • iber

      LoPy Bluetooth characteristic buffer size
      LoPy • lopy ble bluetooth ble send data mobile • • iber  

      2
      0
      Votes
      2
      Posts
      988
      Views

      jmarcelino

      @iber That's normal because it's not really a buffer, Bluetooth LE characteristics are usually restricted to 20 bytes by the protocol - it's what fits in the BLE packet - so unless you negotiate a larger MTU (larger packets than standard) between peers or use Long attributes you are restricted to that amount. Neither of those extended techniques are currently supported.
    • M

      bluetooth.service and characteristic correlation
      MicroPython • ble • • misterlisty  

      2
      0
      Votes
      2
      Posts
      997
      Views

      jmarcelino

      @misterlisty When you do this: b'1234567890123456') You're creating a list of bytes based on the ASCII value of each digit (1 = 0x31, 2=0x32 3=0x33 etc) Your phone however shows you the hexadecimal representation of each byte. It also has a different byte ordering but you can see the b'123...' in "...33-3231" - it's just in reverse order See my previous post on how to produce services that look as you expect: https://forum.pycom.io/post/3279
    • livius

      BLE does not read whole buffer data
      Issues & Bugs • ble • • livius  

      15
      0
      Votes
      15
      Posts
      3156
      Views

      livius

      @jmarcelino I see that in public firmware it is now also avaiable :) (mac=b'\xd2lBk\xad\xc2', addr_type=1, adv_type=0, rssi=-83, data=b'\x02\x01\x06\x1b\xffW\x01\x00\xef\xbf\xc9\xac\xe7\xd5\xd0.\xe5\xf0\x8cr[\x8b[w\x03\xd2lBk\xad\xc2\n\tMI Band 2\x03\x02\xe0\xfe\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00') {'NameShort': None, 'Flag': 6, 'Mac': b'd26c426badc2', 'NameComplete': b'4d492042616e642032', 'MfrData': b'570100efbfc9ace7d5d02ee5f08c725b8b5b7703d26c426badc2', 'Data': b'0201061bff570100efbfc9ace7d5d02ee5f08c725b8b5b7703d26c426badc20a094d492042616e6420320302e0fe00000000000000000000000000000000', 'Rssi': -83, 'Appearance': None} 'NameComplete': b'4d492042616e642032' import binascii a=b'4d492042616e642032' c=binascii.unhexlify(a) print(c) give me proper result :) 'MI Band 2'
    • duffo64

      [SOLVED] BLE scans forever
      Discussion • ble • • duffo64  

      4
      0
      Votes
      4
      Posts
      925
      Views

      duffo64

      @jmarcelino Got why. In the while loop where I test for bt.isscanning() I had to introduce an sleep_ms(1), since the scan termination wasn't recognized anymore. Thank you
    • soren

      Detecting rssi of multiple BLE beacons
      LoPy • ble bluetooth rssi beacon estimote • • soren  

      1
      0
      Votes
      1
      Posts
      981
      Views

      No one has replied

    • D

      BLE and LoRa in LoPy
      LoPy • lopy lora ble • • devkumarchandil  

      4
      0
      Votes
      4
      Posts
      1248
      Views

      D

      @jmarcelino Thank you for the information. I do have one more query, is there any sample or any information which consist of these 2 working together or any sample code.
    • A

      Powering from 5V generates noise?
      LoPy • lopy ble power noise 5vdc • • Aris  

      5
      0
      Votes
      5
      Posts
      1310
      Views

      jmarcelino

      @aris Currently beacon scanning is done via GATT which adds a lot of stack overhead. It's possible to scan for beacons more efficiently.
    • soren

      Lopy - picking up MAC address from Ibeacon
      LoPy • lopy ble bluetooth mac ibeacon • • soren  

      2
      0
      Votes
      2
      Posts
      1482
      Views

      jmarcelino

      The MAC address printed on your beacons is just a nicely formatted version in hexadecimal of the 6 byte address. What you get from Python are the actual 6 bytes themselves (hence the b' at the start) and when you print them they get turned into the correspond ASCII characters for that value (or \xYY if it's not a printable character) You can use the binascii.hexlify function to turn each of those bytes into hexadecimal and make a string which is closer to what you have. For example your b'FS\xbd\x8c\xd2\x11' >>> import binascii >>> binascii.hexlify(b'FS\xbd\x8c\xd2\x11') b'4653bd8cd211' So this address is 46:53:bd:8c:d2:11 Of course you can split into pairs, add the colons and make all letters uppercase too using standard string manipulation.
    • A

      Passive beacons.
      SiPy • ble beacon sypy • • alidaf  

      19
      0
      Votes
      19
      Posts
      4140
      Views

      A

      @papasmurph Exactly. I've been trying to use a complex exponential relationship with some empirically based factors but because I have different types of device, the relative numbers between device types are awful. The simplest approach is the best so far!
    • P

      Android WiPy2.0 Bluetooth connectivity?
      Discussion • ble bluetooth wipy 2.0 connection android • • panos29  

      4
      0
      Votes
      4
      Posts
      1621
      Views

      robert-hh

      @panos29 It's more about the ADC range, which is about 0.07 - 1.1V for the reading between 0 and 4096. I assume you would always need some kind of pre-amplifier/buffer, at least to protect the esp32 against damage,, and if you do not need to take values at hight speed, you can always use averaging to reduce the noise. The esp32 chip is told to have a built-in preamplifier, but that is not supported by Micropython, and I do not know whether it works.
    • F

      [LoPy] - Sending File to LoPy from Mobile Over Bluetooth
      LoPy • lopy ble bluetooth • • fuzzy  

      7
      0
      Votes
      7
      Posts
      1972
      Views

      F

      @robert-hh Thats great. Have skipped my attention so far... Thanks!
    • N

      Get Client Mac Address in GATTSService/Characteristic
      LoPy • lopy ble lopy ble • • neilh93  

      4
      0
      Votes
      4
      Posts
      1336
      Views

      ledbelly2142

      We created a service with multiple characteristics but could only see the first characteristic using BLE scanner.
    • N

      Sending Files from LoPy to Android device (e.g. Phone) via Bluetooth
      LoPy • lopy ble bluetooth lopy ble • • neilh93  

      1
      0
      Votes
      1
      Posts
      987
      Views

      No one has replied

    • S

      BLE Crash
      LoPy • ble • • ssmith  

      4
      0
      Votes
      4
      Posts
      1273
      Views

      S

      Is anything happening with this bug. Every LoPy I update to 1.7.9 now crashes with this error. It wouldn't be as big of an issue if Pycom would let us select which firmware to flash on the board.
    • 1
    • 2
    • 3
    • 4
    • 5
    • 3 / 5