Welcome to the Pycom forum Forum
    • \[\[global:header.categories\]\]
    • \[\[global:header.recent\]\]
    • \[\[global:header.tags\]\]
    • \[\[global:header.popular\]\]
    • Login

    Explore Pybytes | Official Documentation | Report a Firmware Bug/Issue | GitHub

    how send string LoPy4 to LoPy4 over Bluetooth LE

    Scheduled Pinned Locked Moved LoPy
    lopy4blebluetoohconnectionsend data
    4 Posts 2 Posters 790 Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M Offline
      manuelC1318
      last edited by

      Hello, I am trying to send text strings between LoPy's using Bluetooth LE, they are already connected, one configured as a client and another as a server, use the example of the manual: https://docs.pycom.io/chapter/firmwareapi/ pycom / network / bluetooth / for the client to read the services and characteristics of the server, but the only thing I want is to be able to send a text string from the server, and be answered by the client. the project will try to send a received string from an app to the lopy.I'm sure it's a simple thing to do but I do not have much knowledge of Python or BLE. I would appreciate your help.

      I'm sure it's a simple thing to do but I do not have much knowledge of Python or BLE. I would appreciate your help.

      J 1 Reply Last reply Reply Quote 0
      • J Offline
        jcaron @manuelC1318
        last edited by

        @manuelc1318 haven’t tried with a LoPy, but the basic principle for communication over BLE is to write to a characteristic (client -> server) and either read or get notifications for server -> client.

        1 Reply Last reply Reply Quote 0
        • M Offline
          manuelC1318
          last edited by

          @jcaron said in how send string LoPy4 to LoPy4 over Bluetooth LE:

          So, is not possible bidirectional communication? my idea is do a kind of chat, over ble is not possible?

          J 1 Reply Last reply Reply Quote 0
          • J Offline
            jcaron @manuelC1318
            last edited by

            @manuelc1318 as I wrote, you can transmit data in both directions: write to a characteristic to send data from client to server, and either read from a characteristic or use notifications for data from server to client.

            1 Reply Last reply Reply Quote 0

            Hello! It looks like you're interested in this conversation, but you don't have an account yet.

            Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

            With your input, this post could be even better đź’—

            Register Login
            • 1 / 1
            • First post
              Last post

            Pycom on Twitter

            Pycom