Firmware not running on custom hardware, working on devkit - nRF5340

Hello, I have the following problem. I am total newbie in nRF programming, so I have minimal knowledge about that hardware.

I have bought nRF5340-DK earlier, firmware on it is working properly.
Then there was created custom hardware for sme that has nRF5340 chip onboard, exactly part number NRF5340-QKAA-R.

There are programming pins onboard next to the chip, that I can use for programming it with following pinout:

So for my purpose there were used pins such as: 3V3, GND, SWDIO, SWDCLK and RESET.

I have used ST-link V2 interface that I have reflashed to J-link, so it acts as J-link now.
I have also downloaded J-link installation, drivers.

So I have created build. Then I flashed it to the nRF chip.
There I had to click to overwrite, as it has protection for writing new firmware (same bahaviour as in case of NRF5340-DK devkit.

Firmware was uploaded, also verification was performed, everything ended with status OK.
But firmware is NOT running. I don't see any Bluetooth broadcast from this chip.
From devkit I see it immediately after programming. 

When I open VS Code from nRF Connect - Toolchain, 
I see J-link interface there and also when I click on it, I see nRF5340 there.
I don't have any COM port in Terminal tab, so I cannot see what board is doing.

About that P0.11/TRACEDATA0 pin, for what it is used? Some kind of debug or serial interface?

I am thinking there I need to upload bootloader or something, but dont know why. Sample named bluetooth can't be compiled for my CPU target. 
Totally I haven't found what I need to download or how to upload bootloader. There is simply no guide for this. Or can it be something else? Please help, how to fix it.

Everything looks like VS Code is communicating with microcontroller, as I see verification and it is okay, so firmware was uploaded into nRF's flash memory.
Tomorrow I can add some output from VS Code during upload etc.

Firmware was identical for devkit or for standalone chip, no changes there.

Parents
  • Looks like everything is there.
    Can't be problem like just app core was uploaded but network one not?
    Some clue how to debug this? I dont have access to any other pins, also there is no LED on the PCB, so I can't blink... with any.


  • Have you tuned your antenna? Or is the matching antenna matching network missing?

    Another thing, I see from the schematic that VDDH is connected to VDD which enables Normal voltage mode. In this mode the inductor L104 is as well as C116 and C117 are not needed, as according to circuit config. no. 2. However, I do not think this necessarily would cause the issue you are seeing.

    You should also make sure to enable the DCDC for Normal mode (VREGMAIN) as well as disable the high voltage regulator (VREGH): 
    CONFIG_BOARD_ENABLE_DCDC_APP=y
    CONFIG_BOARD_ENABLE_DCDC_NET=y
    CONFIG_BOARD_ENABLE_DCDC_HV=n

    If your project contains a bootloader you would have to include the above in the .conf file for the bootlader as well.

    martin.ch said:
    Some clue how to debug this? I dont have access to any other pins, also there is no LED on the PCB, so I can't blink.

    Is perhaps P0.11 on J101 available for blinking an LED?

  • I have tried these macros, but I don't know if my app is using bootloader. Nowhere I see something about bootloader in my application. I have put whole application (except build directory) to https://github.com/martinius96/nRF_test/tree/main/beacon for better view

  • Hi there,

    Håkon is currently out-of-office so I'll support you in the mean time,

    I've read through your case and the earlier replies here, and I have the following comments/questions:

    1. I would like to point out that the only debugger that we officially support is debuggers from Segger, however, I do not think that your current problem is directly related to that. But you should keep this in mind when you continue the development of your project. 

    2. I've looked at your schematic and notices that there is no tuning components for the antenna present on your board. Do you know what kind of antenna that is on your board and whether it has been tuned? This could explain why you're not able to see any advertising signal from the board. 

    3. You should start with a much simpler example from the NCS and confirm that you're able to flash and that it will run properly on your custom board. For example flashing the blinky sample and then measure on the pin and confirm that you see it toggling. 

    4. The readme file in the example that you shared mentions that it requires BlueZ to be running on the host. What have you flashed to the network core of the nRF5340? Most of our BLE samples requires you to flash hci_rpmsg sample to it for the BLE to work. 

    5. Can you share your whole build folder,

    Remember to answer all of the questions above,

    regards

    Jared

Reply
  • Hi there,

    Håkon is currently out-of-office so I'll support you in the mean time,

    I've read through your case and the earlier replies here, and I have the following comments/questions:

    1. I would like to point out that the only debugger that we officially support is debuggers from Segger, however, I do not think that your current problem is directly related to that. But you should keep this in mind when you continue the development of your project. 

    2. I've looked at your schematic and notices that there is no tuning components for the antenna present on your board. Do you know what kind of antenna that is on your board and whether it has been tuned? This could explain why you're not able to see any advertising signal from the board. 

    3. You should start with a much simpler example from the NCS and confirm that you're able to flash and that it will run properly on your custom board. For example flashing the blinky sample and then measure on the pin and confirm that you see it toggling. 

    4. The readme file in the example that you shared mentions that it requires BlueZ to be running on the host. What have you flashed to the network core of the nRF5340? Most of our BLE samples requires you to flash hci_rpmsg sample to it for the BLE to work. 

    5. Can you share your whole build folder,

    Remember to answer all of the questions above,

    regards

    Jared

Children
No Data
Related