This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Set up specific BLE devices to communicate either without pairing or with automaticly pairing

Hello. I have several nRF51 devices (nRF51 Dongle, pca10031) I wish to use as BLE link between robots.

  1. Is there any examples or tutorials that show how I can do this without having to pair the devices manually using some sort of software first?

  2. I was thinking about hard coding the addresses in but I am not sure if this is the best solution or even feasible?

  3. What would be the best option, broadcast to all or send to specific device?

Edit: I am not bound to use BLE, I can use the radio "alone" as well

Parents Reply Children
  • Regarding peripherals and central device, does this imply that I need to use the S120 soft device for the server and S110 for the robots?

    I was thinking that it would be better to have only one version with software for the nrf device, where I have some sort of function or switch/case to detect wether it is in a robot using spi, twi, or uart (pc) but this may be more complicated than i can comprehend - what is your opinion on this?

    I am going through the BLE tutorials now so hopefully I will get a better grasp on how to solve it.

  • It does not. The S110 supports peripheral role only. The S120 supports peripheral and central role but not concurrently, and as a central it can have links to 8 peripherals at the same time. The S130 supports concurrent peripheral and central role, but the release (2.0.0-7.alpha) that has SDK support can as a central only have links to 3 peripherals at the same time. The latest release (2.0.0-8.alpha) can as a central have links to 8 peripherals at the same time. It is a bit hard to use atm., but I have made an example here.

    So, you can use the same SoftDevice on both sides, but if I were you I would have a separate application for the robots. I don't see any big advantage of mixing the applications and then detecting which of them are going to be used.

  • I'm also not sure what kind of application you need on the PC. What kind of control are we talking about. If it is only sending simple commands maybe you could get away with using Master Control Panel, but this only supports one connection, i.e. only allows you to control one robot at the time. We are working on a new tool that will allow you to be connected to multiple peripherals, Yggdrasil, but the current version doesn't support sending any data, it only supports connection and service discovery. The best option is maybe the BLE driver for Windows, available here. It allows you to control the SoftDevice over UART. The latest release uses S130 1.0.0, so as a central it can be connected to 3 peripherals.

  • Version 0.4.1 of the BLE driver supports SoftDevice S120, so it should be capable of having 8 peripheral connections.

  • I (or we, we are a group) are going to have a java program on pc that will recieve measurements from- and then send instructions back to each robot, 3 or 4 of them.

    Preferably I want to get away with not having to run any other software than this java program and the drivers, so I figured I could use the UART BLE example and communicate through the serial ports.

    This is sort of allready solved, but we had to pair the devices first. I'd rather have the adresses for each robot in the nrf software and somehow include which instruction goes to what robot with a switch case or something similar. I have not yet figured out how to do this.

    It is very important that this is concurrent, each robot is running real time schedulers on a separate mcu and will ideally return measurements, encoder information and need new instructions every 200ms..

    If this is very complicated I'd love to know :)

Related