星期一到星期日英文
micropython编译流程
最近终于都考完了,虽然最近没有发帖⼦,可是还是看了挺多东西的,都不深,就⾃⼰写⼀点⾃⼰做的⼯作。
git上⾯下载了micropython源码 这⾥就不留地址了,因为下下来还是需要改很多,,虽然我也不知道为什么还有不对的地⽅,可能环境不太相同,可能是我README没有看仔细。
//下载了 micropython源码,其中不包含其⼦项⽬,也就是你要应⽤在micropython在哪个环境中,那个对应环境的HAL或者是底层库没有包括其中,需要你⾃⼰下载 。README中有详细介绍。
哒哒英语 收费/没⼿动下载stm32lib之前的错误 git之后⽆stm32的lib
root@charles-VirtualBox:/media/sf_Linux/micropython-master/ports/stm32# make
U make V=1 or t BUILD_VERBOSE in your environment to increa build verbosity.
stm32lib submodule not found, fetching
(cd ../.. && git submodule update --init lib/stm32lib)
error: pathspec 'lib/stm32lib' did not match any file(s) known to git.
Makefile:352: recipe for target '../../lib/stm32lib/README.md' failed
make: *** [../../lib/stm32lib/README.md] Error 1
⼿动下载的stm32lib之后的错误
root@charles-VirtualBox:/media/sf_Linux/micropython-master/ports/stm32# make BOARD=CANNON
U make V=1 or t BUILD_VERBOSE in your environment to increa build verbosity.
mkdir -p build-CANNON/genhdr
Create build-CANNON/genhdr/pins.h
Create stmconst build-CANNON/modstm_qstr.h
Create build-CANNON/genhdr/pybcdc.inf
Create build-CANNON/genhdr/pybcdc_inf.h
Create build-CANNON/genhdr/pllfreqtable.h
Generating build-CANNON/genhdr/mpversion.h
GEN build-CANNON/genhdr/qstr.i.last
/bin/sh: 1: /media/sf_Linux/gcc-arm-none-eabi-linux/gcc-arm-noneezbi/bin/arm-none-linux-gnueabi-gcc: not found
../../py/mkrules.mk:73: recipe for target 'build-CANNON/genhdr/qstr.i.last' failed
make: *** [build-CANNON/genhdr/qstr.i.last] Error 127
make: *** Deleting file 'build-CANNON/genhdr/qstr.i.last'viper是什么
tonight是什么意思
///修改了makefile中的路径
CC ../../py/../extmod/uos_dupterm.c
CC ../../py/../lib/embed/abort_.c
cnn官网CC ../../py/../lib/utils/printf.c
MPY modules/lcd160cr.py
Traceback (most recent call last):
File "modules/lcd160cr.py", line 1
SyntaxError: invalid syntax
../../py/mkrules.mk:115: recipe for target 'build-CANNON/frozen_mpy/lcd160cr.mpy' failed
make: *** [build-CANNON/frozen_mpy/lcd160cr.mpy] Error 1
root@charles-VirtualBox:/media/sf_Linux/micropython-master/ports/stm32#
北京爱迪国际学校
//把lcd160cr.py lcd160cr_test.py onewire.py
ayer//路径micropython-master\ports\stm32\modules下的显⽰函数都杠掉了
省略编译⼀堆lib下的库和stm32lib
CC usbdev/core/src/usbd_core.c
busy什么意思CC usbdev/core/src/usbd_ctlreq.c
CC usbdev/core/src/usbd_ioreq.c
CC usbdev/class/src/usbd_cdc_msc_hid.c
CC usbdev/class/src/usbd_msc_bot.c
CC usbdev/class/src/usbd_msc_scsi.c
CC usbdev/class/src/usbd_msc_data.c
CC build-CANNON/pins_CANNON.c
LINK build-CANNON/firmware.elf
build-CANNON/dma.o: In function `dma_init':
dma.c:(.text.dma_init+0xda): undefined reference to `DMA_CalcBaAndBitshift' Makefile:402: recipe for target 'build-CANNON/firmware.elf' failed
astomake: *** [build-CANNON/firmware.elf] Error 1
aoqstm32f4xx_hal_dma.h⽂件 691⾏
添加
uint32_t DMA_CalcBaAndBitshift(DMA_HandleTypeDef *hdma);//dd add
stm32f4xx_hal_dma.c⽂件
DMA_CalcBaAndBitshift函数的 static去掉
编译成功
虽然现在还没有成功下进去 ,不过我感觉快了。 欢迎指正