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

Cannot get my custom board to run.

I am using a Fanstel BT Module BT832F (that utilizes the Nordic nrf532832 chip).  I am able to successfully run my code on Nordic's dev board PCA10040 and also Fanstel's dev board BT832F with no issues.  I finally received in my custom boards and I am struggling trying to get them to run the code.  I've been starting at schematics for hours and cannot see what I have missed or screwed up.  I can program the chip just fine, however instead of giving me a pause at main(), and allowing me to single step through the program, it just states "running".  When pausing the device, it brings me to the disassembly view and is always stuck at address 0x00015CCE with the instruction "sev".

I'm assuming it is stuck somewhere in the softdevice, or bootloader but not sure where to begin.

I first suspected (and still do) something with my low power xtal.  I do have a 32.768kHz xtal in there with two 12pF caps.  Putting a scope on there, it is flat lined.  Digging a bit deeper, I believe I didn't spec in the proper caps/xtal and it is not loaded correctly.  I have a XTAL with a 12pF load capacitance rating, where I should have an XTAL with a 9pF or so rating.  I've tried swapping the XTAL out but my lack of SMD rework tools have made that a challenging task.  I've also tried to change the code to use an RC clock source and still experiencing the same results.  Although I'm not sure I changed it in the correct location(s).

This is my first time using Nordic tools.  The library has been solid, but I feel it is a bit confusing adding in new library pieces/drivers into your project.  I'm not sure if I am missing something with the softdevice or on my hardware end.  Any help would be appreciated as I'm going crazy trying to figure this out.

Hopefully you can see those images.  When they uploaded in my preview, they looked grainy on the conversion.

  • I've just tried running the Nordic Blinky example.  No BLE.  First tried the one with the softdevice and that had the same "hang" issue.  I then tried the same blinky example with no soft device, and it is now running as expected.

    How do these dev boards come loaded?  Do I have to install the softdevice independent of my project?  I am using Segger Embedded Studio for ARM V4.5.  I am assuming that when I started my project from the BLE template, that it has the softdevice all linked into my project and when I compile and program, it drops it into my chip every time.  Is that not the case?

  • Yes, you'll need to flash the SoftDevice as well. 


  • If your crystal is specced at 12pF you'll need 20pF loading caps.

    The formula is as follows: Cl1 = Cl2 = 2 * Crated - (Cstray + Cpad), where Cstray + Cpad = 4pF.

    Your oscilloscope probes are most likely 12pF probes themselves so you end up with 12pF + 12pF = 24pF when scoping the crystals. 24pF is probably outside of what the oscillator is able to drive. 

    I recommend using a crystal with a lower specced loading capacitance than 12pF, and fit the loading capacitor to your probe's capacitance when you're probing. An alternative is using an active probe. 

  • Flashing just the SoftDevice didn't fix it either.  I went into J-Flash Lite to verify what areas were being programmed when.  I then decided to do an entire chip erase all, verified it was completely blank and then start over.  I went into the Blinky example with the S132 SoftDevice and programmed the chip.  To my surprise I now had a blinky light.  I then was able to close out of that project, open my application, and program the chip.  It is now running as expected.  I'm not sure what happened, but for some reason the SoftDevice, Bootloader, or something else was corrupted or causing me issues.  Erasing the entire chip and then programming fixed the issue for me.

Related