4. BSP Development Guide
- 4.1. Setting Up the Development Environment and Compilation Instructions
- 4.1.1. Overview
- 4.1.2. Setting Up the Development Environment
- 4.1.3. BSP Source Code Directory Structure
- 4.1.4. Compilation Process and Commands
- 4.1.5. Building BSP Using Docker
- 4.1.6. Use Podman to compile BSP
- 4.2. Hardware Bring-Up Guide
- 4.2.1. Hardware Bring-Up Basic Process
- 4.2.2. Adding Board-Level Configuration
- 4.2.3. Adding New Hardware in U-Boot
- 4.2.4. Adding Hardware Support in Kernel
- 4.2.5. Debugging Minimal System
- 4.2.6. System Stability and Stress Testing
- 4.3. Driver Development Guide
- 4.3.1. Address space mapping
- 4.3.2. Configure U-Boot and Kernel Option Parameters
- 4.3.3. UART Driver Debug Guide
- 4.3.4. GPIO Debug Guide
- 4.3.5. Pinctrl Debug Guide
- 4.3.6. IO-Domain Debug Guide
- 4.3.7. ADC Debug Guide
- 4.3.8. SPI Debug Guide
- 4.3.8.1. SPI Overview
- 4.3.8.2. Features
- 4.3.8.3. Functional Description
- 4.3.8.4. Driver Code
- 4.3.8.5. Functional Usage
- 4.3.8.6. Common SPI Communication Errors and Troubleshooting Methods
- 4.3.9. I2C Debug Guide
- 4.3.10. LPWM Driver Debug Guide
- 4.3.11. PWM Driver Debug Guide
- 4.3.12. RTC Debug Guide
- 4.3.13. Watchdog Driver Debug Guide
- 4.3.14. Thermal System
- 4.3.14.1. Overview of the Thermal System
- 4.3.14.2. Functional Description of the Thermal System
- 4.3.14.3. Thermal Driver Code
- 4.3.14.4. Functions and Usage of the Thermal System
- Explanation of Key Structures in Thermal Driver
- Key Function Interfaces of Thermal Subsystem
- thermal_set_governor Function
- thermal_register_governor Function
- thermal_unregister_governor Function
- update_temperature Function
- thermal_zone_device_update Function
- thermal_zone_device_check Function
- thermal_zone_bind_cooling_device Function
- thermal_zone_unbind_cooling_device Function
- thermal_cooling_device_unregister Function
- bind_tz Function
- thermal_zone_device_register_with_trips Function
- thermal_zone_device_unregister function
- thermal_init function
- 4.3.14.5. Thermal system debugging guide for driver platform
- 4.3.14.6. Thermal reference documentation
- 4.3.15. Ethernet Driver Debug Guide
- 4.3.16. PMIC Driver Debugging Guide
- 4.3.16.1. PMIC Overview
- 4.3.16.2. PMIC Functional Description
- 4.3.16.3. PMIC Driver Code
- 4.3.16.4. PMIC Usage Guide
- 4.3.16.5. PMIC Testing
- 4.3.16.6. Common PMIC Issues
- 4.3.16.7. Reference Documents
- 4.3.17. LCD Driver Debug Guide
- 4.3.18. USB/USB Gadget Debug Guide
- 4.3.18.1. Overview
- 4.3.18.2. Functional Description
- 4.3.18.3. Code Analysis
- 4.3.18.4. USB Gadget Function Usage
- 4.3.18.5. Common Issues
- 4.3.19. Audio Development and Debugging Guide
- 4.3.19.1. Overview
- 4.3.19.2. Features
- 4.3.19.3. Functional Description
- 4.3.19.4. Driver Code
- 4.3.19.5. Function Usage
- 4.3.19.6. Common Issues
- Q1: How to troubleshoot silence issues?
- Q2: Few LOGs, unable to locate the problem, what to do?
- Q3: How to determine sound card registration success and PCM device correspondence?
- Q4: What is an xrun issue, and how to locate and resolve it when encountered?
- Q5: Errors related to opening device nodes:
- 4.3.20. SDIO Usage Guide
- 4.3.21. Wi-Fi Driver Debug Guide
- 4.3.22. Bluetooth Driver Debug Guide
- 4.3.22.1. Overview
- 4.3.22.2. RealTek RTL8852BS Porting
- 4.3.22.3. FCS960K Porting
- 4.3.22.4. Bluetooth Usage
- 4.3.22.5. Common Issues
- 4.3.23. QoS Debug Guide
- 4.3.24. AXI-Monitor Debug Guide
- 4.3.25. X5 USB User Manual
- 4.3.26. boardinfo Debug Guide
- 4.3.27. Time Synchronization Debugging Guide
- 4.3.28. bootloader Usage instructions
- 4.3.28.1. Bootloader User Guide
- Introduction to Bootloader
- Bootloader Boot Process
- Introduction to Secure Boot Process
- U-Boot Dynamic Configuration of Kernel ION Reserved Memory Size Usage Guide
- U-Boot Usage Guide for dtb overlay
- U-Boot Configuration of Watchdog
- U-Boot Configuration of PHY
- U-Boot Configuration of UART
- U-Boot Configuration of IO-Domain
- Description of Commonly Used Commands in U-Boot
- Bootloader Glossary
- 4.3.28.2. BL2 Configuration File Description
- 4.3.28.1. Bootloader User Guide
- 4.3.29. HIFI5 Guidelines for use
- 4.4. System Component Development
- 4.4.1. Auto-start Configuration
- 4.4.2. Integrating User Software into System Image
- 4.4.3. Root Filesystem Adaptation Guide
- 4.4.3.1. Creating Root Filesystem with Buildroot
- 4.4.3.2. Use Multistrap to create Ubuntu root file system
- 4.4.3.3. Using APPSDK for Application Development
- Prerequisites
- Packaging the SDK
- Installing the SDK
- Upgrade and Uninstall
- Compiling Applications with the SDK
- Verifying the SDK
- SDK Directory Structure
- version File
- FAQ
source environment-setupreports “must be sourced, not executed”- Using
shto source reports “requires bash, not sh” - Linking hbre libraries reports “cannot find -lxxx”
- Old version residue after SDK upgrade
- SDK does not work after moving to another path
- environment-setup still present after
dpkg -r - dpkg asks how to handle environment-setup during reinstall/upgrade (conffile conflict)
- Need to re-source after upgrading the SDK
- Notes
- 4.4.4. System Miniaturization and Trimming
- 4.4.5. Quickstart Guide
- 4.4.5.1. Overview
- 4.4.5.2. Image Preparation and Flashing
- 4.4.5.3. Boot Time Comparison Before and After Optimization
- 4.4.5.4. Integrating User Software into the Quickstart Image
- 4.4.5.5. Quickstart Boot Chain Optimization
- 4.4.5.6. FAQ
- 4.4.6. ION System Debugging Guide
- 4.4.7. Log System Introduction
- 4.4.8. Information Security Development Guide
- 4.4.8.1. Introduction to security hardware
- 4.4.8.2. FDE Full disk encryption
- 4.4.8.3. FBE File encryption
- 4.4.8.4. Safe start
- 4.4.8.5. boot encrypt
- 4.4.8.6. TEE
- 4.4.8.7. eFuse Burning
- 4.4.8.8. secure storage
- X5 Secure Storage Introduction
- KEY Management
- Secure Storage Operation Interfaces
- Secure Storage Operation Commands
- 4.4.9. OTA
- 4.4.9.1. OTA Functionality and Introduction
- 4.4.9.2. OTA API
- Error Types Returned by Dynamic Library Interfaces
- Interface List
- 4.4.10. USB Flash Drive Update Function
- 4.4.11. Low Power Mode Debugging Guide
- 4.4.11.1. Overview and Introduction
- 4.4.11.2. Detailed Explanation of Low Power Debugging
- 4.4.11.3. Dynamic Voltage and Frequency Scaling (DVFS)
- 4.4.11.4. Suspend and Resume
- 4.4.11.5. Typical Scenario Power Consumption
- 4.4.12. System Performance Optimization Guide
- 4.4.12.1. Overview
- 4.4.12.2. Performance Diagnostic Tools
- 4.4.12.3. System Optimization Strategies
- 4.4.12.4. Application Optimization
- 4.4.12.5. Introduction to the USE Method
- 4.4.12.6. Case Study
- 4.4.12.7. References
- 4.5. Driver function unit test
- 4.5.1. Overview
- 4.5.2. AutoTest Usage Guide
- 4.5.3. CPU-BPU-DDR Stress Test
- 4.5.4. eMMC Stress Test
- 4.5.5. QSPI NAND Flash Stress Test
- 4.5.6. UART Stress Test
- 4.5.7. SPI Stress Test
- 4.5.8. Wi-Fi Performance Testing
- 4.5.9. Ethernet Performance Testing
- 4.5.9.1. Throughput Testing
- 4.5.9.2. MTU Performance Testing
- 4.5.9.3. Common Issues
- 1. Why can’t the
iperf3client connect to the server? - 2. Why is the measured bandwidth lower than expected?
- 3. Why is there high packet loss during testing?
- 4. How to resolve the “Address already in use” error when running
iperf3? - 5. Why do MBytes and Bitrate look the same across MTU test tiers?
- 6. Why is MTU 9000 not tested?
- 1. Why can’t the
- 4.5.10. CPU Performance Test
- 4.5.11. DDR Bandwidth Test
- 4.5.12. USB Bus Speed Test
- 4.5.13. 2D GPU Performance Test
- 4.5.14. 3D GPU Performance Test
- 4.5.15. GPIO IRQ Test
- 4.5.16. Bluetooth Performance Testing
- 4.5.17. ADC Test
- 4.5.18. Watchdog Test
- 4.5.19. RTC Test
- 4.6. System debugging method
- 4.6.1. pstore & ramoops
- 4.6.2. mem-dump Feature Guide
- 4.6.3. Using GDB to Debug Applications
- 4.6.4. Using Kdb/Kgdb to Debug the Kernel
- 4.6.5. DDR Digital eye diagram
- 4.7. Common command usage methods
- 4.7.1. Iozone
- 4.7.2. iperf3
- 4.7.3. perf
- 4.7.4. sysinfopro
- 4.7.4.1. Syntax Description
- 4.7.4.2. Option Parameters Description
- 4.7.4.3. Command Options and Their Functional Descriptions
- Display All Information
- Display Memory Information
- Display Hardware Information
- Display Operating System Version Information
- Display Temperature and Frequency Information
- Display Board Terminal Basic Information
- Display HBRE Library Version Information
- Display Currently Loaded Kernel Modules
- Display Help Information
- 4.7.5. devmem
- 4.7.6. hb_gpioinfo
- 4.7.7. hrut_boardid
- 4.7.8. hrut_bpuprofile
- 4.7.9. hrut_ddr
- 4.7.10. hrut_ddr_freq
- 4.7.11. hrut_resetreason
- 4.7.12. hrut_sched_log_parse
- 4.7.13. hrut_socuid
- 4.7.14. hrut_somstatus
- 4.7.15. hrut_switch_reason
- 4.7.16. logcat
- 4.7.17. ota_tool
- 4.8. Approved Vendor List
- 4.8.1. Introduction
- 4.8.2. DDR Support List
- 4.8.3. eMMC Support List
- 4.8.4. NAND Flash Support List
- 4.8.5. Camera Sensor Support List
- 4.8.6. Wi-Fi/Bluetooth Support List
- 4.8.7. PHY Support List
- 4.8.8. BT1120 To HDMI List
- 4.8.9. Audio Codec Support List
- 4.8.10. IMU Support List
- 4.8.11. MIPI DSI Support List
- 4.8.12. 4G Support List