Hi all,
To write and read a word from memory using program buffer,what is the value of "sw s0 0(s1)”?.This is can be a 32-bit instruction or a compressed instruction in the lower 16 bits accompanied by a compressed nop in the upper 16 bits.I had found that the lower 16 bits is “c080” ,than I need add the nop whose value is “0001” into the upper 16 bits.So the whole value of "sw s0 0(s1) is “0001c080”.However it didn’t work.So I would like to ask for some help here,I don’t know where I’ve made a mistake.
Also,I want to know that the Shift-DR of JTAG TAP is higher bit priority or lower bit priority.
Hello,
If you are just looking for the 32bit opcode for the RV32I instruction sw s0,0(s1)
? If so it is the following:0x0084_A023
.
The opcode for the compressed version of the sw s0,0(s1)
instruction (RV32IC) is as you observed: 0xC080
.
I’m not sure i know what you mean by higher or lower bit priority?
Not quite sure what you are asking, but RISC-V ISA is always little endian. As described in the JTAG Standard, the bits are shifted into DR least-significant-bit first. So in the end the word that you would write to program buffer eg:
0x0084_A023
Should be clocked on TDI in this order:
1 1 0 0 0 1 0 0 ... 0 0 0 1 0 0 0 0 0 0 0 0