We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
I HAVE THIS CODE AND NEED TO SAY WHAT IS WRONG
HELP ME PLZ
LD R0,#>RAMSAVE LD R1,#<RAMSAVE LDE R2,@RR0 LD SV0_RAM,R2 INCW RR0 LDE R2,@RR0 LD SV1_RAM,R2 INCW RR0 LDE R2,@RR0 LD TX_RAM,R2 JP LL9
I still think the code is Zilog Z8.
One thing's for sure - It is certainly not native 8051.
Someone might have gone crazy with some macros to make 8051 code look like something else; but it's pretty unlikely.
It's a fair bet that the code you gave does not add numbers.
What I think it does is copy a pointer from RAMSAVE to SVx_RAM.
What sort of project is this?
Looks like a homework assignment to me!
The ARM Architecture Reference Manual does not have an INCW, JP, or LDE instruction.
I think it's the instruction set for the HAL 9xxx series. It's the code for a pretty famous bug. You see it starts with two copies of objectives in R0 and R1, but confuses the real objectives (R0) with the ones known only to the crew (R1), which causes the code to corrupt the Recognize Rights of Others (RRO) register, leading to the results with which we're all familiar.