Skip to content

support for CC2451 ? #1

Closed
Closed

Description

@ericcastro

I spent a good amount of time doing all the wiring only to find out this is not compatible with the CC2451 :-(

would it be too difficult to support it ?

Activity

  1. wavesoft commented on Oct 30, 2015

    @wavesoft
    Owner

    Hello ericcastro,

    the library itself implements the CC Debugger protocol from TI, therefore it should be able to flash the whole CC253x/4x family. However there need to be some changes to the examples, since they were tailored to the BLE112/BLE113 commercial modules (that need a licence key in some particular memory address etc.)

    • The arduino proxy can stay as-is, since it's very low-level
    • The cclib python library provides all the functions you will need
    • Only the cc_write_flash.py needs to be changed in order to match your needs

    In detail you will only need to comment-out the BLE functionality (getBLEInfo + the block of code for checking the license, and getBLEPStoreSize + the block of code to save the PStore).

    If you want to test, modify the cc_info.py and comment-out the lines 46-50. If it displays the correct chip information you are ready to go!

    If it works I can write an alternative write_flash.py script.

  2. wavesoft commented on Oct 30, 2015

    @wavesoft
    Owner

    You will also need to update the chipID guard (ccdebugger.py:95-96)

            if ((self.chipID & 0xff00) != 0x8d00) && (self.chipID & 0xff00) != 0x4100)):
                raise IOError("This class works ONLY with CC2540/2541 TI chips (This is a 0x%04x)!" % self.chipID)
    
  3. ericcastro commented on Oct 30, 2015

    @ericcastro
    Author

    trying this now. will let you know how it goes!

  4. ericcastro commented on Oct 30, 2015

    @ericcastro
    Author

    ok, output looks much better now

    Using CCDebugger on port /dev/tty.usbmodem1421
    
    Chip information:
          Chip ID : 0x4113
       Flash size : 16 Kb
        SRAM size : 1 Kb
              USB : No
    
    Debug status:
     [ ] CHIP_ERASE_BUSY
     [ ] PCON_IDLE
     [X] CPU_HALTED
     [ ] PM_ACTIVE
     [ ] HALT_STATUS
     [X] DEBUG_LOCKED
     [X] OSCILLATOR_STABLE
     [ ] STACK_OVERFLOW
    
    Debug config:
     [ ] SOFT_POWER_MODE
     [ ] TIMERS_OFF
     [ ] DMA_PAUSE
     [ ] TIMER_SUSPEND
    

    let me know if this is correct / expected, and what do we need to flash it. thanks for the help!

  5. wavesoft commented on Oct 30, 2015

    @wavesoft
    Owner

    Hmm.. the device seems to respond properly, however the memory values seems a bit off. This either means that it couldn't read the CHIPINFO0 (0x6276) register (ex. different instructions between the two chips), or the register is actually zero.

    Try to read the CHIPID Register (that should be 0x4113) or any other register that you know it's value in order to check if this is register issue:

    chipid = dbg.readXDATA(0x624A, 1)
    print "0x%04x" % chipid[0]
    
  6. ericcastro commented on Oct 30, 2015

    @ericcastro
    Author

    thanks, I already left home for work but will try this tonight and will let you know.

  7. ericcastro commented on Nov 1, 2015

    @ericcastro
    Author

    ok I tried this and not getting anything very interesting so far
    the lines:

    chipid = dbg.readXDATA(0x624A, 1)
    print "0x%04x" % chipid[0]
    

    will output:

    0x0000
    

    also, I uncommented some of the output lines you mentioned to remove just to see if there was anything there, I got:

    Device information:
     IEEE Address : 000000000000
               PC : 0000
    
    Firmware information:
          License : 0000000000000000000000000000000000000000000000000000000000000000
       BT Address : 00:00:00:00:00:00
     Hardware Ver : 00
    

    I suspect there could be something wrong with the wiring I made ? I may have misunderstood something with the voltage dividers maybe ? Here is a picture of my breadboard so you can take a look as well if you want:
    http://i.imgur.com/8yU1WNQ.jpg

    and this is my pin config in CCLib proxy on my Leonardo:

    int LED      = 13;
    int CC_RST   = 10;
    int CC_DD_I  = 8 ;
    int CC_DD_O  = 7;
    int CC_DC    = 9;
    
  8. wavesoft commented on Feb 1, 2016

    @wavesoft
    Owner

    Hello @ericcastro, sorry for my late reply, but I was a bit buried with work.
    I see some problems with your wiring (top right voltage divider).

    You can check this diagram for reference:

    Let me know if you manage to get this working in order to update the my compatibility table ;)

  9. wavesoft commented on Dec 24, 2016

    @wavesoft
    Owner

    Hey @ericcastro do you have any update on this? Otherwise I will close this issue.

  10. ericcastro commented on Dec 27, 2016

    @ericcastro
    Author

    oh, I'm sorry I never did reply. Actually I was able to use a different utility (CCLoader by RedBearLabs) in order to successfully flash my CC2451 - so from my end this is no longer relevant.

    Thanks - Eric

  11. wavesoft commented on Dec 27, 2016

    @wavesoft
    Owner

    Thanks for the reply @ericcastro

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions