1.基于恒玄BES2600的源码轻量级鸿蒙操作系统AIOT开发平台解析之SDK和编译
2.githb是什么?
3.vb问题:希望可以给代码
基于恒玄BES2600的轻量级鸿蒙操作系统AIOT开发平台解析之SDK和编译
一 鸿蒙系统
华为鸿蒙系统作为一款面向全场景的分布式操作系统,旨在构建一个互联世界,直播通过智能设备间的源码无缝连接和资源分享,优化用户的直播全场景生活体验。此系统具有高开源性,源码兼容多芯片平台,直播怎么抓取html源码在产业发展中快速推进。源码
二 恒玄BES
BES芯片由恒玄科技推出,直播集WiFi和蓝牙功能于一体,源码具备轻量级和强大资源的直播特点,特别适用于以音频为中心的源码高端物联网应用。
三 代码下载和编译
1 源码在Gitee平台上开放,直播下载地址如下:
gitee.com/openharmony/d...
具体下载步骤如下:
mkdir openharmony_bestechnic
cd openharmony_bestechnic
repo init -u gitee.com/openharmony/m... --no-repo-verify
repo sync -c
repo forall -c 'git lfs pull'
2 使用的源码是arm-gcc编译器,与鸿蒙系统进行封装和映射,直播编译命令示例如下:
hb set -root .
hb set -p bestechnic > display_demo iotlink_demo xts_demo
选择display_demo
hb build -f
编译完成会显示:
四 下载和运行
已包含下载指南。源码seata核心源码编译后的文件会与下载软件和bin文件捆绑,只需将文件复制到Windows环境并按照指示操作即可完成运行。
githb是什么?
GitHub是一个面向开源及私有软件项目的托管平台,因为只支持git作为唯一的版本库格式进行托管,故名GitHub。
简单来说,GitHub是hutool解密源码一个代码托管云服务网站,主要用于软件开发者存储和管理其项目源代码,且能够追踪、记录并控制用户对其代码的修改。甚至你可以简单粗暴的把它当作一个网盘,用来存储任何东西。
GitHub的功能作用:
1.托管代码、历史版本管理
当然不仅仅是加工订单源码代码,任何文件都支持(不少人用GitHub来写博客)。它会自动帮你记录代码的修改,在必要的时候,能够帮助你快速回退到之前的历史版本。
2.搜索开源项目
GitHub是世界顶级开发者的聚集地,在这里你几乎可以找到任何你想要的东西。上面分享有许多优秀、source源码解析著名的开源项目,在遵守其License的前提下,你可以免费使用、下载这些开源项目。这也是GitHub最为吸引人的地方。
3.分享的同时会得到社区的回馈
GitHub可以说是共产主义的最佳实践之一。其一大优势是协同开发,你分享出来的项目,其他开发者也可以参与贡献,帮助你一同完善项目功能,Bug修复,代码质量提升。
4.学习,能力提升
GitHub上有很多优秀开源项目和教程资源值得你去发现、学习。
5.提升自己的影响力
你可以将自己的开源项目发布到GitHub网站上,项目越受欢迎获得的Star越高,说明业界对你的能力越认可。一份优秀的GitHub主页,能为自己的简历润色不少。
vb问题:希望可以给代码
先新建一个模块,里面添加API声明
Option Explicit
Declare Function MoveWindow Lib "user" (ByVal hwnd As Long, ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal bRepaint As Long) As Long
Declare Function SendMessage Lib "user" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, lParam As Any) As Long
Public Const LB_INITSTORAGE = &H1A8
Public Const LB_ADDSTRING = &H
Public Const WM_SETREDRAW = &HB
Public Const WM_VSCROLL = &H
Public Const SB_BOTTOM = 7
Declare Function GetLogicalDrives Lib "kernel" () As Long
Declare Function FindFirstFile Lib "kernel" Alias "FindFirstFileA" (ByVal lpFileName As String, lpFindFileData As WIN_FIND_DATA) As Long
Public Const INVALID_HANDLE_VALUE = -1
Declare Function FindNextFile Lib "kernel" Alias "FindNextFileA" (ByVal hFindFile As Long, lpFindFileData As WIN_FIND_DATA) As Long
Declare Function FindClose Lib "kernel" (ByVal hFindFile As Long) As Long
Type FILETIME
dwLowDateTime As Long
dwHighDateTime As Long
End Type
Public Const MaxLFNPath =
Type WIN_FIND_DATA
dwFileAttributes As Long
ftCreationTime As FILETIME
ftLastAccessTime As FILETIME
ftLastWriteTime As FILETIME
nFileSizeHigh As Long
nFileSizeLow As Long
dwReserved0 As Long
dwReserved1 As Long
cFileName As String * MaxLFNPath
cShortFileName As String *
End Type
然后在窗体上制作2个菜单,放置一个ListBox和一个PictureBox
完整代码如下:
Option Explicit
Dim PicHeight%, hLB&, FileSpec$, UseFileSpec%
Dim TotalDirs%, TotalFiles%, Running%
Dim WFD As WIN_FIND_DATA, hItem&, hFile&
Const vbBackslash = "\"
Const vbAllFiles = "*.*"
Const vbKeyDot =
Private Sub Form_Load()
ScaleMode = vbPixels
PicHeight% = Picture1.Height
hLB& = List1.hwnd
SendMessage hLB&, LB_INITSTORAGE, &, ByVal & *
Move (Screen.Width - Width) * 0.5, (Screen.Height - Height) * 0.5
End Sub
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
If KeyCode = vbKeyEscape And Running% Then Running% = False
End Sub
Private Sub Form_Resize()
MoveWindow hLB&, 0, 0, ScaleWidth, ScaleHeight - PicHeight%, True
End Sub
Private Sub Form_Unload(Cancel As Integer)
Set Form1 = Nothing
End
End Sub
Private Sub mnuFindFiles_Click()
If Running% Then: Running% = False: Exit Sub
Dim drvbitmask&, maxpwr%, pwr%
On Error Resume Next
FileSpec$ = InputBox("Enter a file spec:" & vbCrLf & vbCrLf & "Searching will begin at drive A and continue " & "until no more drives are found. " & "Click Stop! at any time." & vbCrLf & "The * and ? wildcards can be used.", "Find File(s)", "*.exe")
If Len(FileSpec$) = 0 Then Exit Sub
MousePointer =
Running% = True
UseFileSpec% = True
mnuFindFiles.Caption = "&Stop!"
mnuFolderInfo.Enabled = False
List1.Clear
drvbitmask& = GetLogicalDrives()
If drvbitmask& Then
maxpwr% = Int(Log(drvbitmask&) / Log(2))
For pwr% = 0 To maxpwr%
If Running% And (2 ^ pwr% And drvbitmask&) Then _
Call SearchDirs(Chr$(vbKeyA + pwr%) & ":\")
Next
End If
Running% = False
UseFileSpec% = False
mnuFindFiles.Caption = "&Find File(s)..."
mnuFolderInfo.Enabled = True
MousePointer = 0
Picture1.Cls
Picture1.Print "Find File(s): " & List1.ListCount & " items found matching " & """" & FileSpec$ & """"
Beep
End Sub
Private Sub mnuFolderInfo_Click()
If Running% Then: Running% = False: Exit Sub
Dim searchpath$
On Error Resume Next
searchpath$ = InputBox("输入要查找的目标路径", "文件夹信息", "C:\")
If Len(searchpath$) < 2 Then Exit Sub
If Mid$(searchpath$, 2, 1) <> ":" Then Exit Sub
If Right$(searchpath$, 1) <> vbBackslash Then searchpath$ = searchpath$ & vbBackslash
If FindClose(FindFirstFile(searchpath$ & vbAllFiles, WFD)) = False Then
End If
MousePointer =
Running% = True
mnuFolderInfo.Caption = "停止(&S)"
mnuFindFiles.Enabled = False
List1.Clear
TotalDirs% = 0
TotalFiles% = 0
Call SearchDirs(searchpath$)
Running% = False
mnuFolderInfo.Caption = "文件夹信息(&F)"
mnuFindFiles.Enabled = True
Picture1.Cls
MousePointer = 0
MsgBox "Total folders: " & vbTab & TotalDirs% & vbCrLf & "Total files: " & vbTab & TotalFiles%, , "Folder Info for: " & searchpath$
End Sub
Private Sub SearchDirs(curpath$)
Dim dirs%, dirbuf$(), i%
Picture1.Cls
Picture1.Print "Searching " & curpath$
DoEvents
If Not Running% Then Exit Sub
hItem& = FindFirstFile(curpath$ & vbAllFiles, WFD)
If hItem& <> INVALID_HANDLE_VALUE Then
Do
If (WFD.dwFileAttributes And vbDirectory) Then
If Asc(WFD.cFileName) <> vbKeyDot Then
TotalDirs% = TotalDirs% + 1
If (dirs% Mod ) = 0 Then ReDim Preserve dirbuf$(dirs% + )
dirs% = dirs% + 1
dirbuf$(dirs%) = Left$(WFD.cFileName, InStr(WFD.cFileName, vbNullChar) - 1)
End If
ElseIf Not UseFileSpec% Then
TotalFiles% = TotalFiles% + 1
End If
Loop While FindNextFile(hItem&, WFD)
Call FindClose(hItem&)
End If
If UseFileSpec% Then
SendMessage hLB&, WM_SETREDRAW, 0, 0
Call SearchFileSpec(curpath$)
SendMessage hLB&, WM_VSCROLL, SB_BOTTOM, 0
SendMessage hLB&, WM_SETREDRAW, 1, 0
End If
For i% = 1 To dirs%: SearchDirs curpath$ & dirbuf$(i%) & vbBackslash: Next i%
End Sub
Private Sub SearchFileSpec(curpath$)
hFile& = FindFirstFile(curpath$ & FileSpec$, WFD)
If hFile& <> INVALID_HANDLE_VALUE Then
Do
DoEvents
If Not Running% Then Exit Sub
SendMessage hLB&, LB_ADDSTRING, 0, ByVal curpath$ & Left$(WFD.cFileName, InStr(WFD.cFileName, vbNullChar) - 1)
Loop While FindNextFile(hFile&, WFD)
Call FindClose(hFile&)
End If
End Sub
程序运行时就能够通过输入文件名而进行模糊查找了
如果还不明白,就加我QQ,我把我做好的程序发给你看
QQ号: