root/platform/g12/sub/filewrite_hdr.c

/* [<][>][^][v][top][bottom][index][help] */
   1 #include "lolevel.h"
   2 #include "platform.h"
   3 
   4 typedef struct {
   5     unsigned int address;
   6     unsigned int length;
   7 } cam_ptp_data_chunk; //camera specific structure
   8 
   9 // Found in sub_FFAE0EFC (1.00c) --> "CMP     R0, #6"
  10 #define MAX_CHUNKS_FOR_FWT 7   // filewritetask is prepared for this many chunks
  11 /*
  12  * fwt_data_struct: defined here as it's camera dependent
  13  * unneeded members are designated with unkn
  14  * pdc is required, everything after that is optional (DryOS < R50)
  15  * file_offset, full_size, seek_flag only needs to be defined for DryOS>=r50 generation cameras
  16  */
  17 typedef struct
  18 {
  19     int unkn1[5];                                   // sub_FFAE0EFC --> "LDR     R7, [R0, #0x14]!"
  20     cam_ptp_data_chunk pdc[MAX_CHUNKS_FOR_FWT];
  21     int unkn2;
  22     char name[32];                                  // sub_FFAE0DBC --> "ADD     R0, R0, #0x50"
  23                                                     // offset of 'name' from start = 0x50 = 80 bytes = 20 words
  24 } fwt_data_struct;
  25 
  26 #include "../../../generic/filewrite.c"

/* [<][>][^][v][top][bottom][index][help] */