Wikia

CHDK Wiki

DryOS structures

Talk0
577pages on
this wiki
Revision as of 03:42, May 23, 2009 by Autopilot (Talk | contribs)

Tasks and contexts

struct context
{
       uint32_t                cpsr;
       uint32_t                r[13];
       uint32_t                lr;
       uint32_t                pc;
};

struct task
{
       uint32_t                off_0x00;       // always 0?
       uint32_t                off_0x04;       // stack maybe?
       uint32_t                off_0x08;       // flags?
       void *                  entry;          // off 0x0c
       uint32_t                off_0x10;
       uint32_t                off_0x14;
       uint32_t                off_0x18;
       uint32_t                off_0x1c;
       uint32_t                off_0x20;
       char *                  name;           // off_0x24;
       uint32_t                off_0x28;
       uint32_t                off_0x2c;
       uint32_t                off_0x30;
       uint32_t                off_0x34;
       uint32_t                off_0x38;
       uint32_t                off_0x3c;
       uint32_t                off_0x40;
       uint32_t                off_0x44;
       uint32_t                off_0x48;
       struct context *        context;        // off 0x4C
       uint32_t                pad_1[12];
};

VRAM

The VRAM can be read as sequence of 8-bit pixels:

        uint32_t * const vram_config_ptr = (void*) 0x2580;
        uint32_t width = vram_config_ptr[ 0x28 / 4 ];

        uint32_t * const bmp_vram_ptr = (void*) 0x240cc;
        uint8_t * const bmp_vram = (void*) bmp_vram_ptr[ 2 ];

The width config will be 1080 if the output device is HDMI or 720 if it on the internal screen. The bmp_vram pointer might be NULL and always has a pitch of 960 pixels, even in 720 mode.

State objects

Structures like the movie recorder use state objects to track their state. It appears to work like a finite-state-machine, with a set of transitions. The actual mechanism of how they work has not yet been determined, but the structure has been mapped based on the state_object_create() function.

typedef void (*state_function_t)( void * arg );
struct state_object
{
       const char *            type;           // off 0x00, "StateObject"
       const char *            name;           // off 0x04, arg 0
       uint32_t                id;             // off 0x08, arg 1
       // off 0x0c, always 0xff99a228 ?
       void                    (*callback)(
               struct state_object *   obj,
               void *                  unknown1,
               void *                  unknown2
       );
       state_function_t *      callbacks;      // off 0x10
       uint32_t                max_transitions; // off 0x14, arg 2
       uint32_t                max_states;     // off 0x18, arg 3
       uint32_t                state;          // off 0x1c, initially 0
};
extern struct state_object *
state_object_create(
       const char *            name,
       int                     initial,
       state_function_t *      callbacks,
       int                     max_states,
       int                     max_transitions
);

GUI

GUI Event types

  • 0x6 == IDC_DBN_OK
  • 0x7 == IDC_DBN_CANCEL
  • 0x800 == GOT_TOP_OF_CONTROL
  • 0x801 == LOST_TOP_OF_CONTROL
  • 0x802 == INITIALIZE_CONTROLLER
  • 0x804 == TERMINATE_WINSYS
  • 0x805 == DELETE_DIALOG_REQUEST
  • 0x807 == PRESS_RIGHT_BUTTON
  • 0x809 == PRESS_LEFT_BUTTON
  • 0x80B == PRESS_UP_BUTTON
  • 0x80D == PRSES_DOWN_BUTTON
  • 0x80F == PRESS_MENU_BUTTON
  • 0x812 == PRESS_SET_BUTTON (maybe)
  • 0x81B == PRESS_UP_BUTTON
  • 0x820 == SUB_DIAL (spin left)
  • 0x823 == PRESS_MLT_CENTER_BUTTON
  • 0x829 == PRESS_INFO_BUTTON
  • 0x82B == ELECTRONIC_SUB_DIAL_RIGHT
  • 0x82C == ELECTRONIC_SUB_DIAL_LEFT
  •  ? == SUB_DIAL (spin right)
  • 0x10000000 == PRESS_DISP_BUTTON
  • 0x10000005 == PRESS_DIRECT_PRINT_BUTTON
  • 0x10000007 == PRESS_FUNC_BUTTON
  • 0x10000009 == PRESS_PICTURE_STYLE_BUTTON
  • 0x1000000B == OPEN_SLOT_COVER
  • 0x1000000C == CLOSE_SLOT_COVER
  • 0x1000008A == START_SHOOT_MOVIE

Property list

Properties look like events, I think. They have a unique numeric ID in the 0x80000000 space.

  • PROP_ABORT
  • PROP_ACCESS_REMAIN
  • PROP_ACTIVE_SWEEP_ACTIVATE_CONDITION
  • PROP_ACTIVE_SWEEP_MODE
  • PROP_ACTIVE_SWEEP_STATUS
  • PROP_AEB
  • PROP_AE_MODE
  • PROP_AE_MODE_DIAL
  • PROP_AF_MODE
  • PROP_AFPOINT
  • PROP_ARTIST
  • PROP_AUTO_POWEROFF_TIME
  • PROP_AUTO_ROTATE
  • PROP_AVAIL_SHOT
  • PROP_BATTERY_CHECK
  • PROP_BATTERY_HISTORY
  • PROP_BATTERY_POWER
  • PROP_BATTERY_REPORT
  • PROP_BEEP
  • PROP_BODY_ID
  • PROP_CARD
  • PROP_CARD1_CLUSTER_SIZE
  • PROP_CARD1_EXIST
  • PROP_CARD1_FILE_NUMBER
  • PROP_CARD1_FOLDER_NUMBER
  • PROP_CARD1_FREE_SIZE
  • PROP_CARD1_IMAGE_COMPOSITION
  • PROP_CARD1_NEXT_FOLDER_NUMBER
  • PROP_CARD1_RECORD
  • PROP_CARD1_STATUS
  • PROP_CARD2_CLUSTER_SIZE
  • PROP_CARD2_EXIST
  • PROP_CARD2_FILE_NUMBER
  • PROP_CARD2_FOLDER_NUMBER
  • PROP_CARD2_FREE_SIZE
  • PROP_CARD2_IMAGE_COMPOSITION
  • PROP_CARD2_NEXT_FOLDER_NUMBER
  • PROP_CARD2_RECORD
  • PROP_CARD2_STATUS
  • PROP_CARD3_CLUSTER_SIZE
  • PROP_CARD3_EXIST
  • PROP_CARD3_FILE_NUMBER
  • PROP_CARD3_FOLDER_NUMBER
  • PROP_CARD3_FREE_SIZE
  • PROP_CARD3_IMAGE_COMPOSITION
  • PROP_CARD3_NEXT_FOLDER_NUMBER
  • PROP_CARD3_RECORD
  • PROP_CARD3_STATUS
  • PROP_CARD_COVER
  • PROP_CARD_EXTENSION
  • PROP_CARD_IMAGE_QUALITY
  • PROP_CFN_TAB1
  • PROP_CFN_TAB2
  • PROP_CFN_TAB3
  • PROP_CFN_TAB4
  • PROP_COLOR_SPACE
  • PROP_COLOR_TEMP
  • PROP_COMP
  • PROP_CONNECT_TARGET
  • PROP_CONNECT_TARGET_WFT
  • PROP_COPYRIGHT
  • PROP_CURRENT_LENS_NAME
  • PROP_CURRENT_MEDIA
  • PROP_CUSTOM_WB
  • PROP_DATA_INPUT_TRANSMISSION
  • PROP_DATE_DISPLAY_FORMAT
  • PROP_DEFAULT_OBWBREG
  • PROP_DIR_SUFFIX
  • PROP_DISABLE_PLAY_IMAGE
  • PROP_DISPLAY_AF_POINTS
  • PROP_DISPLAY_OFF_SENSOR
  • PROP_DISPSENSOR_CTRL
  • PROP_DL_ACTION
  • PROP_DL_SYMPATHETIC_VIBRATION
  • PROP_DP_DPOF_PARAM
  • PROP_DP_EXT_OPTION_PARAM
  • PROP_DP_STANDARD_PARAM
  • PROP_DRIVE_MODE
  • PROP_DSDEFINE
  • PROP_DUST_DELETE_DATA
  • PROP_EFIC_TEMP
  • PROP_ELECTRIC_SHUTTER_MODE
  • PROP_ERROR_FOR_DISPLAY
  • PROP_EVF_RECODE_STATUS
  • PROP_FILE_NUMBERING_MODE
  • PROP_FILE_PREFIX
  • PROP_FIRM_VERSION
  • PROP_FIXED_VERSION
  • PROP_FLAVOR_BW
  • PROP_FLAVOR_FAITHFUL
  • PROP_FLAVOR_LANDSCAPE
  • PROP_FLAVOR_MODE
  • PROP_FLAVOR_NEUTRAL
  • PROP_FLAVOR_PORTRAIT
  • PROP_FLAVOR_STANDARD
  • PROP_FLAVOR_USER1
  • PROP_FLAVOR_USER2
  • PROP_FLAVOR_USER3
  • PROP_FOCUS_INFO_EX
  • PROP_GetCameraSettingProperty
  • PROP_GPS_STATUS
  • PROP_GUIGROUND_STATE
  • PROP_GUI_STATE
  • PROP_HDD_DCIM_PATH
  • PROP_HDMI_PHYSICAL_CONNECT
  • PROP_HDMI_PHYSICAL_DISCONNECT
  • PROP_HIGHLIGHT_ALERT
  • PROP_HISTOGRAM
  • PROP_ICU_AUTO_POWEROFF
  • PROP_ICU_UILOCK
  • PROP_INFO_BUTTON_SHOOT
  • PROP_Initialize
  • PROP_JUMP_FUNCTION
  • PROP_LANGUAGE
  • PROP_LAST_JOBID
  • PROP_LAST_JOB_STATE
  • PROP_LCD_BRIGHTNESS
  • PROP_LCD_BRIGHTNESS_ADJ
  • PROP_LCD_STATE
  • PROP_LENS
  • PROP_LIGHT_FALLOFF_COMP
  • PROP_LIVE_VIEW_AF_SYSTEM
  • PROP_LIVE_VIEW_FACE_AF
  • PROP_LIVE_VIEW_GRID
  • PROP_LIVE_VIEW_MOVIE_SELECT
  • PROP_LIVE_VIEW_VIEWTYPE_SELECT
  • PROP_LOGICAL_CONNECT
  • PROP_LOGICAL_CONNECT_WFT
  • PROP_LV_ACTION
  • PROP_LV_AF_RESULT
  • PROP_LV_AVAILABLE_AREA
  • PROP_LV_DISPBUSY
  • PROP_LV_DISPSIZE
  • PROP_LV_EMD_DRIVE_RESULT
  • PROP_LV_EXPOSURE_MODE 0x80050038
  • PROP_LV_HISTOGRAM 0x80050013
  • PROP_LV_IMAGE_MUTE
  • PROP_LV_LENS
  • PROP_LV_LOCK
  • PROP_LV_MANIPULATION
  • PROP_LV_OUTPUT_DEVICE
  • PROP_LV_SPDN_BTN_STATUS
  • PROP_LV_START
  • PROP_LV_ST_CHARGE_INFO
  • PROP_LV_STOP
  • PROP_LV_TEST_REMOTE_RELEASE
  • PROP_LV_ZOOM_FOCUS_FRAME_AREA
  • PROP_MAX_DESC_BUFFER
  • PROP_MAX_ENUM_NUMBER
  • PROP_MENU_POSITION
  • PROP_METERING_MODE
  • PROP_METERING_TIMER_FOR_LV
  • PROP_MOVIE_SIZE
  • PROP_MOVIE_SOUND_RECORD
  • PROP_MPU_INDEPENDENT_SETTING
  • PROP_MWB
  • PROP_MWB1
  • PROP_MYMENU_LIST
  • PROP_NO_CARD_RELEASE
  • PROP_NUMBER_OF_CONTINUOUS_MODE
  • PROP_OPTICAL_CORRECT_PARAM
  • PROP_OUTPUT_TYPE
  • PROP_PC_AVAIL_SHOT
  • PROP_PC_FLAVOR1_PARAM
  • PROP_PC_FLAVOR2_PARAM
  • PROP_PC_FLAVOR3_PARAM
  • PROP_PC_FREE_SIZE
  • PROP_PC_HDD_STATUS
  • PROP_PC_WB1
  • PROP_PC_WB2
  • PROP_PC_WB3
  • PROP_PC_WB4
  • PROP_PC_WB5
  • PROP_PERMIT_ICU_EVENT
  • PROP_PHOTO_STUDIO_ENABLE_ISOCOMP
  • PROP_PHOTO_STUDIO_ISOCOMP
  • PROP_PHOTO_STUDIO_MODE
  • PROP_PHOTO_STUDIO_MODE_CHANGE_AUTO_PASSWORD_KEY
  • PROP_PHOTO_STUDIO_MODE_CHANGE_MANUAL_PASSWORD
  • PROP_PHOTO_STUDIO_SETUP_PASSWORD
  • PROP_PHYSICAL_CONNECT
  • PROP_PROGRAM_SHIFT
  • PROP_QUICKREVIEW
  • PROP_QUICKREVIEW_MODE
  • PROP_REGISTER_HEAD
  • PROP_REMOTE_AFSTART_BUTTON
  • PROP_REMOTE_BULB_RELEASE_END
  • PROP_REMOTE_BULB_RELEASE_START
  • PROP_REMOTE_RELEASE
  • PROP_REMOTE_SW1
  • PROP_REMOTE_SW2
  • PROP_Request
  • PROP_RequestChange
  • PROP_SAVE_MODE
  • PROP_SaveMpuDebugData
  • PROP_SCREEN_SAVER
  • PROP_SDIO_PHYSICAL_CONNECT
  • PROP_SDIO_PHYSICAL_CONNECT_START
  • PROP_SELECTED_FILE_PREFIX
  • PROP_SetCameraSettingProperty
  • PROP_SHOOTING_TYPE
  • PROP_SHUTTER_COUNTER
  • PROP_SLIDESHOW
  • PROP_SPECIAL_OPTION
  • PROP_STARTUP_CONDITION
  • PROP_STROBO_CFN
  • PROP_STROBO_FIRING
  • PROP_STROBO_SETTING
  • PROP_STROBO_WIRELESS_SETTING
  • PROP_TEMP_STATUS
  • PROP_TFT_SETTING_PARAM
  • PROP_TFT_STATUS
  • PROP_TRANS_METHOD_WFT
  • PROP_TUNING_FLAG
  • PROP_USBDEVICE_CONNECT
  • PROP_USER_FILE_PREFIX
  • PROP_USER_FILE_PREFIX2
  • PROP_VIDEO_PHYSICAL_CONNECT
  • PROP_VIDEO_SYSTEM
  • PROP_WBB_BA
  • PROP_WBB_GM
  • PROP_WB_MODE
  • PROP_WBS_BA
  • PROP_WBS_GM
  • PROP_WFT_ADAPTERINFO
  • PROP_WFT_CAPTION
  • PROP_WFT_DELIMITER_STATUS
  • PROP_WFT_DONGLE
  • PROP_WFT_FTP
  • PROP_WFT_HOSTINFO
  • PROP_WFT_HTTP
  • PROP_WFT_IMAGE_TRANS
  • PROP_WFT_LOCK
  • PROP_WFT_SYSTEM
  • PROP_WFT_TCPIP
  • PROP_WFT_TRANSMISSION
  • PROP_WFT_WIRED
  • PROP_WFT_WIRELESS
  • PROP_WIZARD_WFT

Around Wikia's network

Random Wiki