? - alias for 'help'
base - print or set address offset
bdinfo - print Board Info structure
bmode - sd1|sd2|qspi1|normal|usb|sata|ecspi1:0|ecspi1:1|ecspi1:2|ecspi1:3|esdhc1|esdhc2|esdhc3|esdhc4 [noreset]
bmp - manipulate BMP image data
boot - boot default, i.e., run 'bootcmd'
bootd - boot default, i.e., run 'bootcmd'
bootelf - Boot from an ELF image in memory
bootm - boot application image from memory
bootp - boot image via network using BOOTP/TFTP protocol
bootvx - Boot vxWorks from an ELF image
bootz - boot Linux zImage image from memory
clocks - display clocks
cmp - memory compare
coninfo - print console devices and information
cp - memory copy
crc32 - checksum calculation
dcache - enable or disable data cache
dhcp - boot image via network using DHCP/TFTP protocol
dm - Driver model low level access
echo - echo args to console
editenv - edit environment variable
env - environment handling commands
erase - erase FLASH memory
exit - exit script
ext2load- load binary file from a Ext2 filesystem
ext2ls - list files in a directory (default /)
ext4load- load binary file from a Ext4 filesystem
ext4ls - list files in a directory (default /)
ext4size- determine a file's size
ext4write- create a file in the root directory
false - do nothing, unsuccessfully
fatinfo - print information about filesystem
fatload - load binary file from a dos filesystem
fatls - list files in a directory (default /)
fatsize - determine a file's size
fatwrite- write file into a dos filesystem
fdt - flattened device tree utility commands
flinfo - print FLASH memory information
fstype - Look up a filesystem type
fuse - Fuse sub-system
go - start application at address 'addr'
gpio - query and control gpio pins
help - print command description/usage
i2c - I2C sub-system
icache - enable or disable instruction cache
iminfo - print header information for application image
imxtract- extract a part of a multi-image
itest - return true/false on integer compare
load - load binary file from a filesystem
loadb - load binary file over serial line (kermit mode)
loads - load S-Record file over serial line
loadx - load binary file over serial line (xmodem mode)
loady - load binary file over serial line (ymodem mode)
loop - infinite loop on address range
ls - list files in a directory (default /)
md - memory display
mdio - MDIO utility commands
mii - MII utility commands
mm - memory modify (auto-incrementing address)
mmc - MMC sub system
mmcinfo - display MMC info
mtest - simple RAM read/write test
mw - memory write (fill)
nfs - boot image via network using NFS protocol
nm - memory modify (constant address)
ping - send ICMP ECHO_REQUEST to network host
pmic - PMIC
printenv- print environment variables
protect - enable or disable FLASH write protection
reset - Perform RESET of the CPU
run - run commands in an environment variable
save - save file to a filesystem
saveenv - save environment variables to persistent storage
setenv - set environment variables
setexpr - set environment variable as the result of eval expression
sf - SPI flash sub-system
showvar - print local hushshell variables
size - determine a file's size
sleep - delay execution for some time
source - run script from memory
test - minimal test like /bin/sh
tftpboot- boot image via network using TFTP protocol
true - do nothing, successfully
usb - USB sub-system
usbboot - boot from USB device
version - print monitor, compiler and linker version
查看命令帮助信息?
设置环境变量
显示内存值
md[.b,.w,.l] address [#pf objects]
nm[.b,.w,.l] address [#pf objects]
cmp[.b,.w,.l] add1 addr2 conut
setenv ipaddr 192.168.1.50
setenv ethaddt 00:04:9f:04:d2:35
setenv gatewayip 192.168.1.1
setenv netmask 255.255.255.0
setenv serverip 192.168.1.250
saveenv
sudo apt-get install nfs-kernel-server rpcbind
sudo vi /etc/exports
打开/etc/exports 以后在后面添加如下所示内容:
/home/zuozhongkai/linux/nfs *(rw,sync,no_root_squash)
sudo apt-get install openssh-server
sudo apt-get install tftp-hpa tftpd-hpa
mmc info
mmc rescan
mmc list
mmc dev x 切换
mmc part
mmc read 80800000 600 10
从EMMC 的第1536(0x600)个块读取 16个数据到addr处
fatinfo mmc 0:1
fatload mmc 1:1 80800000 zimage //将zimage 下载到ddr的 80800000
fatload mmc 1:1 83000000 imx6ull-14x14-emmc-4.3-480x272-c.dtb
bootz 80800000 - 83000000
arch\arm\cpu\u-boot.lds是整个Uboot的链接脚本
board\freescale\mx6ullevk
。。。
重点关注
alientek_uboot\board\freescale
\alientek_uboot\configs
1 #!/bin/bash
2 make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- distclean
3 make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- mx6ull_14x14_ddr512_emmc_de fconfig
4 make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- -j12
宏CONFIG_BOOTCOMMAND 可以设置bootcmd的值
宏CONFIG_BOOTARGS也可以设置bootargs的值
找到uboot 根目录下面
make mx6ull_XXX_emmc_defconfig //默认配置
输入 make menuconfig 指令
// An highlighted block
var foo = 'bar';
/etc/environment是设置整个系统的环境,而/etc/profile是设置所有用户的环境,前者与登录用户无关,后者与登录用户有关。
sudo vi /etc/profile
打开/etc/profile 以后,在最后面输入如下所示内容:
export PATH=$PATH:/usr/local/arm/gcc-linaro-4.9.4-2017.01-x86_64_arm-linux-gnueabihf/bin
常用:
显示当前的目标
-f 不管什么属性 都可以删除
-r 删除文件夹
比如 U盘插入 写入数据 可能储存缓存区
du -h --max-depth=1
ps -aux 所有程序
一般都是Make
Make install
mount 当前文件 挂载到 目标地址
当前有中文内容是
sudo mount -o iocharset=utf8 原地址 + 目标地址
这边可以下载一个软件7ZIP
linux下常用的压缩扩展名 .tar .tar.bz2 .tar.gz
gzip xxx
gzip -t xxx.gz 解压缩
gzip 压缩文件夹
gzip -r 对文件文件进行
zidp2 -z xxx //压缩
bzip2 -d xxx.gz //解压缩
tar -vcf 目标文件 to 压缩文件
例如:tar -vcf test test.tar
tar -vxf test.tar 解包
详细参数
-f
-c 创建新归档,创建压缩文件
-x 从图档中解出文件,解压缩
-j 使用bzip2格式压缩
-z 使用gzip 格式进行压缩
-v 打印出命令执行的过程
sudo apt-get install gnome-system-tools
也可以命令 百度 adduser
ln --help
是多个文件指向一个inode
具有相同的多个文件互为硬链接文件
对于硬链接,只有删除源文件已经对应的所有硬链接文件实体文件才能被删除。
sudo apt-get install vim
输入 i
x 保存并退出
q 退出
w 保存
删除行 dd
u 撤销
… 重新当前操作
yy 复制光标所在行
nyy 复制光标一下n 个所在行
p q
设置vi 编译器tab 行
/etc/vim/vimrc
set ts=4
set nu
-c 只编译不连接
-o 编译后输出文件名称
-O 加优化
什么是Makefile呢???
其实就是编译怎么去编译的一个软件
场景:make工具所使用的文件,Makefile指明了编译的规则
假如没有Makefile gcc x1.c x2.c x2.c main
工具Makefile执行的原则是
没有被编译过 那么.c都要被编译成链接
有个个别文件修改了,那么我们就编译所有引用的C文件并且编译成可执行文件
未完成
输入make
目标 :依赖文件集合
命令一
命令二
sudo apt-get install vsftpd
sudo vi /etc/vsftpd.conf
打开以后 vsftpd.conf 文件以后找到如下两行:
local_enable=YES
write_enable=YES