This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Custom Board: CCDebugger+Debug works, w/o debugger no worky, same code on USBdongle works

Other Parts Discussed in Thread: CC2540

I'm testing the sample KeyFob code to validate my custom hardware (a breakout board) is functional and have ported it over to the CC2540Dongle (changed the target and target library). Custom board is built using the datasheet but matches the CC2540Dongle schematics minus a couple 100nF caps indicated on the VCC lines.

The code works perfectly on the USB dongle - compiles on IAR, can push a button (S2) to advertise. Also, if I debug with the CCDebugger on either the CC2540Dongle or my custom board, the program works just fine.  But, it does not work if I unplug the CCDebugger or try to let the code run on its own (i.e. not through debug but just program it).

The "program" I'm running, I just vary the LED pin from P0_0 to P0_1 to test if the code works or to one of the testpins (ex. P0_5 on dongle).  The "button press" for advertising doesn't work on the custom board, even in debug - not sure why as it's just bringing the pin low. 

Notes:

  1. Tested 32MHz oscillator with o-scope, see the 32MHz waveform in 10x mode, with a trigger, 0.05us, spans ~6 units width, 40mVPP
  2. Reference voltages seem to check out 1.26V (RBias) and 1.86V (DCOUPL)
  3. Strange high (3.3V) registering on P1_7 for no reason on custom board
  4. CCDebugger can recognize and program either boards just fine

Kinda pulling my hair out on this one and have googled and checked through forum without indication of solution.

  • Hi Chris,

    Could you share your schematic and layout files? Could you also measure the voltage on all VDD pins when the debugger is not connected to you custom board?

    Cheers,
    Fredrik

  • VDD Pins: 3.18V

    RBias: 1.26V

    Cdcoupl: 1.85V

    This setup is currently supplied by a 3.3V wall plug.

  • Extra notes: P0_2 is 0.88V, P1_7 is 3.17V

    I'm using the KeyFob code with target CC2540.  Chip is CC2540F256.

    Jumpers on: AVDD, DVDD, DD, DC, RN

  • Hi Chris,

    Are you sure there is no contact between the via pads in the EGP and the CC2540 pins? The copper opening looks really small.

    Why are you powering all the VDD pins individually? Also, you are not exactly following the reference design layout. All supply pins should have proper decoupling close to the pins (you wrote that a couple of 100nF caps were missing, but you actually do not have any decoupling at all). It would not hurt to make the VDD trace from the battery connector and to the jumpers much wider either.

    Additionally you should not run signal traces underneath the RF traces. The balun should be place as close to the CC2540 as possible as it is much easier to control the impadance of the 50 ohm unbalanced trace than the balanced lines.

    Cheers,

    Fredrik

  • I did a continuity check and they are not touching.  I have an updated iteration with wider widths but wanted to provide the schematic/layout of what I'm actually testing.


    I broke everything out individually, didn't have to for the power pins.  You may be asking about that so the balun could be moved closer, and I agree, but I guess I didn't even get that far so I wasn't worried about it.

    Nothing obvious points to the layout as all the reference values seem to be correct.  I agree I should have put some more decoupling caps in there as I had designed this one based off the datasheet versus the reference designs.  I can hook up some through hole caps to test, but you think that would make a difference?  Guess it's worth a try.  I was also contemplating using different code but I don't even really see a reason - if anything I'll just rip out all functionality from the KeyFob base.

  • I guess when things aren't working and you have no idea what's going on... build another board.

    I built another one and it's working.  I had 3 built and and must have been a similar issue.  I don't know why... oven issue or something but I built this one with a heat gun and it works beautifully!

    Sorry for the waste of time.  Thanks for your time!

    -Chris