I used the previous version of the SDK (telink_b85m_ble_sdk_alpha_v4.0.0) and my code worked fine.
The only problem I had that I couldn't set the default pincode in the chip.
In Single Connection SDK I used smp_param_own.paring_tk to do this, but there is nothing in the v4.0.0.0.
I have installed new SDK v4.0.1.1, and I noticed that it has a function blc_smp_setDefaultPinCode(PIN_CODE), which was missing from the previous version.
So I put my code in the new SDK, with any changes required for the new SDK and downloaded it to the chip. Since I am using TLSR8251, I can only use one master and one slave. I am using security level LE_Security_Mode_1_Level_3.
I can connect my phone to the chip in the slave role and it works fine.
The problem I get is when I connect the chip in the master role to another device (slave). The chip connects OK, but it stops receiving data from the PC via UART. It sends debug messages to the PC via UART, so I can see that the chip is running, but it doesn't receive anything.
What can be an issue? I didn't have this problem with the previous SDK.
Is there a way to set the default pincode in the older SDK?
By the way, the firmware file was much smaller with the older SDK for the same configuration.
The second issue that I noticed.
I have tried to build the source code in 825x_m1s1 folder with the default project settings using - DMCU_STARTUP_8258_RET_32K.
When I build, I get an error:
../boot.link:123: undefined symbol `_ramcode_size_div_256_' referenced in expression
make: *** [b85m_ble_sdk.elf] Error 1
When I change -DMCU_STARTUP_8258_RET_32K to -DMCU_STARTUP_8258, it compiles OK.
When I look in the startup_8258_RET_32K.S file, _ramcode_size_div_256_ is commented out, so, I wasn't surprised that it failed
Here is part of the startup_8258_RET_32K.S file:
DAT0:
.word 0x12 @IRQ @0
.word 0x13 @SVC @4
.word (irq_stk + IRQ_STK_SIZE)
.word (0x850000) @12 stack end
.word (_start_bss_) @16
.word (_end_bss_) @20
.word (0x80060c) @24
.word (0x848000) @28
.word (0x848100) @32
.word (0x80) @36
@ .word _ictag_start_ @28 @ IC tag start
@ .word _ictag_end_ @32 @ IC tag end
@ .word _ramcode_size_div_256_ @36
DATA_I:
How to fix this issue?
Any help with both issues would be greatly appreciated.
No related topics |
Some additional information.
Below are some logging messages after the connection to the slave, sent via UART to PC. The messages are in the same parts of the code for both older and latest SDK
SDK V4.0.0.0
14:33:45.806 [TX] - dev4 ***CONNECT COMMAND SEND FROM PC
14:33:45.817 [RX] - dev4 ***COMMAND SEND BACK TO PC
evtCode 3E 02
14:33:56.636 [TX] - dis4 ***DISCONNECT COMMAND SEND FROM PC
14:33:56.641 [RX] - dis4 ***COMMAND SEND BACK TO PC
Message Log for SDK 4.0.1.1
15:01:17.489 [TX] - dev4 ***CONNECT COMMAND SEND FROM PC
15:01:17.497 [RX] - dev4 ***COMMAND SEND BACK TO PC
15:01:35.076 [TX] - dis4 ***DISCONNECT COMMAND SEND FROM PC
15:01:41.307 [RX] - run
I wrote some comments in bold at some relevant places.
Since there is no source code for compiled libraries I can't do anything else.
Hi Wes,
It has been golden week(national holidays) since Oct 1st, our engineer will come back to you soon.
Hi wes58
(1)b85m_ble_sdk_V4.0.1.1 support 8253/8258/8273/8278 chip. 8251/8271 chip is not supported, because 32K SRAM is not enough.
(2)Because b85m_slave and b85m_m1s1 support deepsleep retention mode. Before compiling them, copy b85m_ble_sdk\boot\boot_32k_retn.link to b85m_ble_sdk\boot.link.
Hi,
Thank you for your response.
re (1)
Maybe you should update your "Telink BLE Multi-connection SDK Developer Handbook" because it is referencing 8251 as available for 1-master and 1-slave?
And, it still uses functions that are used in the Single Connection SDK.
If I knew that, I wouldn't have wasted so much time trying to find out what is wrong!
I would be happy to use SDK V4.0.0.0 (although it is Alpha) if I was able to set my own pincode.
The handbook, still describes the method used in Single Connection SDK (using: smp_param_own.paring_tk). How hard would it be to add it to this SDK (or add source code to the project)? You have a source code, so you know if this can be done.
If it is not possible, I just have to forget about using Multi Connection SDK.
re (2)
After the changes that you mentioned I can compile the project. Although, since I can t use 8251 chip, it is not useful to me
Thanks for you help.