//adb链接不上断开adb
adb kill-server ; adb start-server
嵌入式必备
//编译结巴的demo g++ -std=c++11 -I ../deps/ -I ../deps/darts-clone/include/ -I ../include/ ../deps/limonp/Md5.cpp demo.c -o cppjieba_demo -Wall -g
//编译的库 /home/jason/GongJuLian/host_out_3326/bin/aarch64-linux-g++ -I ../deps/ -I ../deps/darts-clone/include/ -I ../include/ ../deps/limonp/Md5.cpp chs_wordcut.cpp -shared -fPIC -I ./3326/ -o libqie_ci.so
//编译源文件 /home/jason/GongJuLian/host_out_3326/bin/aarch64-linux-gcc demo.c -L. -lqie_ci -o -I./3326/qie_ci.exe
//export LD_LIBRARY_PATH=/home/ 环境变量
//chmod 777 权限
//d:
//adb push 项目名 /home/
//嵌入式启动wifi的脚本文件wifi_connect.sh随意命名
/usr/sbin/wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf &#脚本文件可以在任何位置 /etc/wpa_supplicant.conf这里是wifi的配置文件
sleep 3
udhcpc -s /etc/udhcpc.script -i wlan0 -b
//wifi的配置文件
ctrl_interface=/var/run/wpa_supplicant
ap_scan=1
update_config=1
network={
ssid="vivo"
psk="123456789"
key_mgmt=WPA-PSK
}
//ps -ef#获取进程id
//cd proc/进程id
//cat status #查看进程内存占用情况## 标题
//需安装驱动 adb
adb pull //从嵌入式移动东西出来
adb push //移动东西到嵌入式设备
adb shell //操作嵌入式
//编译结巴的demo g++ -std=c++11 -I ../deps/ -I ../deps/darts-clone/include/ -I ../include/ ../deps/limonp/Md5.cpp demo.c -o cppjieba_demo -Wall -g
//编译3326的库 /home/jason/GongJuLian/host_out_3326/bin/aarch64-linux-g++ -I ../deps/ -I ../deps/darts-clone/include/ -I ../include/ ../deps/limonp/Md5.cpp chs_wordcut.cpp -shared -fPIC -o libgeling_participle.so
//编译3326的源文件 /home/jason/GongJuLian/host_out_3326/bin/aarch64-linux-gcc demo.c -L. -lgeling_participle -lgeling_sign -o demo
v500 编译链
/home/jason/GongJuLian/arm-linux-androideabi-4.8/arm-linux-androideabi/bin/gcc *.c -shared -fPIC -o libini_config.so
/home/jason/GongJuLian/android/toolchain/arm-linux-androideabi-4.7/bin/arm-linux-androideabi-g++
君正
D:/君正/x2000/tools/toolchains/mips-gcc720-glibc226/bin/mips-linux-gnu-g++
/home/jason/GongJuLian/x2000/tools/toolchains/mips-gcc720-glibc226/bin/mips-linux-gnu-g++
//编译切词
/home/jason/GongJuLian/x2000/mips-gcc720-glibc226/bin/mips-linux-gnu-gcc demo.c -L. -L/home/jason/GongJuLian/ofldkfk/buildroot/buildroot/output/target/usr/lib -lgeling_participle -lgeling_sign -lssl -lcrypto -lcurl -lnghttp2 -Wl,-rpath-link=. -o demo
//adb链接不上断开adb
adb kill-server ; adb start-server
//export LD_LIBRARY_PATH=/home/ 环境变量
//chmod 777 权限
//d:
//adb push 项目名 /home/
//init 0 关机命令
//wifi 路径 /data/misc/wifi/wpa_supplicant.conf
make clean;make//编译
adb push "\\12.12.12.35\Share\GongJuLian\android\linux\case\apps\api_demo\ota_demo\__tmp__\otademo" /mnt/udisk/ota_v500//移动文件到嵌入式
//嵌入式启动wifi的脚本文件
/usr/sbin/wpa_supplicant -i wlan0 -c /etc/wpa_supplicant.conf &#脚本文件可以在任何位置 /etc/wpa_supplicant.conf这里是wifi的配置文件
sleep 3
udhcpc -s /etc/udhcpc.script -i wlan0 -b
//wifi的配置文件
ctrl_interface=/var/run/wpa_supplicant
ap_scan=1
update_config=1
network={
ssid="vivo"
psk="123456789"
key_mgmt=WPA-PSK
}
//ps -ef#获取进程id
//cd proc/进程id
//cat status #查看进程内存占用情况
M-STAR
工具-xshell
python -m SimpleHTTPServer 8000 //虚拟机开启http服务器
wget http://192.168.0.110:8000/demo.c //虚拟机作为服务器下载东西 wifi通畅的情况
/customer/用户目录
/appconfigs/wpa_supplicant.conf_bak wifi 配置目录
sigma_wifi_init.sh //wifi脚本文件
LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$(pwd) //wifi路径下配置环境变量
串口协议 SERIAL
ping -I wlan0 14.215.177.39 //查看wifi是否链接成功
编译链(切词库)
/home/jason/GongJuLian/gcc-sigmastar-9.1.0-2020.07-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ -I ../deps/ -I ../deps/darts-clone/include/ -I ../include/ ../deps/limonp/Md5.cpp chs_wordcut.cpp -shared -fPIC -o libgeling_participle.so
/home/jason/GongJuLian/gcc-sigmastar-9.1.0-2020.07-x86_64_arm-linux-gnueabihf/bin/arm-linux-gnueabihf-g++ geling_wifi.cpp -shared -fPIC -o libgeling_wifi.so;cp libgeling_wifi.so ../bin
ffmpeg -i http://yunstudy.koo6.cn/2018Videofile/2020/ACC4a6cc5668fc61ec2c11ddef35c112ed5/rjbxxyw2njxc2017xdb40/500kb.m3u8 xiaoshiping.mp4
查看Linux当前目录的大学 --max-depth为深度
du -h --max-depth=0
ls -alh 查看文件的大小
//虚拟机挂载
在linux下:
1. sudo apt-get install nfs-kernel-server
2. sudo vim /etc/exports
2.1 最后一行添加:/home/jason/nfs *(rw,sync,no_root_squash,no_subtree_check)
3. sudo /etc/init.d/nfs-kernel-server restart
在arm下:
1.检查网络,是否与linux能ping通
2.mount -t nfs -o nolock 192.168.0.110:/home/jason/nfs /mnt
3.小概率出现内存格式不搭,执行cp操作
sh 进程名杀死进程
./kill.sh demo
kill.sh
#!/bin/bash
array=(`ps -ef | grep -v grep | grep -w "$1"`)
kill -9 ${array[1]}
宏开关
#include<stdio.h>
#ifdef DEBUG
#define L printf
#else
#define L(...)
#endif
int main(void)
{
L("------------------------------------------------------\n");
return 0;
}