An error and warning were output after an attempt to read the data in the address 0:0000h of flash memory. What should I do to avoid this situation? Output error and warning: Warning 37 : ROMWINDOW/NOROMWIN is not specifiedError 29 : out of range : memory not exist at the address l er0, 0000h
To perform direct addressing on the ROM window, define the ROM window area. When the ROM window area is not specified explicitly in a program, performing direct addressing on the area other than RAM will cause RASU8 assembler to output an error. The ROM window area varies by product. Specify the end address of the ROM window area specified in the program memory space in User’s Manual.
● When the script is written in C: #pragma romwin 0x0 0xdfff // <- Add this description. // * 0x0 0xdfff varies by product. unsigned short v0000h; // v0000h indicates a variable name. void main() { v0000h = *(unsigned short*)0x0000; // Read data of the address 0. }
● When the script is written in the assembly language: romwindow 0, 0dfffh ;; <- Add this description. ;; * 0 and 0dfffh vary by product. cseg at 1000h l er0, 0000h ;; Read data of the address 0.