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

Programming 3rd-Party nRF51822

Hello All Slight smile

Since 3 days now, I am trying to program my third party beacon board PTR9048 with the PCA10028. I'm pretty sure, that I connected it correctly, because I can program the SoftDevice on it, and can the it in nRFgo Studio as well. I tried flashing the Beacon_app_example with nRFgo Studio and in Linux via command line.. Flash executes without an error, so I guess it flashes somehow and somewhere. 

I assume, that the problem is either about memory organisation, because the nRF51822 got less RAM or it is about the pin-out of the CUSTOM-BOARD. I read something about this, but in one post there was said, that is not mandatory customizing this. And in additon I read something about crystal speed, but I do not know how to adjust this.

So concluded: Flashing Softdevice and Application works without error, I cannot see device in a Bluetooth Scan, so the example is not working.

Thanks for your help.

Parents
  • Hi,

     

    This module normally does not have an external 32k xtal mounted, so you'll need to adjust this in your sdk_config.h (for SDK 12 and newer) to use the 32kHz internal RC oscillator instead.

    I assume you're using SDK 12.3 or older? Then you do not have to go through the config file. Here's a snippet that should be placed in ble_stack_init that will use the RC osc instead of the external xtal:

        nrf_clock_lf_cfg_t clock_lf_cfg = 
        {
            .source        = NRF_CLOCK_LF_SRC_RC,
            .rc_ctiv       = 16,                                
            .rc_temp_ctiv  = 2,                                
        };    
    
        // Initialize SoftDevice.
        SOFTDEVICE_HANDLER_INIT(&clock_lf_cfg, NULL);

     

    Another thing you have to think about is to alter the linker script to accommodate to the RAM size of your nRF51822 device (subtract 0x4000), but it looks like you already have thought about this.

     

    Kind regards,

    Håkon

     

     

Reply
  • Hi,

     

    This module normally does not have an external 32k xtal mounted, so you'll need to adjust this in your sdk_config.h (for SDK 12 and newer) to use the 32kHz internal RC oscillator instead.

    I assume you're using SDK 12.3 or older? Then you do not have to go through the config file. Here's a snippet that should be placed in ble_stack_init that will use the RC osc instead of the external xtal:

        nrf_clock_lf_cfg_t clock_lf_cfg = 
        {
            .source        = NRF_CLOCK_LF_SRC_RC,
            .rc_ctiv       = 16,                                
            .rc_temp_ctiv  = 2,                                
        };    
    
        // Initialize SoftDevice.
        SOFTDEVICE_HANDLER_INIT(&clock_lf_cfg, NULL);

     

    Another thing you have to think about is to alter the linker script to accommodate to the RAM size of your nRF51822 device (subtract 0x4000), but it looks like you already have thought about this.

     

    Kind regards,

    Håkon

     

     

Children
Related