def debugger_memory_read_func(self, addr: int) -> HexByteValue:
        """
        Callback to populate hex view with bytes from debugger state.
        """
        if addr not in self._data_cache:
            dbg = self.instance.debugger_mgr.debugger
            if dbg.am_none:
                v = "?"
            else:
                state: angr.SimState | None = dbg.simstate
                if state is None:
                    v = "?"
                else:
                    try:
                        r = state.memory.load(addr, 1)
                        v = "S" if r.symbolic else state.solver.eval(r)
                    except Exception:  # pylint:disable=broad-except
                        log.exception("Failed to read @ %#x", addr)
                        v = "?"
            self._data_cache[addr] = v
        return self._data_cache[addr]

        Callback to populate hex view with bytes from debugger state.
        
angrmanagement/ui/views/hex_view.py