您尚未登录。

楼主 # 2023-12-26 00:58:16

evilbinary
会员
注册时间: 2021-07-25
已发帖子: 10
积分: 196

熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

E688359B38CBF17F9CB6D0B619C31D27.jpg

克隆项目

git clone https://github.com/evilbinary/YiYiYa.git
make pull

安装构建工具

pip install yymake

ya -m debug -p v3s -run=v3s

编译

ya -m debug -p v3s -run=v3s
welcome to use ymake 0.7.3 ,make world happy ^_^!!
tinyusb todo support
[1%]:compile  target archcommon
[2%]:compile  target platform
[2%]:compile  target arch
[3%]:compile  target algorithm
[4%]:compile  target kernel
[5%]:compile  target gcc
[6%]:compile  target mod-queue
[6%]:compile  target mod-devfs
[7%]:compile  target mod-bcm
[8%]:compile  target musl
[9%]:compile  target mod-debug
[9%]:compile  target mod-gaga
[10%]:compile  target mod-musl
[11%]:compile  target mod-ipc
[12%]:compile  target mod-pty
[13%]:compile  target mod-log
[13%]:compile  target mod-gpio
[14%]:compile  target mod-rtc
[15%]:compile  target mod-sdhci
[16%]:compile  target mod-mouse
[17%]:compile  target mod-gpu
[17%]:compile  target mod-fat
[18%]:compile  target mod-test
[19%]:compile  target mod-posix
[20%]:compile  target mod-loader
[20%]:compile  target mod-spi
[21%]:compile  target mod-i2c
[22%]:compile  target mod-serial
[23%]:compile  target zlib
[24%]:compile  target kernelcommon
[24%]:compile  target modules
[25%]:compile  target png
[26%]:compile  target jpeg
arm-none-eabi-ld build/v3s/armv7-a/debug/objs/duck/init/main.o build/v3s/armv7-a/debug/objs/duck/init/module.o build/v3s/armv7-a/debug/objs/duck/init/init.o build/v3s/armv7-a/debug/objs/duck/init/monitor.o build/v3s/armv7-a/debug/objs/duck/init/test.o -o build/v3s/armv7-a/debug/kernel.elf -Lbuild/v3s/armv7-a/debug -T/Users/evil/dev/c/YiYiYa/duck/xlinker/link-v3s.ld -lmod-serial -lmod-i2c -lmod-spi -lmod-loader -lmod-posix -lmod-test -lmod-fat -lmod-gpu -lmod-mouse -lmod-sdhci -lmod-rtc -lmod-gpio -lmod-log -lmod-pty -lmod-ipc -lmod-musl -lmod-gaga -lmod-debug -lmod-bcm -lmod-devfs -lmod-queue -lkernel -lalgorithm -larch -lplatform -larchcommon -lkernelcommon
arm-none-eabi-ld: 警告: 无法找到项目符号 _kstart; 缺省为 42000000
[26.100%]:compile  target build/v3s/armv7-a/debug/kernel.elf
arm-none-eabi-objcopy -S build/v3s/armv7-a/debug/kernel.elf build/v3s/armv7-a/debug/kernel
arm-none-eabi-objcopy --only-keep-debug build/v3s/armv7-a/debug/kernel.elf build/v3s/armv7-a/debug/kernel.dbg
arm-none-eabi-objcopy -O binary -S build/v3s/armv7-a/debug/kernel.elf build/v3s/armv7-a/debug/kernel.bin
[27%]:compile  target kernel.elf
[28%]:compile  target gui
kernel gen target boot-config
file-> build/v3s/armv7-a/debug/kernel
kernel gen start build/v3s/armv7-a/debug/kernel
file size  173124 kernel size  175104 block size  171
generated header file success. /Users/evil/dev/c/YiYiYa/boot/arm/config.h
[28%]:compile  target boot-config
[29%]:compile  target sdl2
[30%]:compile  target lz4
[31%]:compile  target uuid
[31%]:compile  target ncurses
[32%]:compile  target lvgl
[33%]:compile  target freetype
arm-none-eabi-ld build/v3s/armv7-a/debug/objs/boot/arm/boot-armv7-a.o build/v3s/armv7-a/debug/objs/boot/arm/init.o -o build/v3s/armv7-a/debug/boot-init.elf -Lbuild/v3s/armv7-a/debug -T/Users/evil/dev/c/YiYiYa/boot/arm/link-v3s.ld -lkernelcommon -lmod-serial -lmod-i2c -lmod-spi -lmod-loader -lmod-posix -lmod-test -lmod-fat -lmod-gpu -lmod-mouse -lmod-sdhci -lmod-rtc -lmod-gpio -lmod-log -lmod-pty -lmod-ipc -lmod-musl -lmod-gaga -lmod-debug -lmod-bcm -lmod-devfs -lmod-queue -lkernel -lalgorithm -larch -lplatform -larchcommon
arm-none-eabi-ld: warning: build/v3s/armv7-a/debug/boot-init.elf has a LOAD segment with RWX permissions
[33.100%]:compile  target build/v3s/armv7-a/debug/boot-init.elf
arm-none-eabi-objcopy -O binary build/v3s/armv7-a/debug/boot-init.elf build/v3s/armv7-a/debug/boot-init.bin
[34%]:compile  target boot-init.elf
[35%]:compile  target gaga
[35%]:compile  target sdl
[36%]:compile  target sdl2-image
[37%]:compile  target quickjs
[38%]:compile  target chez
[39%]:compile  target lua
[39%]:compile  target lvqrcode
[40%]:compile  target image
[41%]:compile  target sdl2-ttf
[42%]:compile  target lvgl-8.0.0
[43%]:compile  target etk
[43%]:compile  target cmocka
[44%]:compile  target webp
mkimage -f build/v3s/armv7-a/debug/kernel-v3s.its build/v3s/armv7-a/debug/duck.fit
FIT description: Simple image with single duck kernel
Created:         Mon Dec 25 01:36:34 2023
 Image 0 (setup)
  Description:  YiYiYa init
  Created:      Mon Dec 25 01:36:34 2023
  Type:         Kernel Image
  Compression:  uncompressed
  Data Size:    5224 Bytes = 5.10 kB = 0.00 MB
  Architecture: ARM
  OS:           Linux
  Load Address: 0x00000000
  Entry Point:  0x00000000
  Hash algo:    sha1
  Hash value:   4d5ae7867d67f7ab561e7cc7061788e9f187b181
 Image 1 (kernel)
  Description:  YiYiYa kernel
  Created:      Mon Dec 25 01:36:34 2023
  Type:         RAMDisk Image
  Compression:  uncompressed
  Data Size:    173124 Bytes = 169.07 kB = 0.17 MB
  Architecture: ARM
  OS:           Linux
  Load Address: 0x40000000
  Entry Point:  0x40000000
  Hash algo:    crc32
  Hash value:   1811acee
  Hash algo:    sha1
  Hash value:   5ee9ee2bb71e1a7b593a63accd781516b77f0dfe
 Default Configuration: 'config-1'
 Configuration 0 (config-1)
  Description:  YiYiYa init
  Kernel:       setup
  Init Ramdisk: kernel
 Configuration 1 (config-2)
  Description:  YiYiYa kernel
  Kernel:       kernel
[45%]:compile  target duck.fit
[46%]:compile  target disk.img
[46%]:compile  target duck.img
[47%]:compile  target mod-pic
[48%]:compile  target systemd
[49%]:compile  target vfsd
[50%]:compile  target serviceb
[50%]:compile  target servicea
[51%]:compile  target tinyusb
[52%]:compile  target testbitmap
[53%]:compile  target testoverlay2
[54%]:compile  target testoverlay
[54%]:compile  target testwm
[55%]:compile  target watch
[56%]:compile  target gnuboy
[57%]:compile  target qjs
[57%]:compile  target qjsc
[58%]:compile  target scheme
[59%]:compile  target lua.elf
[60%]:compile  target mgba
[61%]:compile  target launcher
[61%]:compile  target infones
[62%]:compile  target sdl2.elf
[63%]:compile  target showfont
[64%]:compile  target showimage
[65%]:compile  target track
[65%]:compile  target lvgl.elf
[66%]:compile  target etk.elf
[67%]:compile  target microui
[68%]:compile  target pngtest
[69%]:compile  target test-thread
[69%]:compile  target test-sys
[70%]:compile  target test-sound
[71%]:compile  target test-free
[72%]:compile  target test-fork
[72%]:compile  target test-stdio
[73%]:compile  target test-string
[74%]:compile  target test-uncompress
[75%]:compile  target test-mem
[76%]:compile  target test-file
[76%]:compile  target test-musl
[77%]:compile  target test
[78%]:compile  target hello
[79%]:compile  target gui.elf
[80%]:compile  target touch
[80%]:compile  target shell
[81%]:compile  target ls
[82%]:compile  target kill
[83%]:compile  target hexdump
[83%]:compile  target echo
[84%]:compile  target date
[85%]:compile  target cat
[86%]:compile  target sdl-image
[87%]:compile  target sdl-ttf
[87%]:compile  target v3s
[88%]:compile  target raspi2
[89%]:compile  target qemu
[90%]:compile  target debug
[91%]:compile  target uImage.img
[91%]:compile  target mod-keyboard
[92%]:compile  target mod-vga
[93%]:compile  target mod-sb16
[94%]:compile  target mod-hello
[94%]:compile  target mod-dma
[95%]:compile  target mod-fat32
[96%]:compile  target mod-lcd
[97%]:compile  target mod-ewok
[98%]:compile  target mod-net
[98%]:compile  target mod-ahci
[99%]:compile  target mod-pci
[100%]:compile  target mod-fatfs
build success! cost 0:00:01.302443
run v3s fel build/v3s/armv7-a/debug/duck.fit
AWUSBFEX soc=00001681(V3s) 00000001 ver=0001 44 08 scratchpad=00007e00 00000000 00000000

串口中输入运行
infones mario.nes

boot
Hello,YiYiYa OS
display init
test display hello,YiYiYa
interrupt init cpu 0
mm init
phy dump
base:0 0 lenght:0 40000000 type:1
total memory 1024m 1048576k
alloc init
kernel base 100000 end 14b800
add block:0 type:1 size:1048552 start: 18 end:100000
add block:14b800 type:1 size:1072383976 start: 14b818 end:40000000
[00000000] tid:0 info  exception init
[00000000] tid:0 info  page init
map mem block start
map mem block addr range 14b800 - 285b800
map mem range
map mem kernel
map kernel start
map kernel 0 range 100000  - 1245da type 1
map kernel 1 range 125000  - 134228 type 1
map kernel end 2
[00000000] tid:0 info  page enable page: 14c000
enable page
paging success
[00000000] tid:0 info  page enable end
[00000000] tid:0 info  syscall init
[00000000] tid:0 info  schedule init
timer init
cntfrq 62500
val 59063
[00000000] tid:0 info  module init
[00000000] tid:0 info  memory init
[00000000] tid:0 info  vfs init
[00000000] tid:0 info  thread init
[00000000] tid:0 info  event init
[00000000] tid:0 info  kernel init end
[00000000] tid:0 debug tid 0 kpage 14c000 upage 14c000
[00000000] tid:0 debug tid 0 ksp 18c628 usp 90100000
[00000000] tid:0 debug tid 1 kpage 14c000 upage 194000
[00000000] tid:0 debug tid 1 ksp 19113c usp 70100000
[00000000] tid:0 info  kernel run start
[00000001] tid:0 info  module regist
[00000022] tid:0 info  module regist end
[00000024] tid:0 info  module run devfs
[00000026] tid:0 warn  not fond device 0
[00000027] tid:0 warn  not fond device 2
[00000028] tid:0 warn  not fond device 3
[00000029] tid:0 warn  not fond device 6
[00000031] tid:0 warn  not fond device 22
[00000033] tid:0 info  module run serial
[00000037] tid:0 info  module run i2c
[00000038] tid:0 info  i2c init
[00000039] tid:0 info  module run gpio
[00000040] tid:0 info  gpio init
[00000041] tid:0 info  module run spi
[00000063] tid:0 debug spi
[00000063] tid:0 info  module run vga
[00000065] tid:0 debug map box 3f00b000
[00000067] tid:0 debug fb addr:3c100000 end:3d0f0000 len:3fc000
[00000069] tid:0 debug map fb start 3c100000 3c100000
[00000071] tid:0 debug map fb end 3c4fc000 3c4fc000
[00000072] tid:0 info  gpu_init_device end
[00000074] tid:0 info  module run mouse
[00000075] tid:0 info  module run sdhci
[00000077] tid:0 info  sdhci_init
[00000104] tid:0 info  module run fat
[00000105] tid:0 info  fat init
[00000108] tid:0 debug empty partition entry
[00000109] tid:0 info  partition type:ff offset:0 length:0
[00000112] tid:0 info  fat init end
[00000113] tid:0 info  module run test
[00000114] tid:0 info  test hello
[00000116] tid:0 info  module run rtc
[00000117] tid:0 info  module run posix
[00000118] tid:0 info  posix init
[00000120] tid:0 info  module run pty
[00000121] tid:0 info  module run log
[00000142] tid:0 info  module run loader
[00000143] tid:0 debug loader init
[00000144] tid:0 info  module run musl
[00000145] tid:0 info  musl init
[00000146] tid:0 info  enable float
[00000147] tid:0 info  module run gaga
[00000150] tid:0 debug gaga init
[00000153] tid:0 info  module run ytrace
 _  _  _ _  _  _      
| || || | || || |     
| \| |/ | \| |/ __  __
 \_   _/ \_   _/  \/ /
   | |     | |( ()  < 
   |_|     |_| \__/\_\

2021 - 2080 Copyright by evilbinary 
version 1.4 Dec 26 2023 00:26:29
https://github.com/evilbinary/YiYiYa

Welcome to YiYiYa Os ^_^! 

yiyiya$[00000164] tid:1 debug sys open new name: /dev/series addr:121260 fd:2 fd->id:2 ptr:126bfc fd->name:/dev/series
[00000165] tid:1 debug sys open new name: / addr:12126c fd:3 fd->id:3 ptr:126c14 fd->name:/

yiyiya$
yiyiya$infones mario.nes
[00007743] tid:1 debug sys access not impl /bin/infones
[00007743] tid:1 debug sys open new name: /bin/infones addr:700ffef4 fd:3 fd->id:4 ptr:126c2c fd->name:/bin/infones
[00007744] tid:1 debug thread copy start
[00007744] tid:1 debug thread init default
[00007744] tid:1 debug tid 2 kpage 14c000 upage 1e8000
[00007744] tid:1 debug tid 2 ksp 1e7d4c usp 70100000
[00007744] tid:1 debug thread copy end
[00007745] tid:1 debug sys get pid 1
yiyiya$[00007752] tid:2 debug sys get pid 2
[00007753] tid:2 debug sys exec file /bin/infones addr 700ffef4 tid name init
[00007753] tid:2 debug sys open new name: /bin/infones addr:700ffef4 fd:3 fd->id:4 ptr:126c2c fd->name:/bin/infones
[00007753] tid:2 debug argv[0]=infones 700ffdf4
[00007753] tid:2 debug argv[1]=mario.nes 700ffdf8
[00007753] tid:2 debug envp 0 argc 2
[00007754] tid:2 debug sys open new name: /bin/infones addr:700ffef4 fd:3 fd->id:4 ptr:126c2c fd->name:/bin/infones
[00007760] tid:2 debug sys fn faild f0005
[00007760] tid:2 debug sys set thread area not impl 
[00007761] tid:2 debug sys set tid adress not impl
[00007782] tid:2 debug sys open new name: /dev/stdin addr:7106912c fd:4 fd->id:0 ptr:126bcc fd->name:/dev/stdin
[00007783] tid:2 debug sys open new name: /dev/fb addr:71069140 fd:5 fd->id:5 ptr:126c44 fd->name:/dev/fb
screen init fd:5
[00007787] tid:2 debug map box 3f00b000
[00007787] tid:2 debug fb addr:3c100000 end:3d0f0000 len:3fc000
[00007787] tid:2 debug map fb start 3c100000 3c100000
[00007787] tid:2 debug map fb end 3c4fc000 3c4fc000
[00007787] tid:2 info  gpu_init_device end
screen init 480x272 bpp:32 fb count:1 len:1880096768 buffer len:0
[00007789] tid:2 debug sys open name return : /dev/stdin fd: 4
[00007790] tid:2 debug sys open new name: /dev/mouse addr:71069270 fd:6 fd->id:6 ptr:126c5c fd->name:/dev/mouse
[00007795] tid:2 debug sys open new name: mario.nes addr:711202fc fd:7 fd->id:7 ptr:126c74 fd->name:mario.nes
InfoNES_SoundOpen: samples_per_sync=735, sample_rate=44100

运行效果图

最近编辑记录 evilbinary (2023-12-26 23:01:38)

离线

#2 2023-12-27 15:06:14

musich
会员
注册时间: 2018-04-17
已发帖子: 226
积分: 258

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

几百个通宵, 我没看错吧,   这干劲大啊.

离线

#3 2023-12-27 15:14:49

musich
会员
注册时间: 2018-04-17
已发帖子: 226
积分: 258

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

裸奔, 能搞定硬件JPEG吗?

离线

#4 2023-12-27 16:10:42

mango
会员
所在地: 芒果派
注册时间: 2017-12-02
已发帖子: 779
积分: 730

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

直接上匠心,官方支持裸机/RTT/buildroot,片上资源也比V3s多得多






歪朵拉开源硬件: https://widora.cn
淘宝:  https://widora.taobao.com/

离线

#5 2023-12-27 19:32:12

musich
会员
注册时间: 2018-04-17
已发帖子: 226
积分: 258

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

V3S带网络phy, 这点非常方便,  1.2G的主频性能也不弱,   

试过同是C906核心的全志D1s, 主频720MHz,  跑软编2路解8路MP3,网口收发音频,Mic降噪,512点FFT+动态频谱显示,
V3S可以到152帧,  D1s平均只有90帧左右,波动有点大,还没弄明白原因;

匠心最高主频600M,不带网口hpy, 有点遗憾, 坐等IAR出来再体验.

离线

#7 2023-12-29 13:51:10

armstrong
会员
注册时间: 2019-04-10
已发帖子: 256
积分: 170.5

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

楼主的yiyiya os是什么类型的OS?是posix接口的OS吗?为什么称之为裸机呢?

离线

楼主 #8 2023-12-30 12:25:39

evilbinary
会员
注册时间: 2021-07-25
已发帖子: 10
积分: 196

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

armstrong 说:

楼主的yiyiya os是什么类型的OS?是posix接口的OS吗?为什么称之为裸机呢?

是这样的,posix不是必须的,随时可以丢弃,这样就是裸机了

离线

#9 2023-12-31 18:38:09

armstrong
会员
注册时间: 2019-04-10
已发帖子: 256
积分: 170.5

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

只能说,太牛逼了!

离线

#10 2024-02-05 09:43:58

lg676041036
会员
注册时间: 2021-07-09
已发帖子: 35
积分: 34

Re: 熬了几百个通宵,终于搞定V3S裸奔(从boot写起,到程序运行)

mango 说:

直接上匠心,官方支持裸机/RTT/buildroot,片上资源也比V3s多得多

大佬说详细点,公司全名叫啥?哪款芯片?

离线

页脚

工信部备案:粤ICP备20025096号 Powered by FluxBB

感谢为中文互联网持续输出优质内容的各位老铁们。 QQ: 516333132, 微信(wechat): whycan_cn (哇酷网/挖坑网/填坑网) service@whycan.cn