本文來源電子發燒友社區,作者:efans_190a9a, 帖子地址:https://bbs.elecfans.com/jishu_2292095_1_1.html
什么是Zephyr?
zephyr操作系統是一個用于資源受限和嵌入式系統的小型內核(出自名門),針對的應用場景,從簡單的嵌入式環境傳感器和可穿戴設備到復雜的嵌入式控制器、智能手表和物聯網無線應用程序。
Zephyr內核支持多種體系結構,包括ARM Cortex-M, Intel x86, ARC, NIOS II, Tensilica Xtensa and RISC-V 32.。
此外個人覺得zephyr的ble statck被廣大芯片廠商所認可,目前主流藍牙芯片一般都已經支持了。
zephyr的ble stack 包含如下 ble central ble peripheral ble hid等等,此外zephyr的ble mesh 也被大家所認可。
https://github.com/zephyrproject-rtos/zephyr/tree/main/samples/bluetooth
- samples/bluetooth/beacon
- samples/bluetooth/broadcaster
- samples/bluetooth/central
- samples/bluetooth/central_hr
- samples/bluetooth/central_ht
- samples/bluetooth/central_multilink
- samples/bluetooth/eddystone
- samples/bluetooth/observer
- samples/bluetooth/peripheral
- samples/bluetooth/peripheral_csc
- samples/bluetooth/peripheral_dis
- samples/bluetooth/peripheral_esp
- samples/bluetooth/peripheral_hids
- samples/bluetooth/peripheral_hr
- samples/bluetooth/peripheral_ht
- samples/bluetooth/peripheral_identity
- samples/bluetooth/peripheral_ots
- samples/bluetooth/peripheral_sc_only
- samples/bluetooth/scan_adv
TLSR9系列在單芯片上支持包括藍牙5.2在內的最領先的物聯網標準和行業聯盟規范,包括基本速率(BR),增強速率(EDR),低功耗(LE),長距離(Long Range),多天線室內定位(AoA/AoD)和Bluetooth^?^ Mesh,Zigbee 3.0,HomeKit,6LoWPAN,Thread和2.4 GHz專有協議。TLSR9標配256KB SRAM和1 MB~2MB Flash,并將高質量無線音頻和可穿戴產品所需的特性和功能整合到單個SoC中,高配版本將包含更多的硬件資源用于對這些產品的支持。
大家可以在Zephyr支持的設備中發現TLSR9系列:
1. 代碼獲取
git clone https://github.com/zephyrproject-rtos/zephyr.git
2下載交叉編譯工具鏈:
http://wiki.telink-semi.cn/tools_and_sdk/Tools/IDE/telink_riscv_linux_toolchain.zip
配置環境變量:
export PATH=$PATH:~/toolchains/nds32le-elf-mculib-v5f/bin/
配置完在中斷輸出riscv32-elf看看有沒有相關gcc之類的提示,有的話說明工作正常。
-
修改 dts配置clock
boards/riscv/tlsr9518adk80d/tlsr9518adk80d.dts
&cpu0 {
clock-frequency = <48000000>;
};
為什么是48M呢,因為外部晶體是24M 經過PLL倍頻后是48Mhz
4.編譯
# From the root of the zephyr repository
west build -b tlsr9518adk80d samples/hello_world
5.接線如圖
6.全部命令如下:
sudo apt update
sudo apt upgrade sudo apt install --no-install-recommends git cmake ninja-build gperf ccache dfu-util device-tree-compiler wget python3-dev python3-pip python3-setuptools python3-tk python3-wheel xz-utils file make gcc gcc-multilib g++-multilib libsdl2-dev
pip3 install --user -U west echo 'export PATH=~/.local/bin:"$PATH"' >> ~/.bashrc source ~/.bashrc
west init ~/zephyrproject cd ~/zephyrproject west update
pip3 install --user -r ~/zephyrproject/zephyr/scripts/requirements.txt
wget https://github.com/zephyrproject-rtos/sdk-ng/releases/download/v0.13.1/zephyr-sdk-0.13.1-linux-x86_64-setup.run
chmod +x zephyr-sdk-0.13.1-linux-x86_64-setup.run
./zephyr-sdk-0.13.1-linux-x86_64-setup.run -- -d ~/zephyr-sdk-0.13.1
sudo cp ~/zephyr-sdk-0.13.1/sysroots/x86_64-pokysdk-linux/usr/share/openocd/contrib/60-openocd.rules /etc/udev/rules.d sudo udevadm control --reload west build -b tlsr9518adk80d samples/hello_world
-
泰凌微
+關注
關注
7文章
153瀏覽量
10863
發布評論請先 登錄
相關推薦
泰凌微電子榮膺2023年Andes晶心科技最具價值客戶
【正點原子STM32H7R3開發套件試用體驗】開發套件開箱報告
泰凌微電子:國內首家獲得Zigbee PRO R23 + Zigbee Direct認證的芯片公司
![<b class='flag-5'>泰</b><b class='flag-5'>凌</b>微電子:國內首家獲得Zigbee PRO R23 + Zigbee Direct認證的芯片公司](https://file1.elecfans.com/web3/M00/01/C2/wKgZPGdYCaGASlpNAAih_r3jhSk271.png)
【星閃派物聯網開發套件體驗連載】智能交通燈
泰凌微電子推出Wi-Fi 6多協議TLSR9118 SoC
泰凌微電子發布Wi-Fi 6多協議TLSR9118 SoC
![<b class='flag-5'>泰</b><b class='flag-5'>凌</b>微電子發布Wi-Fi 6多協議<b class='flag-5'>TLSR</b>9118 SoC](https://file1.elecfans.com/web2/M00/04/89/wKgZombP3z2AXaZxAAJCOnaD2_U269.jpg)
【xG24 Matter開發套件試用體驗】開發環境搭建和開發流程體驗
【xG24 Matter開發套件試用體驗】1-基本情況介紹
低功耗再下一城!泰凌深耕Matter,降低客戶開發門檻、加速產品迭代
![低功耗再下一城!<b class='flag-5'>泰</b><b class='flag-5'>凌</b>深耕Matter,降低客戶<b class='flag-5'>開發</b>門檻、加速產品迭代](https://file1.elecfans.com/web2/M00/FC/71/wKgZomaUgf6AAkoWACIZ6afmkv0840.jpg)
三相全橋RCP開發套件
泰凌微電子發布國內首顆工作電流低至1mA量級的多協議物聯網無線SoC
![<b class='flag-5'>泰</b><b class='flag-5'>凌</b>微電子發布國內首顆工作電流低至1mA量級的多協議物聯網無線SoC](https://file1.elecfans.com/web2/M00/C4/E7/wKgaomXv-xKAIIlqAAAPF0wStoI197.jpg)
泰凌微宣布推出國內首顆工作電流低至1mA量級的無線SoC芯片TLSR925x
![<b class='flag-5'>泰</b><b class='flag-5'>凌</b><b class='flag-5'>微</b>宣布推出國內首顆工作電流低至1mA量級的無線SoC芯片<b class='flag-5'>TLSR</b>925x](https://file1.elecfans.com/web2/M00/C3/E6/wKgZomXvru-AAQNEAABFsJfilhA820.png)
評論