当前位置:网站首页>Secondary bootloader about boot28 Precautions for ASM application, 28035
Secondary bootloader about boot28 Precautions for ASM application, 28035
2022-06-26 05:13:00 【Quantum mechanics and Life Science】
do BL When , The main function has been changed to BLmian()
boot28.asm in LCR _SBLmain, In this way, the main function is called with a return , After this sentence runs ,SBLmain The return value of the function is APP The entry address of is placed in ACC in , adopt LCR _exit call , In the end ACC The main function entry address in is loaded into PC in
therefore , _exit The contents of the function are added to boot28.asm in , Otherwise, it is quoted _exit Is in the library , There is no such process , You can't complete the jump
Add to boot28.asm The code in is as follows :
_exit:
;-----------------------------------------------
; Insure that the stack is deallocated
;-----------------------------------------------
MOV SP,#__stack
;-----------------------------------------------
; Clear the bottom of the stack. This will endup
; in RPC when we are finished
;-----------------------------------------------
MOV *SP++,#0
MOV *SP++,#0
;-----------------------------------------------
; Load RPC with the entry point as determined
; by the boot mode. This address will be returned
; in the ACC register.
;-----------------------------------------------
PUSH ACC
POP RPC
;-----------------------------------------------
; Put registers back in their reset state.
;
; Clear all the XARn, ACC, XT, and P and DP
; registers
;
; NOTE: Leave the device in C28x operating mode
; (OBJMODE = 1, AMODE = 0)
;-----------------------------------------------
ZAPA
MOVL XT,ACC
MOVZ AR0,AL
MOVZ AR1,AL
MOVZ AR2,AL
MOVZ AR3,AL
MOVZ AR4,AL
MOVZ AR5,AL
MOVZ AR6,AL
MOVZ AR7,AL
MOVW DP, #0
;------------------------------------------------
; Restore ST0 and ST1. Note OBJMODE is
; the only bit not restored to its reset state.
; OBJMODE is left set for C28x object operating
; mode.
;
; ST0 = 0x0000 ST1 = 0x0A0B
; 15:10 OVC = 0 15:13 ARP = 0
; 9: 7 PM = 0 12 XF = 0
; 6 V = 0 11 M0M1MAP = 1
; 5 N = 0 10 reserved
; 4 Z = 0 9 OBJMODE = 1
; 3 C = 0 8 AMODE = 0
; 2 TC = 0 7 IDLESTAT = 0
; 1 OVM = 0 6 EALLOW = 0
; 0 SXM = 0 5 LOOP = 0
; 4 SPA = 0
; 3 VMAP = 1
; 2 PAGE0 = 0
; 1 DBGM = 1
; 0 INTM = 1
;-----------------------------------------------
MOV *SP++,#0
MOV *SP++,#0x0A0B
POP ST1
POP ST0
;------------------------------------------------
; Jump to the EntryAddr as defined by the
; boot mode selected and continue execution
;-----------------------------------------------
LRETR
边栏推荐
- 6.1 - 6.2 公钥密码学简介
- 微服务之间的Token传递之一@Feign的token传递
- [unity3d] rigid body component
- Introduction to classification data cotegory and properties and methods of common APIs
- UWB超高精度定位系统原理图
- 2. < tag dynamic programming and conventional problems > lt.343 integer partition
- localStorage浏览器本地储存,解决游客不登录的情况下限制提交表单次数。
- Computer Vision Tools Chain
- Why do many Shopify independent station sellers use chat robots? Read industry secrets in one minute!
- Sentimentin tensorflow_ analysis_ cell
猜你喜欢
The localstorage browser stores locally to limit the number of forms submitted when tourists do not log in.
The beautiful scenery is natural, and the wonderful pen is obtained by chance -- how is the "wonderful pen" refined?
Decipher the AI black technology behind sports: figure skating action recognition, multi-mode video classification and wonderful clip editing
Codeforces Round #800 (Div. 2)
Illustration of ONEFLOW's learning rate adjustment strategy
Final review of brain and cognitive science
cartographer_pose_graph_2d
递归遍历目录结构和树状展现
Yolov5 super parameter setting and data enhancement analysis
6.1 - 6.2 introduction to public key cryptography
随机推荐
Procedural life
RESNET in tensorflow_ Train actual combat
The first gift of the project, the flying oar contract!
First day of deep learning and tensorflow learning
pycharm 导包错误没有警告
Zuul implements dynamic routing
递归遍历目录结构和树状展现
CMakeLists.txt Template
Machine learning final exercises
How MySQL deletes all redundant duplicate data
广和通联合安提国际为基于英伟达 Jetson Xavier NX的AI边缘计算平台带来5G R16强大性能
[IDE(ImageBed)]Picgo+Typora+aliyunOSS部署博客图床(2022.6)
红队得分方法统计
Computer Vision Tools Chain
FastAdmin Apache下设置伪静态
Sentimentin tensorflow_ analysis_ layer
Vie procédurale
Replacing domestic image sources in openwrt for soft routing (take Alibaba cloud as an example)
cartographer_pose_graph_2d
Douban top250