+ /* Do the "null decode" using a one-byte decode array of '\0' */
+ partial_decode(0 , 0x0b14, "", 0, 1, in, size, buf);
+
+ /*
+ * The header scrambling is different form the dive
+ * scrambling. Oh yay!
+ */
+ partial_decode(0x010e, 0x0b14, decode, 0, mod, in, size, buf);
+ partial_decode(0x0b14, 0x1b14, decode, 0, mod, in, size, buf);
+ partial_decode(0x1b14, 0x2b14, decode, 0, mod, in, size, buf);
+ partial_decode(0x2b14, 0x3b14, decode, 0, mod, in, size, buf);
+ partial_decode(0x3b14, 0x5414, decode, 0, mod, in, size, buf);
+ partial_decode(0x5414, size, decode, 0, mod, in, size, buf);
+
+ printf("\n%s, header\n\n", filename);
+ cochran_debug_write(filename, buf, size);
+
+ free(buf);
+}
+
+static void parse_cochran_dive(const char *filename, int dive,
+ const unsigned char *decode, unsigned mod,
+ const unsigned char *in, unsigned size)
+{
+ char *buf = malloc(size);
+#ifdef DON
+ unsigned int offset = 0x4a14;
+#else
+ unsigned int offset = 0x4b14;
+#endif
+