20250519使用TF卡将NanoPi NEO core开发板刷机为Ubuntu core22.04.3系统完成之后执行poweroff自动关机

1、h3-sd-friendlycore-xenial-4.14-armhf-20210618.img.gz 在WIN10下使用7-ZIP解压缩/ubuntu20.04下使用tar
2、Win32DiskImager.exe 写如32GB的TF卡。【以管理员身份运行】
3、TF卡如果已经做过会有3个磁盘分区,可以使用SD Card Formatter/SDCardFormatterv5_WinEN.zip格式化TF卡。DiskGenius可以尝试。

制作好Ubuntu core22.04.3系统的IMG固件之后,还需要你编辑TF卡中的文件:
1、修改H:\eflasher.conf
autoStart=/mnt/sdcard/friendlycore-jammy
autoExit=true

2、root@NanoPi-NEO-Core:/opt# vi run-eflasher.sh 
root@NanoPi-NEO-Core:/opt# cat run-eflasher.sh 
poweroff

如果能够直接编辑IMG固件就好了。到时候写TF卡之后不需要每次都来编辑这两个文件。


20250519使用TF卡将NanoPi NEO core开发板刷机为Ubuntu core22.04.3系统完成之后执行poweroff自动关机
2025/5/19 15:38


缘起:在上电之后,TF卡将NanoPi NEO core开发板刷机之后自动关机,安全/保险一点。
【不会丢数据^_】

【你放心吧】生产线的工人只会问你插入TF卡之后上电几分钟刷机完成。【2分钟搞定】
不要想他们会去看DEBUG串口打印信息。


【切记,不需要在H:\eflasher.conf的autoStart项目之后手工输入autoExit项目。conf配置文件有/自带的。^_】
1、使用Win32DiskImager.exe写TF卡之后,将TF卡插入读卡器之后插入到WIN10/WIN11的电脑。
【理论上在ubuntu20.04.6下使用gedit修改也OK的。】
修改H:\eflasher.conf。【具体盘符H以您的电脑为准。^_不通的电脑肯定会变化的!】

C:\TF1emmc-jammy22.04\FriendlyARM\eflasher.conf

; This is the eFlasher configuration file.
; See http://wiki.friendlyarm.com/wiki/index.php/EFlasher for detailed information.

[General]
; Automate OS installation at system startup,
; Use the "autoStart" field to specify the image path or RAW image file,
; The RAW image file can be a gzip compressed file,
; The RAW image file extension must be ".raw" or ".gz",
; Available values: friendlycore-jammy
autoStart=friendlycore-jammy

; If the "autoExit" field set to true, the eflasher-gui will automatically exit after burning or restoring is completed, 
; You can do something else after burning or restoring by modifying /opt/run-eflasher.sh.
autoExit=false

; Don't erase the flash before burning, useful if you only want to update part of the system files
disableLowFormatting=false

[UI]
; HDMI overscan option, examples:
;     screenSizePercent=auto
;     screenSizePercent=90
screenSizePercent=auto

welcomeMessage=
hideMenuButton=false
hideBackupAndRestoreButton=false
hideStatusBar=false
autoRebootWhenSDBeEjected=true


修改成为:
H:\eflasher.conf

; This is the eFlasher configuration file.
; See http://wiki.friendlyarm.com/wiki/index.php/EFlasher for detailed information.

[General]
; Automate OS installation at system startup,
; Use the "autoStart" field to specify the image path or RAW image file,
; The RAW image file can be a gzip compressed file,
; The RAW image file extension must be ".raw" or ".gz",
; Available values: friendlycore-jammy
autoStart=/mnt/sdcard/friendlycore-jammy

; If the "autoExit" field set to true, the eflasher-gui will automatically exit after burning or restoring is completed, 
; You can do something else after burning or restoring by modifying /opt/run-eflasher.sh.
autoExit=true

; Don't erase the flash before burning, useful if you only want to update part of the system files
disableLowFormatting=false

[UI]
; HDMI overscan option, examples:
;     screenSizePercent=auto
;     screenSizePercent=90
screenSizePercent=auto

welcomeMessage=
hideMenuButton=false
hideBackupAndRestoreButton=false
hideStatusBar=false
autoRebootWhenSDBeEjected=true


2、将TF卡插入到NanoPi NEO core开发板,使用vi编辑run-eflasher.sh:【加入poweroff关机】

详细LOG:
root@NanoPi-NEO-Core:/# ll
total 72
drwxr-xr-x  19 root root  4096 Mar 20 14:32 ./
drwxr-xr-x  19 root root  4096 Mar 20 14:32 ../
drwxr-xr-x   2 root root  4096 Mar 20 14:32 Settings/
lrwxrwxrwx   1 root root     7 Aug 22  2023 bin -> usr/bin/
drwxr-xr-x   2 root root  4096 Apr 18  2022 boot/
drwxr-xr-x  14 root root  3860 Mar 20 14:32 dev/
drwxr-xr-x  65 root root  4096 Mar 20 14:32 etc/
drwxr-xr-x   3 root root  4096 Aug 22  2023 home/
lrwxrwxrwx   1 root root     7 Aug 22  2023 lib -> usr/lib/
drwx------   2 root root 16384 Apr  2  2025 lost+found/
drwxr-xr-x   2 root root  4096 Aug 22  2023 media/
drwxr-xr-x   4 root root  4096 Mar 21  2025 mnt/
drwxr-xr-x   2 root root  4096 Nov 28  2024 opt/
dr-xr-xr-x 116 root root     0 Jan  1  1970 proc/
drwx------   2 root root  4096 Mar 20  2023 root/
drwxr-xr-x  19 root root   520 Mar 20 14:32 run/
lrwxrwxrwx   1 root root     8 Aug 22  2023 sbin -> usr/sbin/
drwxr-xr-x   2 root root  4096 Aug 22  2023 srv/
dr-xr-xr-x  12 root root     0 Feb 11  2016 sys/
drwxrwxrwt  11 root root  4096 Mar 20 14:32 tmp/
drwxr-xr-x  11 root root  4096 Jul 16  2024 usr/
drwxr-xr-x  11 root root  4096 Aug 22  2023 var/
root@NanoPi-NEO-Core:/# cd opt/
root@NanoPi-NEO-Core:/opt# ll
total 3248
drwxr-xr-x  2 root root    4096 Nov 28  2024 ./
drwxr-xr-x 19 root root    4096 Mar 20 14:32 ../
-rwxr-xr-x  1 root root 3309892 Mar 19  2025 eflasher-gui*
-rwxr-xr-x  1 root root      80 Aug 25  2022 run-eflasher.sh*
root@NanoPi-NEO-Core:/opt# 
root@NanoPi-NEO-Core:/opt# 
root@NanoPi-NEO-Core:/opt# cp run-eflasher.sh /etc/
root@NanoPi-NEO-Core:/opt# ll
total 3248
drwxr-xr-x  2 root root    4096 Nov 28  2024 ./
drwxr-xr-x 19 root root    4096 Mar 20 14:32 ../
-rwxr-xr-x  1 root root 3309892 Mar 19  2025 eflasher-gui*
-rwxr-xr-x  1 root root      80 Aug 25  2022 run-eflasher.sh*
root@NanoPi-NEO-Core:/opt# 
root@NanoPi-NEO-Core:/opt# 
root@NanoPi-NEO-Core:/opt# vi run-eflasher.sh 
root@NanoPi-NEO-Core:/opt# 
root@NanoPi-NEO-Core:/opt# 
root@NanoPi-NEO-Core:/opt# vi run-eflasher.sh 
root@NanoPi-NEO-Core:/opt# ll
total 3248
drwxr-xr-x  2 root root    4096 Nov 28  2024 ./
drwxr-xr-x 19 root root    4096 Mar 20 14:32 ../
-rwxr-xr-x  1 root root 3309892 Mar 19  2025 eflasher-gui*
-rwxr-xr-x  1 root root      91 Mar 20 14:34 run-eflasher.sh*
root@NanoPi-NEO-Core:/opt# cat run-eflasher.sh 
#!/bin/bash

. /usr/bin/setqt4env

cd /opt/
./eflasher-gui -qws >/dev/null 2>&1

poweroff

root@NanoPi-NEO-Core:/opt# sync
root@NanoPi-NEO-Core:/opt# sync
root@NanoPi-NEO-Core:/opt# poweroff


3、上电刷机的LOG:
【在黄灯快闪的时候,通过top可以看见:eflasher-+ 在工作ING中!】

[  OK  ] Finished Permit User Sessions.
[  OK  ] Started Serial Getty on ttyS0.
         Starting Set console scheme...
[  OK  ] Finished Set console scheme.
[  OK  ] Created slice Slice /system/getty.
[  OK  ] Finished Load/Save Random Seed.
[  OK  ] Started OpenBSD Secure Shell server.

Ubuntu 22.04 LTS NanoPi-NEO-Core ttyS0

Default Login:
Username = pi
Password = pi

NanoPi-NEO-Core login: root
Password: 
Last login: Mon Mar 20 14:32:28 UTC 2023 on ttyS0
root@NanoPi-NEO-Core:~# top
top - 14:32:38 up 0 min,  1 user,  load average: 1.06, 0.27, 0.09
Tasks: 102 total,   2 running, 100 sleeping,   0 stopped,   0 zombie
%Cpu(s):  2.7 us, 13.6 sy,  0.0 ni, 53.6 id, 30.0 wa,  0.0 hi,  0.0 si,  0.0 st
MiB Mem :    491.8 total,     32.8 free,     74.6 used,    384.4 buff/cache
MiB Swap:      0.0 total,      0.0 free,      0.0 used.    401.8 avail Mem 

  PID USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND    
  374 root      20   0  102776  40396  19364 S  16.7   8.0   0:06.80 eflasher-+ 

  515 root      20   0    5712   2068   1804 R  12.5   0.4   0:00.09 top        
    1 root      20   0   31656   7472   5728 S   0.0   1.5   0:05.45 systemd    
    2 root      20   0       0      0      0 S   0.0   0.0   0:00.00 kthreadd   
    3 root      20   0       0      0      0 I   0.0   0.0   0:00.00 kworker/0+ 
    4 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 kworker/0+ 
    5 root      20   0       0      0      0 I   0.0   0.0   0:00.05 kworker/u+ 
    6 root       0 -20       0      0      0 I   0.0   0.0   0:00.00 mm_percpu+ 
    7 root      20   0       0      0      0 S   0.0   0.0   0:00.03 ksoftirqd+ 
    8 root      20   0       0      0      0 I   0.0   0.0   0:00.09 rcu_sched  
    9 root      20   0       0      0      0 I   0.0   0.0   0:00.00 rcu_bh     
   10 root      rt   0       0      0      0 S   0.0   0.0   0:00.03 migration+ 
   11 root      20   0       0      0      0 S   0.0   0.0   0:00.00 cpuhp/0    
   12 root      20   0       0      0      0 S   0.0   0.0   0:00.00 cpuhp/1    
   13 root      rt   0       0      0      0 S   0.0   0.0   0:00.00 migration+ 
   14 root      20   0       0      0      0 S   0.0   0.0   0:00.01 ksoftirqd+ 
top - 14:32:41 up 0 min,  1 user,  load average: 1.06, 0.27, 0.09
Tasks: 101 total,   2 running,  99 sleeping,   0 stopped,   0 zombie
%Cpu(s):  0.9 us, 13.0 sy,  0.0 ni, 80.1 id,  6.0 wa,  0.0 hi,  0.0 si,  0.0 st
MiB Mem :    491.8 total,     26.3 free,     74.6 used,    390.9 buff/cache
MiB Swap:      0.0 total,      0.0 free,      0.0 used.    401.5 avail Mem 


4、完美谢幕/曲终人散,上电大概2分钟之后,你就可以看到TF卡旁边的红灯/黄灯都灭了!
【刷机完成了。拔卡,下一个!NEXT ^_】

如果你接入了串口,就可以在串口打印中看到NanoPi NEO core开发板执行关机步骤的LOG了。

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.pswp.cn/diannao/84084.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

编译Qt5.15.16并启用pdf模块

编译Qt5.15.16并启用pdf模块 标题1.目录设置 -q-bulid –qt-everywhere-src-5.15.16 –bulid cd bulid 必须,否则会提示Project ERROR: You cannot configure qt separately within a top-level build. create .qmake.stash and .qmake.super in build folder …

“智”斗秸秆焚烧,考拉悠然以科技之力筑牢生态安全防线

清晨,薄雾笼罩着辽阔的田野,农民们开始了一天的劳作。然而,随着收割季的到来,秸秆焚烧问题也逐渐浮现,成为威胁空气质量与生态安全的隐患。传统监管方式往往显得力不从心,效率低下的困境亟待突破。在此背景…

Nockchain项目部署教程

Nockchain头矿窗口正在打开,不拼设备,现在部署,马上就要开挖了。 一、项目介绍 Nockchain 是结合了POW和ZKVM的区块链协议。 主要特点: 1)计算存储新域名空间三位一体架构,高吞吐量 2)使用No…

2025年气候持续大风,消纳减少,如何保收益?东润能源整体解决方案持续保收益保增长

引言 随着全球气候变化加剧,2025年极端天气频发,风资源丰富但电网消纳能力不足的问题日益突出,导致许多风电项目面临限电、收益下滑的挑战。如何在复杂的气候和电力市场环境下保障投资收益,成为行业关注的焦点。东润能源凭借领先的技术创新和综合能源解决方案,为风电行业…

2023河南CCPC省赛vp部分补题

A 模拟 暴力 对每个合法的前缀&#xff0c;判断后缀是不是合法 int a[29]; void solve(){string s;cin>>s;int t-1;if(s.size()1){return cout<<"NaN"<<endl,void();}for(int i0;i<27;i) a[i]0;for(int i0;i<s.size();i){a[s[i]-a];if(…

【2025保姆级】Open-WebUI五大功能区首曝!第一篇:管理员面板深度拆解,手把手讲解配置AI管理中枢

【2025保姆级】Open-WebUI五大功能区首曝&#xff01;第一篇&#xff1a;管理员面板深度拆解&#xff0c;手把手讲解&配置AI管理中枢 一、引言二、用户2.1 概述2.2 权限组 三、竞技场评估四、函数五、设置5.1 通用5.1.1 身份验证5.1.2 功能 5.2 外部连接5.2.1 OpenAI API5.…

docker上传镜像

向Docker Hub上传镜像&#xff0c;需要按照一定的步骤进行操作。 Docker Hub是Docker的官方镜像仓库&#xff0c;用户可以在其中存储、管理和部署Docker镜像。要向Docker Hub上传镜像&#xff0c;请遵循以下步骤&#xff1a; 创建Docker Hub账户&#xff1a; 访问Docker Hub官…

(十三)深入了解AVFoundation-采集:视频帧采集与实时滤镜处理

引言 在移动应用中&#xff0c;实时视频处理已成为视频拍摄、短视频、直播、美颜相机等功能的核心技术之一。从简单的滤镜叠加&#xff0c;到复杂的美颜、AR 特效&#xff0c;背后都离不开对每一帧图像的高效采集与处理。在前几篇文章中&#xff0c;我们已经实现了基本的视频采…

数字政务安全实战:等保2.0框架下OA系统防护全解析

近期在Python基础教学领域深入钻研函数机制、数据结构优化等内容时&#xff0c;深刻意识到信息安全作为技术基石的战略价值。在政务数字化转型浪潮中&#xff0c;Python凭借其高扩展性与丰富的安全生态库&#xff0c;成为构建政务OA系统安全防护体系的核心工具。本文将以等保2.…

Pytorch项目实战-2:花卉分类

一、前言 在深度学习项目中&#xff0c;数据集的处理和模型的训练、测试、预测是关键环节。本文将为小白详细介绍从数据集搜集、清洗、划分到模型训练、测试、预测以及模型结构查看的全流程&#xff0c;附带代码和操作说明&#xff0c;让你轻松上手&#xff01; 二、数据集 …

React Flow 边事件处理实战:鼠标事件、键盘操作及连接规则设置(附完整代码)

本文为《React Agent&#xff1a;从零开始构建 AI 智能体》专栏系列文章。 专栏地址&#xff1a;https://blog.csdn.net/suiyingy/category_12933485.html。项目地址&#xff1a;https://gitee.com/fgai/react-agent&#xff08;含完整代码示​例与实战源&#xff09;。完整介绍…

java小结(一)

java&#xff08;上&#xff09; 模块一 1.JDK,JRE,JVM 知识点 核心内容 易混淆点 JDK定义 Java Development Kit&#xff08;Java开发工具包&#xff09;&#xff0c;包含开发所需全部工具 JDK包含JRE的关系容易混淆 JRE定义 Java Runtime Environment&#xff08;Jav…

ddns-go安装介绍-强大的ipv6动态域名解析神器-家庭云计算专家

ddns-go 是一款轻量级开源动态域名解析工具&#xff0c;专注于解决动态IP环境下的域名绑定问题&#xff0c;尤其适配IPv6网络环境。其核心功能包括&#xff1a; 1.IPv6动态解析&#xff1a;自动检测本地IPv6地址变化&#xff08;支持网卡、接口或命令获取&#xff09;&#xf…

Docker-mongodb

拉取 MongoDB 镜像: docker pull mongo 创建容器并设置用户&#xff1a; 要挂载本地数据目录&#xff0c;请替换此路径: /Users/Allen/Env/AllenDocker/mongodb/data/db docker run -d --name local-mongodb \-e MONGO_INITDB_ROOT_USERNAMEadmin \-e MONGO_INITDB_ROOT_PA…

WooCommerce缓存教程 – 如何防止缓存破坏你的WooCommerce网站?

我们在以前的文章中探讨过如何加快你的WordPress网站的速度&#xff0c;并研究过各种形式的缓存。 然而&#xff0c;像那些使用WooCommerce的动态电子商务网站&#xff0c;在让缓存正常工作方面往往会面临重大挑战。 在本指南中&#xff0c;我们将告诉你如何为WooCommerce设置…

贪心算法 Part04

总结下重叠区间问题 LC 452. 用最少数量的箭引爆气球 和 LC 435. 无重叠区间 本质上是一样的。 LC 452. 用最少数量的箭引爆气球 是求n个区间当中 &#xff0c; 区间的种类数量 k。此处可以理解为&#xff0c;重叠在一起的区间属于同一品种&#xff0c;没有重叠的区间当然…

云原生CD工具-Argocd+ArgoRollout入门到精通

第一章 Argo CD简介 课时1.1 Argo产品介绍 ARGO官网地址:https://argoproj.github.io/ 旗下产品有: Argo Workflows、ArgoCD 、Argo Rollouts 、Argo Events 课时1.2 什么是Argo CD Argo CD 是一个开源的持续交付工具, 是 Kubernetes 的声明式 GitOps 持续交付工具。专…

数据分析与应用---数据可视化基础

目录 Matplotlib基础绘图 (一)、pyplot绘图基础语法与常用参数 1、pyplot基础语法 (1) 创建画布与创建子图 (2) 添加画布内容 (3) 保存与显示图形 案例代码 2. 设置pyplot的动态rc参数 (二)、使用Matplotlib绘制进阶图形 1. 绘制散点图----scatter 2. 绘制折线…

PP-YOLOE-SOD学习笔记1

项目&#xff1a;基于PP-YOLOE-SOD的无人机航拍图像检测案例全流程实操 - 飞桨AI Studio星河社区 一、安装环境 先准备新环境py>3.9 1.先cd到源代码的根目录下 2.pip install -r requirements.txt 3.python setup.py install 这一步需要看自己的GPU情况&#xff0c;去飞浆…

力扣HOT100之二叉树:114. 二叉树展开为链表

这道题自己尝试着做了一下&#xff0c;感觉还是得用递归来做比较简单&#xff0c;但是一直想的是用前序遍历来构造链表&#xff0c;导致怎么做都不对&#xff0c;去看了下灵神的题解&#xff0c;然后问了下GPT&#xff0c;现在终于弄明白了。虽然构造出来的链表的排列顺序是按照…