Part Number: CC2640
Other Parts Discussed in Thread: CC2540EMK-USB
Hi,
First, some context :
Last year, I developed a custom board powered by CC2640 and some sensors for H.R measurements. At this time, the latest SDK was 2.1.1 so I used the HeartRate exemple and add a MAX30100 implementation. My firmware works great.
Now I need to implement the OAD feature to my firmware, so I read couple times the BLE OAD User guide in the SDK (2.1.1). I followed every step in off-chip OAD and I got two "bug" and after searching on the web and RTFM again and again, I'm feeling a little bit confused:
First bug :
I successfully installed python 2.7 and IntelHex script, I added commands lines under "step" tab and I can generate SUPER_IMAGE_FULL.hex (BIM+App+Stack) - ref 8.3 in the user guide.
But when I'm try to program my board with Flash Programmer 2 (1.6.2) I got an error during verification(error page 4).
With BLE device monitor (2.3.0), the CC2540EMK-USB programed with "Host" prog, scan nothing.
Second bug:
To avoid to be block, I tried a new methodology. With CCS, I program my board 3 times : BIM in first, after the stack and the app to finish.
On BLE device monitor, I successfully find my custom board and I can connect to them.
I can see the OAD services :
| 0x48 | 72 | 0x2800 | GATT Primary Service Declaration | F000FFC0-0451-4000-B000-000000000000 | R | OAD Service |
| 0x49 | 73 | 0x2803 | GATT Characteristic Declaration | 1C:4A:00:00:00:00:00:00:00:00:B0:00:40:51:04:C1:FF:00:F0 | R | OAD Image Identify |
| 0x4A | 74 | 0xFFC1 | OAD Image Identify | WN | Write '0' to identify image type 'A', '1' to identify 'B'. Data in notfication 8 bytes: image type (2), size/4 (2), user data (4). | |
| 0x4B | 75 | 0x2902 | Client Characteristic Configuration | RW | Write "01:00" to enable notifications, "00:00" to disable | |
| 0x4C | 76 | 0x2901 | Characteristic User Description | R | ||
| 0x4D | 77 | 0x2803 | GATT Characteristic Declaration | 1C:4E:00:00:00:00:00:00:00:00:B0:00:40:51:04:C2:FF:00:F0 | R | OAD Image Block |
| 0x4E | 78 | 0xFFC2 | OAD Image Block | WN | Image block (18 bytes). Block no. (2 bytes), OAD image block (16 bytes) | |
| 0x4F | 79 | 0x2902 | Client Characteristic Configuration | RW | Write "01:00" to enable notifications, "00:00" to disable | |
| 0x50 | 80 | 0x2901 | Characteristic User Description | R | ||
| 0x51 | 81 | 0x2803 | GATT Characteristic Declaration | 0C:52:00:00:00:00:00:00:00:00:B0:00:40:51:04:C3:FF:00:F0 | R | OAD Image Count |
| 0x52 | 82 | 0xFFC3 | OAD Image Count | W | Number of images expected to be downloaded (1 byte) | |
| 0x53 | 83 | 0x2901 | Characteristic User Description | R |
When I try to program, I choose the OADApp.hex, configure 1 Blk/conn, click on Start....and nothing :
12:30:40.838 > OAD started
12:30:40.854 > WriteRsp[FFC1]: st=0 n=0
wait 5 minutes, and still nothing.
I really don't have an idea on what's going on. Someone have a clue ?
regards
mRabla