Avoid crashes when x/y/z are absent or nested under accel/data keys. Co-authored-by: Cursor <cursoragent@cursor.com>