2007-07-28 14:38:25 +00:00
|
|
|
/***************************************************************************
|
|
|
|
* __________ __ ___.
|
|
|
|
* Open \______ \ ____ ____ | | _\_ |__ _______ ___
|
|
|
|
* Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
|
|
|
|
* Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
|
|
|
|
* Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
|
|
|
|
* \/ \/ \/ \/ \/
|
|
|
|
* Module: rbutil
|
|
|
|
* File: irivertools.h
|
|
|
|
*
|
|
|
|
* Copyright (C) 2007 Dominik Wenger
|
|
|
|
*
|
2008-06-28 18:10:04 +00:00
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
2007-07-28 14:38:25 +00:00
|
|
|
*
|
|
|
|
* This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
|
|
|
|
* KIND, either express or implied.
|
|
|
|
*
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
#ifndef IRIVERTOOLS_H_INCLUDED
|
|
|
|
#define IRIVERTOOLS_H_INCLUDED
|
|
|
|
|
2008-02-10 18:25:49 +00:00
|
|
|
#include <QtCore>
|
2007-07-28 14:38:25 +00:00
|
|
|
|
|
|
|
#include "md5sum.h"
|
|
|
|
|
|
|
|
#define ESTF_SIZE 32
|
|
|
|
|
|
|
|
struct sumpairs {
|
2007-09-15 22:37:02 +00:00
|
|
|
const char *unpatched;
|
|
|
|
const char *patched;
|
2007-07-28 14:38:25 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
enum striptype
|
|
|
|
{
|
2008-05-23 19:05:20 +00:00
|
|
|
STRIP_NONE,
|
|
|
|
STRIP_HEADER_CHECKSUM,
|
|
|
|
STRIP_HEADER_CHECKSUM_ESTF
|
2007-07-28 14:38:25 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
/* protos for iriver.c */
|
|
|
|
|
|
|
|
int intable(char *md5, struct sumpairs *table, int len);
|
|
|
|
|
2008-05-23 19:05:20 +00:00
|
|
|
int mkboot(QString infile, QString outfile,QString bootloader,int origin);
|
2007-07-28 14:38:25 +00:00
|
|
|
int iriver_decode(QString infile_name, QString outfile_name, unsigned int modify,
|
2008-05-23 19:05:20 +00:00
|
|
|
enum striptype stripmode);
|
|
|
|
int iriver_encode(QString infile_name, QString outfile_name, unsigned int modify);
|
2007-07-28 14:38:25 +00:00
|
|
|
|
|
|
|
#endif // IRIVERTOOLS_H_INCLUDED
|