|
|||||||||||
Technical Support Support Resources
Product Information |
µVISION DEBUGGER: Error 65: Access ViolationSYMPTOMSWhen trying to write to a variable or memory location, the Keil µVision Debugger issues an Error 65 message: *** Error 65: Access violation at 0x00000004 I have specified this memory area in the Target options, but I still receive this error. Other versions of the error could be:
BACKGROUNDWhen the µVision Debugger loads an executable program, the µVision Simulator uses the loaded program and data segments to create a memory map:
While executing, the debugger checks that memory accesses are only made to objects that are defined in the program, i.e., the debugger by default only allows memory accesses to valid data objects. For any access that is outside of a defined C object, the µVision debugger generates an error message. Usually, there is a programming error when you try to access unexpected locations. For example:
Note: If debugging on a target, Access Violation could mean a bus issue, device lockup, or memory remap is preventing the debugger from reaching the memory. RESOLUTIONIf the error is memory region that should be accessed, update the memory map the simulator uses. Define all the memory ranges that your program is permitted to access. Ensure each memory range has the proper permissions (read, write, execute) that match the memory of the actual hardware. Use the Memory Map Dialog
Use the MAP Command in the Command Window
MAP C:0xF800, C:0xF8FF READ WRITE // allow R/W access to IO space Note: For 8051 devices, the address may need a prefix, e.g., a memory specifier in the table on this page. For example, In the Memory Map dialog C:0xF800 refers to Code address 0xF800. Use a Debug Initialization FileAny memory map changes could be lost during the next debug session. Once you find the correct memory put the required MAP commands into a debugger INI file.
MAP 0x40000000, 0x4000003F READ WRITE EXEC // allow code execution for interrupt vector fetch This should resolve the error. MORE INFORMATION
SEE ALSO
Last Reviewed: Monday, February 8, 2021 | ||||||||||
|
Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.