0

I need help debugging the ble settings.

I have a project that uses simple_peripheral and works perfectly. This project was developed last year.

I have a hex file that works perfectly. The problem is that the sdk files were not added to SVN. We only have the ccs files saved.

When I run a new build, BLE does not work. It is possible to detect the peripheral but the device disconnects after connection. And it is not possible to read data from the device.

The project uses RFP Single Ended and EXTBIAS. And it doesn't use the 32kHz crystal.

I suspect that some SDK file has been changed and has not been saved.

How can I check the settings after the project is compiled? Are there any reports generated by the tool?

I am testing a new version of the board in which the tdi and tdo pins have been removed. I can't debug this card, but the old hex file works when programmed on it, so this shouldn't be the problem.

Ilidam
  • 73
  • 6
  • I was able to generate a functional firmware version again. The project works when programmed with ccs debug but do not work when programmed with flash programmer (same hex file). – Ilidam Mar 01 '21 at 13:41

1 Answers1

0

I had the same symptoms with the cc2640r2 on the simple_repipheral project.

In my case it was related to free Heap Memory. The project can work perfectly fine without connecting to any device, but when it connects to a device more Heap memory is used, and it crashes. If it connects to a device then to use notification more heap will be required.

Problem 1: the Heap debugger in ROV does not work with the simple_peripheral settings. In order to ROV to show HeapMem manager, HeapMem has to be activated.

Solution to 1: Go to file the configuration file (TOOLS>app_ble.cfg). There is an import link of the file: ble_stack_heap.cfg . Search for this file and copy-paste the code within this file in app_ble.cfg . Then, you can modify the Heap configuration. Set HeapMem (0x81), to debug it in ROV.

Problem 2: The BLE does reach a stable connection with devices.

Solution to 2: Debugg your project. Debbug your HeapMem before and after trying to connect to a device. Evaluate if there is enough HeapMem after connection.

In my case there was not enough HeapMem after connections. Therefore, I just freed more stack (e.g. reducing Task Stacks) to have more Heap available. This solved my problem.

Dharman
  • 30,962
  • 25
  • 85
  • 135
Desperate Morty
  • 66
  • 2
  • 11