Create your Gitee Account
Explore and code with more than 13.5 million developers,Free private repositories !:)
Sign up
Clone or Download
contribute
Sync branch
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
a year ago
Loading...
README
GPL-2.0

OpenHarmony NearLink WS63 案例集

license OS platform platform SDK SDK platform build

版权

Copyright (c) 2024, Qi Yaolong.
dragon@hbu.edu.cn
HeBei University, China.

简体中文

保留所有权利。依据GPL 2.0(以下简称"本许可")进行许可。除非符合(遵守)本许可及以下条款,否则您不得使用此案例集:

禁止任何未经授权的个人或组织以任何形式将本案例集及其附属资料、创新、创意、架构设计、算法、衍生作品等用于任何商业目的、盈利活动、各类竞赛(比赛)、直播教学、录播教学、线下课程、书籍编写、教材编写、会议、培训、公益活动、项目课题、毕业设计、毕业论文、学术论文等。

本程序由版权持有人和贡献人“按原样”提供,不提供任何明示或暗示担保,包括但不局限于对适销性和特定用途适合性的暗示担保。在任何情况下,版权持有人或贡献人对因使用本程序而导致的任何直接、间接、附带、特殊、典型或后果性损害(包括但不限于购买替代商品或服务;使用损失、数据丢失或利润损失;业务中断)不承担任何责任,无论其如何产生,也不论其责任理论为何,无论是合同、严格责任还是侵权(包括疏忽或其他),即使已告知此类损害的可能性。

English

All rights reserved. Licensed under the GPL 2.0 (the "License"). You may NOT use these cases except in compliance with the License and the following terms:

IT IS PROHIBITED FOR ANY UNAUTHORIZED PERSON OR ENTITY TO USE THIS PROGRAM AND ITS ANCILLARY DATA, INNOVATIONS, CONCEPTS, ARCHITECTURE DESIGN, ALGORITHMS, DERIVED WORKS, ETC., IN ANY FORM FOR COMMERCIAL PURPOSES, PROFIT-MAKING ACTIVITIES, VARIOUS COMPETITIONS (CONTESTS), LIVE TEACHING, PRE-RECORDED LESSONS, OFFLINE COURSES, BOOK WRITING, CONFERENCES, TRAININGS, PUBLIC WELFARE ACTIVITIES, PROJECTS, TOPICS, GRADUATION DESIGNS, DISSERTATIONS, THESES, AND OTHER APPLICATIONS.

THIS PROGRAM IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS PROGRAM, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

SDK版本

  • 星闪OpenHarmony SDK(oh_sdk_20240628)
  • 星闪OpenHarmony SDK(oh_sdk_20241021)

编译环境+快速烧录工具

移步海思社区下载:下载链接

适用开发板

核心板

  • 小熊派H3863
  • 小熊派BM-H63
  • NearLink_DK_WS63E
  • NearLink_DK_WS63

开发套件

  • 星闪+OpenHarmony物联网实训套件
  • 星闪派物联网开发套件

技术合规性

本案例集遵循以下技术标准、技术协议和技术规范:

  1. OpenHarmony开发者文档。
  2. SparkLink团体标准:T/XS 30001-2023、T/XS 20002-2022、T/XS 20002-2023、T/XS 20004-2022、T/XS 20003-2022、T/XS 20001-2022、T/XS 30002-2023、T/XS 30003-2023、T/XS 00002-2022、TR/XS 00001-2021 等。
  3. WS63V100芯片手册。
  4. 星闪+OpenHarmony物联网实训套件手册。
  5. 小熊派H3863开发板手册。
  6. NearLink_DK_WS63E开发板手册。
  7. 光敏电阻GL5537-2技术手册。
  8. 人体红外传感器AS312技术手册。
  9. 温湿度传感器AHT20技术手册。
  10. 可燃气体传感器MQ-2技术手册。
  11. SSD1306 Advance Information。
  12. SK6805-EC20技术手册。

技术侧重点

  1. 星闪OpenHarmony SDK的全面打磨完善。
  2. SparkLink团体标准的深入分析及工程运用。
  3. 业内尚未公开的星闪自身新能力的设计及实现。
  4. 各种规模的分布式星闪网络的构建和优化。
  5. 星闪芯片自身能力的全面发掘及应用。
  6. SLE对BLE的完全对标与能力、场景替代。
  7. 可复用模块、星闪项目模板的开发,即造轮子。
  8. 对初学者友好的、系统、科学的星闪知识体系构建。

技术淡化点

本案例集聚焦于星闪技术本身。以下技术与星闪技术无关,且外延纷繁复杂,因此不在本案例集的侧重点范围内。

  1. 各种外围(开发板以外的)硬件设备的驱动和控制。
  2. 硬件板卡的设计和制造。
  3. 星闪通讯所承载的具体业务数据内容。

案例集内容

序号1-43聚焦星闪开发板和SDK基础能力,与星闪技术无关,不收录在本案例集中。序号44-66聚焦星闪SLE五大核心能力、技术优势和应用场景。每个序号内可能包含多个案例。

序号 目录 类型 案例个数 简介
1 startup 标准案例 1 入门案例。演示如何使用星闪OpenHarmony SDK,实现一个简单的Hello World程序。
2 gn_practice 标准案例 1 组件/模块开发标准案例。
3 kvstore_demo 标准案例 1 键值存储标准案例。
4 file_demo 标准案例 1 文件操作标准案例。
5 thread_demo 标准案例 2 线程管理标准案例。
6 feature_template 通用模板 1 feature模板,用于快速创建新的feature案例。
7 delay_demo 标准案例 1 通用等待功能标准案例。
8 timer_demo 标准案例 2 定时器管理标准案例。
9 mutex_demo 标准案例 1 互斥锁管理标准案例。
10 semaphore_demo 标准案例 2 信号量管理标准案例。
11 message_demo 标准案例 1 消息队列管理标准案例。
12 led_demo 标准案例 2 GPIO输出电平标准案例。
13 gpio_input_demo 标准案例 3 GPIO按键输入标准案例。
14 pwm_demo 标准案例 6 PWM输出方波标准案例。
15 adc_demo 标准案例 5 通过ADC获取模拟传感器的数据。
16 i2c_demo 标准案例 2 通过I2C获取数字温湿度传感器的数据。
17 oled_demo 标准案例 3 OLED显示屏的驱动和控制标准案例。
18 ssd1306_3rd_driver 可复用模块+标准案例 2 OLED屏驱动库模块及相应案例。增强了功能和易用性。
19 qrcode_gen 可复用模块+标准案例 2 二维码生成器模块及相应案例。二维码生成器模块是一个可重用的、易用的二维码生成器,支持按倍数缩放。
20 uart_demo 标准案例 4 通用串行总线基础案例集。
21 uart_p2p 标准案例 1 两块开发板通过UART2进行点对点通讯。
22 json_demo 标准案例 1 JSON开发标准案例。
23 hard_random_gen 标准案例 1 硬件真随机数生成标准案例。包括测速计算。
24 easy_cipher 可复用模块+标准案例 2 EasyCipher模块及其应用示例。EasyCipher模块是一个可重用的、易用的加密解密模块,支持AES加密解密算法。
25 wifi_demo 标准案例 3 Wi-Fi开发标准案例。
26 easy_wifi 可复用模块+标准案例 3 EasyWiFi模块及其相应案例。让星闪WiFi功能更容易使用。使用原始WiFI API接口进行编程,整个过程稍显繁琐,为此对原始WiFi API接口做了一层封装,形成了一套更简单易用的接口。
27 tcpclient 标准案例 1 TCP客户端编程标准案例。
28 tcpserver 标准案例 1 TCP服务端编程标准案例。
29 udpclient 标准案例 1 UDP客户端编程标准案例。
30 udpserver 标准案例 1 UDP服务端编程标准案例。
31 ntp_demo 标准案例 1 使用NTP协议同步时间标准案例。
32 soft_rtc 可复用模块+标准案例 2 SoftRTC模块及其相关案例。软件RTC,精确到us级别。可以进一步精确到ns级别。
33 http_client_demo 标准案例 1 HTTP客户端基础案例。展示HTTP协议基本原理。
34 easy_http_client 可复用模块+标准案例 2 EasyHttpClient模块及其相应案例。EasyHttpClient模块是一个可重用的、易用的HTTP客户端模块,支持HTTP(S) GET、POST请求。
35 easy_httpd 可复用模块+标准案例 2 EasyHttpd模块及其相应案例。EasyHttpd是一个轻量级的HTTP服务器,支持GET和POST请求,支持静态文件和动态文件,支持SSI、CGI。
36 paho_mqtt 可复用模块 1 OpenHarmony兼容版paho.mqtt.embedded-c模块。
37 mqtt_demo 可复用模块+标准案例 2 MQTT客户端编程模块及标准案例。本案例提供的mqtt_task模块,对MQTTClient-C库进行了二次封装,提供了一套更简单的接口实现MQTT的连接、发布、订阅、取消订阅、断开等功能。
38 mqtt_light 标准案例 1 MQTT灯光控制标准案例。
39 mqtt_light_sensor 标准案例 1 MQTT环境光采集标准案例。
40 mqtt_human_sensor 标准案例 1 MQTT人体感应标准案例。
41 mqtt_gas_sensor 标准案例 1 MQTT可燃气体报警标准案例。
42 mqtt_temp-humi_sensor 标准案例 1 MQTT温湿度收集标准案例。
43 mqtt_oled 标准案例 1 MQTT广告屏标准案例。
44 radar_demo 标准案例 1 星闪雷达标准案例。
45 radar_led 标准案例 1 星闪雷达人体感应指示。感应到人体在0-1米范围内,红黄绿LED同时点亮;在1-2米范围内,黄绿LED同时点亮;在2-6米范围内,绿色LED点亮。感应不到人体,LED熄灭。
46 radar_linger_warn 商业项目 1 危险区域人员逗留提醒系统。人员持续逗留在危险区域,可能会导致危险事件的发生。本项目展示了如何使用NearLink_DK_WS63E星闪开发板和OpenHarmony SDK实现危险区域人员逗留提醒功能。可用于完全无光环境。适用于公共服务、建筑工地、危险作业、敏感设施、突发事件等各类场景。
47 sle_demo_1v1 标准案例 (项目模板) 2 星闪1v1标准案例。一个客户端和一个服务端使用星闪SLE能力发送/接收数据。遵循SparkLink团体标准。对客户端和服务端进行封装,更易用。可以作为项目模板,适用于各种星闪1v1通讯场景。
48 sle_demo_1vn 标准案例 (项目模板) 2 星闪1vn标准案例。一个客户端和多个服务端使用星闪SLE能力发送/接收数据。遵循SparkLink团体标准。对客户端和服务端进行封装,更易用。可以作为项目模板,适用于各种星闪1vn通讯场景。
49 sle_uart_demo_1v1 标准案例 2 星闪1v1转发串口数据标准案例。一个客户端和一个服务端使用星闪SLE能力转发串口数据。对客户端和服务端进行封装,更易用。
50 sle_uart_demo_1vn 标准案例 2 星闪1vn转发串口数据标准案例。单个客户端和多个服务端使用星闪SLE能力转发串口数据。对客户端和服务端进行封装,更易用。
51 sle_wifi_coexist 标准案例 2 SLE/WiFi共存标准案例。适用于各种星闪网关通讯场景。
52 sle_wifi_radar_coexist 标准案例 2 SLE/WiFi/Radar共存标准案例。展示了如何让Radar不受SLE和WiFi影响的技术细节。
53 sle_set_wifi 标准案例 2 SLE配网Wi-Fi标准案例。适用于各种星闪配网场景。
54 sle_light_control 标准案例 2 SLE灯控场景案例。基于星闪通讯的端到端硬件控制和传感器数据采集是比较简单的星闪应用,本案例选取相对典型的灯控场景进行展示。
55 sle_multi_point_gather 标准案例 2 SLE多点采集标准案例。多个服务端主动发送数据给一个客户端。客户端收到数据后,发送响应数据给服务端。
56 sle_hybrid_mode 商业项目 1 星闪主从一体(Hybrid)模式。即Master+Slave模式,是指星闪设备既可以主动搜索其他设备并建立连接,也可以等待其他设备的连接的模式。本项目实现了星闪主从一体节点,增强了星闪设备的场景适用性和功能多样性。适用于组建线性星闪网络的各类场景。本项目首创[1]实现了星闪主从一体模式,并首次开源[2]
57 sle_hybrid_demo 标准案例 (项目模板) 3 星闪主从一体(Hybrid)基础案例。包括三类节点:Client节点、Hybrid节点、Server节点。本案例首创[1]实现了线性星闪网络,并首次开源[2]。可以作为项目模板,适用于各种线性星闪网络通讯场景。
58 sle_hybrid_n_mode 商业项目 1 星闪主从一体一对多(HybridN)模式。在Hybrid模式的基础上,支持一对多的连接,即可以同时连接多个server端设备。本项目实现了星闪主从一体一对多节点,这是建立星闪网络的基础,使得星闪具备大规模自组网能力。适用于组建复杂星闪网络的各类场景。本项目首创[1]实现了星闪主从一体一对多模式,并首次开源[2]
59 sle_hybrid_n_demo 标准案例 (项目模板) 3 星闪主从一体一对多(HybridN)基础案例。包括三类节点:Client节点、HybridN节点、Server节点。本案例首创[1]实现了树型(星型)分布式星闪网络,并首次开源[2]。可以作为项目模板,适用于各种树型(星型)分布式星闪网络通讯场景。
60 sle_dicsoss 商业项目 3 星闪开放空间分布式信息采集系统。多个Data节点采集信息,通过SLE分布式网络发送到一个Receiver节点。Receiver节点作为星闪网关,连接Wi-Fi网络,通过MQTT将信息发送到云端MQTT代理。富设备端(手机、PAD、PC、大屏等)订阅MQTT云端消息。本项目首创[1]实现了复杂的星闪树型网络拓扑结构或星型网络拓扑结构,进行了星闪自组网能力测试,给出了末端节点数量计算公式,展示了实际场景部署的一些典型网络拓扑结构。本项目首创[1]实现了可自由配置的星闪主从一体一对多节点,支持自定义星闪网络拓扑结构,且配置方便。适用于所有分布式信息采集场景,包括但不限于工业、农业、商业、公共服务、教育、医疗、科研等。适用于设备固定化的信息采集,和设备移动化的信息采集。既适用于长期固定部署,也适用于临时部署。
61 sle_radar_surveillance 商业项目 3 星闪分布式雷达监控系统。多个Radar节点采集人员靠近信息,通过SLE分布式网络发送到一个Receiver节点。Receiver节点作为星闪网关,连接Wi-Fi网络,通过MQTT将监控信息发送到云端MQTT代理。富设备端(手机、PAD、PC、大屏等)订阅MQTT云端消息,实现人员出没监控。可用于完全无光环境下的人员出没监控。本项目实现了可自由配置的星闪主从一体一对多节点,支持自定义星闪网络拓扑结构,实现了复杂的星闪树型网络拓扑结构或星型网络拓扑结构,并额外展示了星闪网络健壮性,给出了星闪网络组网速度。适用于家庭安全、公共安全、场地安全、保密设施、人员搜救、人员跟踪等各类场景。既适用于长期固定部署,也适用于临时部署。
62 sle_delay_optimize 标准案例 2 SLE延迟优化标准案例。一个或多个服务端主动发送数据给一个客户端。客户端收到数据后,发送响应数据给服务端。服务端计算时延。分别针对1V1模式和1VN模式进行调优。
63 sle_throughput_optimize 标准案例 2 SLE吞吐量优化标准案例。基于海思官方示例原样移植到OpenHarmony SDK,再进行吞吐量优化。两块星闪开发板通过SLE发送数据,并显示速率。
64 sle_announce_customize 标准案例 2 星闪自定义设备公开数据标准案例。对星闪协议栈的空口广播数据进行了详细分析,展示了如何自定义设备公开数据和扫描响应数据,以及如何解析扫描结果数据。网络首发[3]星闪协议栈的空口数据分析。
65 sle_starBeacon 商业项目 1 可信星闪信标(Trusted starBeacon)。本项目对标蓝牙信标(iBeacon),相比蓝牙信标,可信星闪信标信号覆盖面积更大、更安全、支持的空口广播数据量更大。星闪信标(starBeacon)是一种基于星闪技术的精准微定位(包括存在性感知和位置性感知)技术,它可以让附近的具备星闪功能的终端设备检测到由星闪信标发出的信号,范围可以从几厘米到3千米。星闪信标的可信信标模式,可以解决由于信标的伪造或者空口数据泄露带来的安全问题。在可信信标模式下,信标的广播数据以加密方式发射,接收方需要以事先协商好的密钥解密。通过加密广播和解密接收,可以确保信标的广播数据不被伪造,并且极难破解。适用于工业、农业、商业、服务业、公共服务、教育、医疗、户外标定等各类场景。本项目实现的可信星闪信标是业内首创[1],并首次开源[2]。由于2821E星闪芯片具备测距能力,可以达到厘米级精准度,当把可信星闪信标移植到2821E芯片时,其将拥有室内精准定位能力。本项目实现了星闪广播模式。
66 sle_starBeacon_test 商业项目 1 可信星闪信标(Trusted starBeacon)发现端案例。适用于手机、手表、手环、平板、车辆、轮船、飞行器、工业终端、农业终端等各类终端场景。由于2821E星闪芯片具备测距能力,可以达到厘米级精准度,当把本案例移植到2821E芯片时,其将拥有室内精准定位能力。本项目实现了星闪观察者模式。

使用方法

  1. 将本仓内容(包括applicationsdeviceLICENSEREADME.md等)复制到编译环境中OpenHarmony SDK的根目录(例如~/openharmony/sdk20240628)下。
  2. 使用VSCode打开OpenHarmony SDK的根目录。如果使用Windows版本的VSCode,可以通过网络位置(例如\\<虚拟机IP>\home\dragon\openharmony\sdk20240628)打开OpenHarmony SDK的根目录。
  3. 案例间具备连贯性和阶梯性,建议入门学习者按照序号进行学习。
  4. 具体到某个案例,阅读该案例的README.md文件,按照说明进行编译、烧录、运行。注意,README.md文件不会明确给出硬件连接方法,请根据源码、注释、开发板引脚定义,连接硬件。
  5. 有些案例需要两块、多块、甚至大量的开发板,有些案例需要杜邦线、LED、蜂鸣器、按键、传感器、外置天线、OLED屏、逻辑分析仪等外设,请自行准备。缺少硬件将导致案例无法正常运行。
  6. 每个案例均提供了大量中文注释和适量的英文注释[2],注释中包含了具体的技术细节,请结合注释理解案例。

OpenHarmony SDK (oh_sdk_20240628) BUG list

参见海思社区的 帖子列表

联系

邮件

注解

[1] 如果对"首创"有异议,请联系版权持有人,并提供有效证据,版权持有人将及时更正。
[2] 如果对"首次开源"有异议,请联系版权持有人,并提供有效证据,版权持有人将及时更正。
[3] 如果对"首发"有异议,请联系版权持有人,并提供有效证据,版权持有人将及时更正。
[4] 英文注释是对中文注释的补充。
[5] 本案例集既不在中国以外的源代码管理平台发布,也不允许日本、美国、欧盟成员国的任何实体或个人使用。

GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Lesser General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. GNU GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. 1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. 4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. 6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. 10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. <one line to give the program's name and a brief idea of what it does.> Copyright (C) <year> <name of author> This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. Also add information on how to contact you by electronic and paper mail. If the program is interactive, make it output a short notice like this when it starts in an interactive mode: Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. <signature of Ty Coon>, 1 April 1989 Ty Coon, President of Vice This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Lesser General Public License instead of this License.

About

OH和NearLink还很年轻, 路还很长, 但是没人能熄灭满天星光。 每一位开发者, 都是我们要汇聚的星星之火。 让我们在国产自主的道路上, 冲锋陷阵,高歌前行。 漫待群星闪耀时, 一览众山小! expand collapse
README
GPL-2.0
Cancel

Releases

No release

Contributors (1)

All

Activities

can not load any more
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C
1
https://gitee.com/anhao011/openharmony-nearlink-ws63-cases.git
git@gitee.com:anhao011/openharmony-nearlink-ws63-cases.git
anhao011
openharmony-nearlink-ws63-cases
OpenHarmony NearLink WS63 案例集
master

Search