28500067c5
Merge pull request !3 from Laowang-BearPi/master |
||
---|---|---|
app | ||
docs | ||
figures | ||
hi3861_adapter | ||
iot_hardware_hals/include | ||
sdk_liteos | ||
BUILD.gn | ||
LICENSE | ||
NOTICE | ||
OAT.xml | ||
ohos.build | ||
README.en.md | ||
README.md |
Reason for abandonment of this repository: the repository is abandoned due to the separation and adjustment of board and SOC New repository:device_board_bearpi,device_soc_hisilicon
BearPi-HM Nano
- Get source code
- Construction of development environment
- Source code compilation
- Firmware burning
- Introduction to development board
- Development board details
- Application
- Directory Structure
Get source code
repo init -u git@gitee.com:openharmony/manifest.git -b master --no-repo-verify
repo sync -c
repo forall -c 'git lfs pull'
Construction of development environment
Please refer to Hi3861 development environment construction
Source code compilation
hb set
bearpi
>bearpi_hm_nano
选择bearpi_hm_nano
hb build -f
Firmware burning
-
Open hiburn tool in windows, click 'Refresh', and select com number in 'com', as shown in the following figure。
Then click 'Setting' and select 'Com settings'.
-
Set 'Baud' to '921600' in com settings, and click OK, as shown in the figure below.
-
Click the 'select file' button in hiburn tool, and in the pop-up file box, select the './out/bearpi_hm_nano/bearpi_hm_nano/' file under the 'Hi3861_wifiiot_app_allinone.bin' path of the project file, as shown in the following figure.
-
Click the 'Auto burn' check box, and then click 'Connect', as shown in the following figure.
The 'Connect' button changes to 'Disconnect' and waits for the download.
-
Reset the 'RESET' button on the development board to start downloading the program, as shown in the figure below.
-
Until the word "Execution Successful" appears, the program download is completed.
-
After downloading, click the 'Disconnect' button to facilitate later debugging.
Introduction to development board
Development board overview
BearPi(BearPi-HM Nano)is a development board specially built by BearPi school for openharmony system. It carries a highly integrated 2.4GHz WiFi SoC chip hi3861, and carries NFC circuit and standard E53 interface. The standard E53 interface can expand cases such as intelligent humidifier, intelligent desk lamp, intelligent security, intelligent smoke detector, etc.
Development board function
BearPi-HM Nano development board, for developers, is used for openharmony development and learning. At the same time, it provides rich cases and tutorials to realize full scene application design.
-
E53 interface: it is a standard interface with rich resources and easy to expand. It realizes multi application case expansion, making case development more flexible and convenient.
-
NFC: the on-board NFC RF circuit, combined with the key capabilities of openharmony, can perfectly realize the "touch and touch" networking mechanism and service pull-up function of openharmony system, reduce the complexity of user operation, and improve the user experience.
-
User keys: open function keys. The key functions are fully defined by the developer, which increases user operability.
Development board details
The detailed functions of the development board are shown in the figure below:
Application
Development board application scenario
Bearpi_HM_Nano can be used in intelligent humidifier, intelligent desk lamp, intelligent security, intelligent smoke detector and other cases, such as the following cases.
-
Intelligent humidifier: it can monitor the current indoor temperature and humidity in real time, and can open and close the humidifier remotely and in real time.
-
Intelligent desk lamp: it can monitor the current indoor light intensity in real time. When it is lower than the predetermined threshold, the desk lamp will be turned on automatically, and the independent control of the desk lamp can be realized.
-
Intelligent security: it can monitor the movement of human body within the range in real time and report to the cloud display to realize the monitoring and alarm of intelligent security.
-
Intelligent smoke sensing: it can monitor the smoke concentration in the current room in real time and report to the cloud display. When the smoke concentration exceeds the set threshold, the alarm will trigger the alarm immediately.
Directory Structure
The root directory of the Hi3861 SDK is device\bearpi\bearpi_hm_nano\sdk_liteos. Its directory structure is as follows:
device/bearpi/bearpi_hm_nano/sdk_liteos
├── app # Application layer code, including the demo program.
├── boot # Flash bootloader code.
├── build # Library, link, and configuration files required for SDK construction.
├── BUILD.gn # GN building script.
├── build_patch.sh # File used for decompressing the U-Boot open-source code package and applying patches.
├── build.sh # Building script for startup, which can be customized using the sh build.sh menuconfig command.
├── components # Files related to the SDK platform.
├── config # SDK system configuration files.
├── config.gni # Configuration files supporting OpenHarmony.
├── factory.mk # Building script of the factory-test version.
├── hm_build.sh # Building script for adapting to OpenHarmony.
├── include # Header files declaring APIs.
├── license # License of the open-source SDK.
├── Makefile # File for building using the make or make all command.
├── non_factory.mk # Building script of the non-factory-test version.
├── platform # Files related to the SDK platform, including the kernel image and driver modules.
├── SConstruct # SCons build script.
├── third_party # Open-source third-party software.
└── tools # Tools provided by the SDK for Linux and Windows systems, including the NV making tool, signature tool, and Menuconfig.
Repositories Involved
device/bearpi/bearpi_hm_nano
vendor/bearpi