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

Using nRF51422 for sending bluetooth packets

Hi, I started using the nRF51422 kit today. Downloaded nRFgo Studio, Master Control Panel, nRF Connect, BLE Sniffer, Wireshark 1.10 (after figuring out that you don't support higher versions), Keil µVision, S110, S120, S130 stacks, and nRF5-SDK files.

I ultimately need to make a program that can transmit acquired data over bluetooth from the chip, but of course I want to test the templates first to understand the functionality.

To test the kit I installed the SDK zip files package in µVision, and ran the peripheral_blinky example. So far so good, the LEDs changed at the 20 Hz frequency I set them to. Now I wanted to test the chip's bluetooth connectivity, so I followed the guides laid out in the ble_peripheral_app_beacon example. I configured it to build the flash softdevice and not the default application. When I turned it on, no LEDs were flashing. I opened Master Control Panel and connected through the COM port, but it didn't find any signals. I then tried with nRF connect and Wireshark with the same null results.

It seems most likely that I'm completely misunderstanding the application of this chip and/or the SDK templates, but I just can't figure out how to get this chip to send anything over bluetooth to my computer. Help?!

  • Hi,

    The softdevice target in Keil only flashes the softdevice, you will have to flash the application in addition afterwards.

    I would recommend you to go through the tutorials here on DevZone, especically the getting started tutorial and the BLE tutorials, to learn more about the use of our chips and how to setup BLE communication.

    Best regards,

    Jørgen

  • Thanks for the quick reply, Jørgen. I'm now following the BLE advertising tutorial from that list, but I've hit another stumbling block. I was under the impression that you could find the bluetooth device from your computer, but it seems from all the tutorials that you either need the dongle, or a BLE compatible phone...Is there no way to just connect the chip to a computer through TeraTerm (or Termite as you suggested in the tutorial)?

  • If you want to follow the tutorials, you need a BLE enabled phone or a nRF51-DK/nRF51 Dongle to use with Master Control Panel (MCP). Recently, MCP have been replaced by nRF Connect for desktop. This also support nRF52-DK for interfacing with BLE devices. If your PC have a BLE enabled Bluetooth interface, you can connect to devices using this, but you will have to create your own application or driver. If you have your kit (I'm assuming you are using the nRF51-DK?) connected to your computer, you can communicate with the device throug UART (using Termite or TeraTerm), if this is setup in the application in the board. This will not have any connections to the BLE part.

  • Even the UART doesn't seem to work. I loaded ble_att_uart_c_s130_pca10028 into µVIsion, loaded the flash softdevice, then changed to the application, and loaded that. LED1 is blinking at 0.5 Hz as it's supposed to according to the guide, but nothing happens in Termite. I tried both setups; RTS/CTS flow control and Status LEDs, and then enabling the RTS in the terminal. Nothing. Then I tried removing flow control and status LEDs from the terminal, and disable flow control in the uart_init function. Still nothing. Note: The example used a baud rate of 115200, while the program I used is 38400. As long as uart_init and Termite setting is the same, I assume it doesn't matter.

  • The ble_app_uart_c example does not write anything to the terminal, unless it receives something over BLE from a connected board. Can you try the ble_app_uart example found in <SDK_folder>\examples\ble_peripheral\ble_app_uart? This should print UART Start! to the terminal on startup.

Related