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.

LP-CC2652R7: CC2652R7烧录connecthomeip例程里面的lock-app程序无法连接到树莓派边界路由

Part Number: LP-CC2652R7
Other Parts Discussed in Thread: CC2652R7, UNIFLASH

CC2652R7板子串口打印如下:

#000001 [ 0.039 ] INFO: (led_service.c:191) Registered service, 5 attributes, status 0x00
#000002 [ 0.040 ] INFO: (button_service.c:230) Registered service, 7 attributes
#000003 [ 0.040 ] INFO: (data_service.c:209) Registered service, 6 attributes
#000004 [ 0.041 ] INFO: (project_zero.c:660) Registered OAD Service
#000005 [ 0.041 ] INFO: (project_zero.c:2888) Left button not held under boot, not reverting to factory.
#000006 [ 0.041 ] INFO: (project_zero.c:2890) Right+Left button not held under boot, not erasing external flash.
#000007 [ 0.041 ] INFO: (project_zero.c:678) OAD Image v0001
#000008 [ 0.041 ] INFO: (led_service.c:207) Registered callbacks to application. Struct @200021e4
#000009 [ 0.041 ] INFO: (button_service.c:248) Registered callbacks to application. Struct @200021ec
#000010 [ 0.041 ] INFO: (data_service.c:227) Registered callbacks to application. Struct @200021f4
#000011 [ 0.041 ] INFO: (led_service.c:242) SetParameter : LED0 len: 1
#000012 [ 0.041 ] INFO: (led_service.c:250) SetParameter : LED1 len: 1
#000013 [ 0.041 ] INFO: (button_service.c:289) SetParameter : BUTTON0 len: 1
#000014 [ 0.041 ] INFO: (button_service.c:322) Trying to send noti/ind: connHandle ffff, Noti/ind disabled
#000015 [ 0.041 ] INFO: (button_service.c:300) SetParameter : BUTTON1 len: 1
#000016 [ 0.041 ] INFO: (button_service.c:322) Trying to send noti/ind: connHandle ffff, Noti/ind disabled
#000017 [ 0.041 ] INFO: (data_service.c:265) SetParameter : String len: 40
#000018 [ 0.041 ] INFO: (data_service.c:276) SetParameter : Stream len: 20
#000019 [ 0.041 ] INFO: (data_service.c:298) Trying to send noti/ind: connHandle ffff, Noti/ind disabled
#000020 [ 0.048 ] INFO: (project_zero.c:1161) GAP is started. Our address: D8:B6:73:6C:14:EC
#000021 [ 0.048 ] INFO: (project_zero.c:1179) Name in advertData array: ProjectZero
#000022 [ 0.053 ] INFO: (project_zero.c:1382) Adv Set 0 Enabled
#000023 [ 4.195 ] INFO: (project_zero.c:2628) Button interrupt: Button 1
#000024 [ 4.245 ] INFO: (project_zero.c:1994) Button 1 pressed
#000025 [ 4.245 ] INFO: (button_service.c:300) SetParameter : BUTTON1 len: 1
#000026 [ 4.245 ] INFO: (button_service.c:322) Trying to send noti/ind: connHandle ffff, Noti/ind disabled
#000027 [ 6.896 ] INFO: (project_zero.c:2628) Button interrupt: Button 1
#000028 [ 6.946 ] INFO: (project_zero.c:1994) Button 1 released
#000029 [ 6.946 ] INFO: (button_service.c:300) SetParameter : BUTTON1 len: 1
#000030 [ 6.946 ] INFO: (button_service.c:322) Trying to send noti/ind: connHandle ffff, Noti/ind disabled
#000031 [ 366.585 ] INFO: (project_zero.c:2628) Button interrupt: Button 1
#000032 [ 366.635 ] INFO: (project_zero.c:1994) Button 1 pressed
#000033 [ 366.635 ] INFO: (button_service.c:300) SetParameter : BUTTON1 len: 1
#000034 [ 366.635 ] INFO: (button_service.c:322) Trying to send noti/ind: connHandle ffff, Noti/ind disabled
#000035 [ 369.183 ] INFO: (project_zero.c:2628) Button interrupt: Button 1
#000036 [ 369.233 ] INFO: (project_zero.c:1994) Button 1 released
#000037 [ 369.233 ] INFO: (button_service.c:300) SetParameter : BUTTON1 len: 1
#000038 [ 369.233 ] INFO: (button_service.c:322) Trying to send noti/ind: connHandle ffff, Noti/ind disabled

树莓派搭建的边界路由验证RCP无法通过:

ubuntu@raspberrypi:~$ sudo ot-ctl state
[sudo] password for ubuntu:
connect session failed: No such file or directory
ubuntu@raspberrypi:~$

  • 请问这种问题是我的CC2652R7里面的程序没有烧录正确吗

  • 您好,

    感谢您的提问。

    想请问您的connecthomeip例程是从哪个版本的SDK中的哪个路径下导入的?

  • git clone --recurse-submodules https://github.com/project-chip/connectedhomeip

    用的这个 哪个版本的SDK怎么看 还有导入路径是指的哪个 我是按照TI的教程来编译和下载程序的

  • 在ubuntu下面编译的生成了Hex文件然后通过uniflash烧录到cc2652r7板子 SDK哪个版本不知道怎么看

  • ubuntu@raspberrypi:~$ sudo systemctl status
    ● raspberrypi
    State: running
    Jobs: 0 queued
    Failed: 0 units
    Since: Mon 2023-03-20 22:35:45 CST; 3 months 13 days ago
    CGroup: /
    ├─user.slice
    │ └─user-1000.slice
    │ ├─user@1000.service …
    │ │ ├─user.slice
    │ │ │ └─podman-pause-8178418391264919638.scope
    │ │ │ └─2852 /usr/bin/podman
    │ │ ├─app.slice
    │ │ │ └─dbus.service
    │ │ │ └─2973 /usr/bin/dbus-daemon --session --address=systemd: --nofork --nopidfile --systemd-activation --syslog-only
    │ │ └─init.scope
    │ │ ├─2791 /lib/systemd/systemd --user
    │ │ └─2792 (sd-pam)
    │ └─session-1.scope
    │ ├─2787 sshd: ubuntu [priv]
    │ ├─2948 sshd: ubuntu@pts/0
    │ ├─2949 -bash
    │ ├─3668 sudo systemctl status
    │ ├─3669 sudo systemctl status
    │ ├─3670 systemctl status
    │ └─3671 less
    ├─init.scope
    │ └─1 /sbin/init fixrtc splash
    └─system.slice
    ├─irqbalance.service
    │ └─715 /usr/sbin/irqbalance --foreground
    ├─containerd.service …
    │ └─974 /usr/bin/containerd
    ├─systemd-networkd.service
    │ └─698 /lib/systemd/systemd-networkd
    ├─systemd-udevd.service
    │ └─444 /lib/systemd/systemd-udevd
    ├─cron.service
    │ └─943 /usr/sbin/cron -f -P
    ├─system-serial\x2dgetty.slice
    │ └─serial-getty@ttyS0.service
    │ └─1010 /sbin/agetty -o -p -- \u --keep-baud 115200,57600,38400,9600 ttyS0 vt220
    ├─otbr-web.service
    │ └─1142 /usr/sbin/otbr-web
    ├─networkd-dispatcher.service
    │ └─717 /usr/bin/python3 /usr/bin/networkd-dispatcher --run-startup-triggers
    ├─bluetooth.service
    │ └─988 /usr/lib/bluetooth/bluetoothd
    ├─multipathd.service
    │ └─430 /sbin/multipathd -d -s
    ├─systemd-journald.service
    │ └─400 /lib/systemd/systemd-journald
    ├─unattended-upgrades.service
    │ └─969 /usr/bin/python3 /usr/share/unattended-upgrades/unattended-upgrade-shutdown --wait-for-signal
    ├─ssh.service

  • 边界路由提示这个

    1 raspberrypi otbr-agent: [NOTE]-AGENT---: Backbone interface: eth0
    Jul 3 14:41:21 raspberrypi otbr-agent[2419]: [NOTE]-AGENT---: Running 0.3.0-thread-reference-20230119-238-ga611a780d0
    Jul 3 14:41:21 raspberrypi otbr-agent[2419]: [NOTE]-AGENT---: Thread version: 1.3.0
    Jul 3 14:41:21 raspberrypi otbr-agent[2419]: [NOTE]-AGENT---: Thread interface: wpan0
    Jul 3 14:41:21 raspberrypi otbr-agent[2419]: [NOTE]-AGENT---: Radio URL: spinel+hdlc+uart:///dev/ttyACM0
    Jul 3 14:41:21 raspberrypi otbr-agent[2419]: [NOTE]-AGENT---: Radio URL: trel://eth0
    Jul 3 14:41:21 raspberrypi otbr-agent[2419]: [NOTE]-ILS-----: Infra link selected: eth0
    Jul 3 14:41:21 raspberrypi otbr-agent[2419]: [INFO]-NCP-----: OpenThread log level changed to 4
    Jul 3 14:41:23 raspberrypi otbr-agent[2419]: 49d.17:33:38.807 [W] Platform------: Wait for response timeout
    Jul 3 14:41:23 raspberrypi otbr-agent[2419]: 49d.17:33:38.808 [I] Platform------: Software reset RCP successfully
    Jul 3 14:41:25 raspberrypi otbr-agent[2419]: 49d.17:33:40.810 [W] Platform------: Wait for response timeout
    Jul 3 14:41:25 raspberrypi otbr-agent[2419]: 49d.17:33:40.810 [C] Platform------: Failed to communicate with RCP - no response from RCP during initialization
    Jul 3 14:41:25 raspberrypi otbr-agent[2419]: 49d.17:33:40.810 [C] Platform------: This is not a bug and typically due a config error (wrong URL parameters) or bad RCP image:
    Jul 3 14:41:25 raspberrypi otbr-agent[2419]: 49d.17:33:40.810 [C] Platform------: - Make sure RCP is running the correct firmware
    Jul 3 14:41:25 raspberrypi otbr-agent[2419]: 49d.17:33:40.810 [C] Platform------: - Double check the config parameters passed as `RadioURL` input
    Jul 3 14:41:25 raspberrypi otbr-agent[2419]: 49d.17:33:40.810 [C] Platform------: HandleRcpTimeout() at radio_spinel_impl.hpp:2051: RadioSpinelNoResponse
    Jul 3 14:41:25 raspberrypi systemd[1]: otbr-agent.service: Main process exited, code=exited, status=6/NOTCONFIGURED
    Jul 3 14:41:25 raspberrypi systemd[1]: otbr-agent.service: Failed with result 'exit-code'.
    Jul 3 14:41:30 raspberrypi systemd[1]: otbr-agent.service: Scheduled restart job, restart counter is at 84.

  • 您好,

    CC2652R7 串行端口指出已加载 BLE5 project_zero(LaunchPad 上out-of-box的默认程序),而不是应加载以与 Thread 边界路由器主机 (Thread Border Router host,RPi) 配合使用的 Thread RCP。

    您需要遵循Matter Getting Started Guide和参考 TI Matter Github repository

    您需要在重新编程RCP映像之前使用Uniflash擦除整个程序存储器。

  • 我今天下载了chip-LP_CC2652R7-lock-example-bim.hex这个文件,已经可以串口打印出信息了,打印的信息如下:

    Initialize Server
    Failed to remove advertised services: 3
    Failed to advertise extended commissionable node: 3
    Failed to finalize service update: 3
    Initialize LEDs
    Initialize buttons
    Lock completed
    Unlock initiated
    Unlock completed
    Lock initiated
    Lock completed
    Unlock initiated
    Unlock completed
    Lock initiated
    Lock completed
    Unlock initiated
    Unlock completed
    Lock initiated
    Lock completed
    ÿInitialize Server
    Failed to remove advertised services: 3
    Failed to advertise extended commissionable node: 3
    Failed to finalize service update: 3
    Initialize LEDs
    Initialize buttons
    Lock completed

    我把这个板子通过USB线接在树莓派的USB口上这样可以吗

  • 这个图里面RCP和 Matter Device里面的程序是一样的吗

  • 您好,

    收到工程师回复:

    如果您的LP_CC2652R7连接到Raspberry Pi作为RCP,您为什么要在上面运行chip-LP_CC2652R7-lock-example-bim.hex?不应该在它上运行 RCP 吗?

  • 是的我明白了,但是现在有个问题[FAQ] CC2652R7: Matter -- Getting Started Guide这篇文章里面的下面这个

    这就是RCP文件,我需要烧录到CC2652R1板子里面的,这个为什么访问不了,请问这个如何解决。

  • 这个clang编译器安装CortexM4的安装包或者配置有没有教程能提供一下

  • 您好,

    您可以在一下路径下导入和编译 RCP for CC2652R7:simplelink_cc13xx_cc26xx_sdk_7_10_00_98\examples\rtos\LP_CC2652R7\thread\rcp

    我们也直接给您贴上该附件: rcp_CC26X2R1_LAUNCHXL_tirtos_ticlang.out

    这个clang编译器安装CortexM4的安装包或者配置有没有教程能提供一下

    该新问题和本帖主题无关,为方便他人查询麻烦您重新开帖提问,谢谢您的配合和支持。

  • clang这个截图的问题就是我在CCS IDE里面import simplelink_cc13xx_cc26xx_sdk_7_10_00_98\examples\rtos\LP_CC2652R7\thread\rcp这个工程报的问题

  • 您好,

    这是相关的下载链接:https://www.ti.com/tool/download/ARM-CGT-CLANG/2.1.2.LTS 

    建议您将其直接安装在CCS/SDK的目录下(我这边是ccs1230\ccs\tools\compiler下),然后在CCS中的Window -> Preferences -> Code Composer Studio -> Build -> Compilers中去添加。