[RK-Linux] Linux A/B System详解

所谓的 A/B System 即把系统固件分为两份,分别称为 slot-a , slot-b 。系统可以从任意一个 slot 启动,当一个 slot 启动失败后还可以从另一个启动,在 Normal 模式下直接升级系统,无需进入系统升级模式,只需重启系统即可进入升级过的系统。

A/B System 由于有两个引导 slot,所以具有以下优点:

  1. 升级无需重启进入升级模式,即机器可以在当前系统上直接进行升级。
  2. 防止由于升级失败导致机器变砖,如果升级失败,机器可以回到当前版本。
  3. 当前系统如果由于一些误操作被破坏掉,系统会自动切换到另外一个 slot 上。

缺点:

  1. A/B System 有两个 slot,所以会增加 flash 上系统固件的占用率。

一、配置项

U-Boot 需要依赖 LIBAVB ,如下:

# A/B System依赖的库
CONFIG_AVB_LIBAVB=y
CONFIG_AVB_LIBAVB_AB=y
嵌入式Linux开机自启实战:System V init机制解析与RK3588应用配置 在嵌入式Linux系统开发中,服务管理是确保设备稳定运行的核心基础。System V init作为经典的初始化系统,通过串行执行/etc/init.d目录下的脚本来控制系统启动流程,其原理在于利用S/K前缀及两位数字排序号来定义服务的启动与停止顺序。这套机制在资源受限或定制化的嵌入式环境中,因其简单、可控和低开销,依然具有重要的技术价值,尤其适用于由Buildroot构建的轻量级系统。在实际应用场景中,无论是需要替换默认桌面的Qt图形应用,还是像WiFi自动连接这样的后台守护进程,都可以通过编写符合LSB规 阅读详情

相关推荐

RK3568/RK3588 Android 12单独编译内核与快速烧录实践

在嵌入式Android开发中,内核编译与镜像烧录是BSP工程师高频操作。面向RK3568/RK3588的Android 12 SDK,全量编译一次往往需要数十分钟,极大拖慢调试节奏。单独编译内核则能通过增量构建生成boot.img,结合fastboot命令快速烧录,将迭代缩短到几分钟。理解boot分区结构、设备树dtb打包机制以及内核与用户空间的解耦原理,是高效调试的基础。该流程适用于摄像头传感器适配、屏幕调试、驱动移植等典型场景。系统拆解单独编译内核的三种实现路径、烧录验证方法以及常见坑点,帮助开发者少走

weixin_33906657的博客 259

手把手教你为TB-RK3576D0编译Buildroot Linux系统(RK3576 SDK实战)

本文详细介绍了如何为TB-RK3576D0开发板编译Buildroot Linux系统的完整流程,包括环境准备、SDK获取、Buildroot配置、内核调整、系统编译与烧录等关键步骤。针对瑞芯微RK3576处理器的特性,提供了实用的优化建议和常见问题解决方案,帮助开发者快速上手嵌入式Linux系统开发。

weixin_30897233的博客 131

RK3568边缘网关开发实战:五大常见坑与调试经验详解

在嵌入式Linux开发中,设备树(Device Tree)是连接硬件与操作系统的关键桥梁,它以树状结构描述内存、GPIO、I2C、网络PHY等硬件资源,让内核能精准驱动外设。正确配置设备树是嵌入式系统稳定运行的基石,尤其在边缘计算网关、物联网关等场景中,设备树配置错误往往导致网口协商失败、摄像头黑屏等棘手问题。针对RK3568等主流国产SoC平台,实际项目里常遇到设备树选择困难、PHY时钟与复位时序异常、MIPI摄像头调试链路复杂、构建环境依赖冲突等挑战。基于RK3568边缘网关项目的真实开发经验,梳理出从

weixin_34060299的博客 484

RK3588平台开发系列讲解(系统篇)A/B System的介绍

📢本篇将介绍RK3588平台的A/B System

内核笔记 3319

深度解析RK3588平台开发之系统篇:探讨A/B System的实现与优势

A/B System,又称为双系统或双分区系统,是一种用于实现系统固件更新的技术。它通过在设备上同时保留两个系统分区(A和B),使得系统能够在运行时切换到另一个分区,从而实现平滑的固件更新过程。这种设计可以显著减少因固件更新导致的系统中断和风险。通过本文,我们深入研究了A/B System在RK3588平台上的实现与优势。作为现代嵌入式系统的一项关键技术,A/B System通过无缝固件更新、系统回滚能力等特点,极大地提高了系统的可用性和稳定性。希望本文对于正在进行RK3588平台开发的开发者有所启发。

一直在水些技术小文 1292

RK3588平台开发系列:A/B System介绍与Android实现

通过使用A/B System,Android设备可以更安全地进行系统更新,并在更新失败时自动回滚到备份系统,,并在更新失败时自动回滚到备份系统,保证用户的使用体验。如果更新后的系统运行正常,A/B System会将下一次的启动引导到更新后的系统。A/B System是一种用于系统更新和回滚的机制,它允许Android设备在进行系统更新时保留一个完整的备份系统。当进行系统更新时,更新包会被下载并验证,然后被应用到未使用的Slot中(如果当前使用的是Slot A,则更新会应用到Slot B中)。

2301_79330513的博客 523

RK 系统安全(System-Verity / System-Encryption)原理与落地实战

摘要:本文详细解析了Rockchip Linux SDK中的系统安全方案,重点探讨System-Verity和System-Encryption的实现原理与工程实践。System-Verity通过dm-verity确保rootfs完整性,System-Encryption通过dm-crypt实现数据保密性。文章从概念定位、架构设计到具体实现,完整阐述了PC侧镜像处理(生成Hash-Map/加密容器)和Ramdisk中/init脚本的校验解密流程,最终通过vroot映射和switch_root完成安全系统切换

Interview_TC的博客 1191

RK3568平台开发系列讲解(环境篇)RK3568 SDK 的编译

本 SDK 开发环境是在 Ubuntu 系统上开发测试。我们推荐使用 Ubuntu 18.04 的系统进行编译。其他的Linux 版本可能需要对软件包做相应调整。除了系统要求外,还有其他软硬件方面的要求。 硬件要求:64 位系统,硬盘空间大于 40G。如果您进行多个构建,将需要更大的硬盘空间。 软件要求:Ubuntu 18.04 系统

内核笔记 5993

RK3568平台开发系列:深入理解Linux文件系统和Android

本文对RK3568平台开发中的Linux文件系统和Android进行了介绍,并提供了相关的源代码示例。Linux文件系统是Linux操作系统中用于组织和管理文件的机制,同时Android文件系统是在Linux文件系统基础上添加了一些特定的目录和文件。您可以使用Linux命令来操作文件系统,如列出目录内容、创建目录、复制文件、移动文件、删除文件和修改文件权限等。和Android有所帮助。Android操作系统是基于Linux内核的移动操作系统,它在Linux文件系统的基础上添加了一些特定的目录和文件。

. 395

Linux下处理RK平台SecureBoot签名失败的工具指南

本文还有配套的精品资源,点击获取 简介:在Linux系统中,当使用RK(Rockchip)平台的设备时,可能会遇到因system分区过大导致SecureBoot签名失败的问题,影响设备安全启动。为解决这一问题,本文介绍了使用"SecureBootConsole_v1.89"工具来调整分区大小、修复签名以及管理证书等方法。这些步骤涉及依赖库安装、设备连接、Bootloader...

weixin_42327217的博客 1397

避开这些坑!baostock获取股票数据时最容易犯的5个错误(Python实战)

本文针对使用Python和baostock库获取股票历史数据时常见的五大陷阱,提供了实战解决方案。重点剖析了登录状态验证、参数配置、数据解析、批量操作效率及数据一致性校验等关键环节,帮助开发者构建稳健高效的数据获取流程,避免因细节疏忽导致的数据错误或性能瓶颈。

websocket5live的博客 1421

【遥感数字图像处理(朱文泉)】各章博文链接汇总及思维导图

遥感数字图像处理(北京师范大学朱文泉教授)课程各章博文笔记汇总,及各章节思维导图

甜子yu的博客 2609

反无人机作战体系全解析:从低慢小探测到分层拦截

随着小型无人机在军事和民用领域的广泛使用,低慢小目标探测与拦截成为低空安全的核心挑战。传统防空体系面对成本低廉、飞行高度低、雷达特征小的无人机集群时,暴露出探测难、识别难、处置成本失衡等问题。为应对威胁,反无人机体系采用分层闭环设计,融合雷达、光电、声学与无线电侦测实现多源感知,通过电子战软杀伤与导弹、高炮、激光等硬杀伤手段协同配合,并借助自动化指控系统缩短“传感器到射手”的响应时延。该体系既可支撑战场要地防护,也能为民用低空安防提供参考。围绕分层反制逻辑,梳理探测、软硬杀伤、指控布防及实战短板,提供理解反

weixin_42533120的博客 324

深入解析AndroidManifest.xml与device_admin.xml:打造完美DeviceOwner应用配置

本文深入解析了Android企业级开发中DeviceOwner应用的核心配置文件AndroidManifest.xml与device_admin.xml。详细阐述了如何精准声明DeviceAdminReceiver、定义管理策略,并提供了通过ADB命令进行设置与验证的实战指南,帮助开发者构建权限完整、配置正确的设备所有者应用。

ice55的博客 677

Windows下Fortran调用CGNS库的完整踩坑实录:从HDF5、CMake到VS2019+IVF2020的保姆级配置

本文详细记录了在Windows环境下使用Fortran调用CGNS库的完整配置过程,涵盖HDF5安装、CMake配置、VS2019与IVF2020集成等关键步骤。通过实战经验分享,帮助开发者解决常见编译错误和链接问题,实现高效的Fortran与CGNS库集成。

weixin_28707739的博客 346

TensorRT(C++)部署 Pytorch模型

众所周知,python训练pytorch模型得到.pt模型。但在实际项目应用中,特别是嵌入式端部署时,受限于语言、硬件算力等因素,往往需要优化部署,而tensorRT是最常用的一种方式。本文以yolov5的部署为例,说明模型部署在x86架构上的电脑端的流程。(部署在Arm架构的嵌入式端的流程类似)。

女神sha手的博客 5396

目标检测YOLO实战应用案例100讲-【目标检测】缺陷检测(二)

在工业生产中总是经常遇到裂痕、划痕等产品的表面缺陷问题,机器视觉行业对于表面检测相比前几年已经有很大的突破,对于产品表面的划伤、污迹等检测已经不再是难点。在金属、玻璃、手机屏幕、液晶板等行业表面检测上应用广泛。但由于该类缺陷形状不规则、深浅对比度低,而且往往会被产品表面的自然纹理或图案所干扰。因此,表面划痕缺陷检测对于正确打光、相机分辨率、被检测部件与工业相机的相对位置、复杂的机器视觉算法等要求非常高。

qq_36130719的博客 725

Android NDK/JNI面试题大全及参考答案(3万字长文)

是一套工具集合,它允许开发者为Android平台编写原生应用程序或者应用程序的部分模块。NDK 主要用于开发那些需要高性能计算的应用程序,例如游戏引擎、图像处理软件或音频/视频编码解码器等。通过使用 C 或 C++ 编写代码,开发者可以利用硬件加速功能,提高应用性能。NDK 提供了一系列工具来帮助开发者完成从源代码到可执行文件的整个过程,包括编译、链接、调试等功能。

大模型大数据攻城狮的专栏 1246

Statistics and Machine Learning Toolbox

Statistics and Machine Learning Toolbox(带书签),MATLAB统计学习工具

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

jre9下载 jdk9

(Java SE Runtime Environment 9.0) 9.0u175 官方最新版 【x86|x64】

复分析 阿尔福斯(Ahlfors) 第三版答案 英文

答案分为十章,有部分习题没有答案,全英文复分析阿尔福斯(Ahlfors) 第三版答案

上一篇: RK356x U-Boot研究所(开发篇)5.2 A/B系统的使用
下一篇: [RK-Linux] updateEngine工具使用以及代码分析
嵌入式逍遥
嵌入式逍遥 领域专家: 嵌入式与硬件开发技术领域 领域专家: 嵌入式与硬件开发技术领域
博客等级 码龄9年 7万+粉丝 237原创
评论 2
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

嵌入式逍遥

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值