def METHOD_NAME(addr, digit, mask):
    command_line = ["devmem", "0x%02x"%addr, str(digit)]
    retrytime = 6
    ret_t = ""
    for i in range(retrytime):
        ret, ret_t = osutil.command(command_line)
        if ret == 0:
            if mask != None:
                ret_t = str(int(ret_t, 16) & mask)
        return True, ret_t
    return False, ret_t