Commit c756f3bb authored by alex@thinkpad's avatar alex@thinkpad
Browse files

QEMU: generic MPU spells compatible with most EOS models (experimental)

--HG--
branch : qemu
parent b75e1342711a
......@@ -46,6 +46,7 @@ static int mpu_init_spell_count = 0;
#include "mpu_spells/100D.h"
#include "mpu_spells/EOSM.h"
#include "mpu_spells/EOSM2.h"
#include "mpu_spells/generic.h"
#include "mpu_spells/known_spells.h"
......@@ -1107,13 +1108,13 @@ void mpu_spells_init(EOSState *s)
if (!mpu_init_spell_count)
{
MPU_EPRINTF("FIXME: no MPU spells for %s.\n", s->model->name);
MPU_EPRINTF("FIXME: using generic MPU spells for %s.\n", s->model->name);
mpu_init_spells = mpu_init_spells_generic;
mpu_init_spell_count = COUNT(mpu_init_spells_generic);
/* how to get them: http://magiclantern.fm/forum/index.php?topic=2864.msg166938#msg166938 */
}
else
{
mpu_check_duplicate_spells(s);
}
mpu_check_duplicate_spells(s);
#define MPU_BUTTON_CODES(cam) \
if (strcmp(s->model->name, #cam) == 0) { \
......
/**
* Minimal generic spell set based on 60D (deleted everything that did not prevent booting)
* Boots many other models (without card support, but menu navigation works).
* Tested on:
* 5D2 5D3 6D 50D 60D 70D
* 450D 500D 550D 600D 650D 700D
* 100D 1000D 1100D 1200D EOSM2
* Not working: EOSM
*/
static struct mpu_init_spell mpu_init_spells_generic[] = {
{ { 0x06, 0x04, 0x02, 0x00, 0x00 }, .description = "Init", .out_spells = { /* spell #1 */
{ 0x2c, 0x2a, 0x02, 0x00, 0x03, 0x03, 0x03, 0x04, 0x03, 0x00, 0x00, 0x48, 0x00, 0x00, 0x00, 0x14, 0x50, 0x00, 0x00, 0x00, 0x00, 0x81, 0x06, 0x00, 0x00, 0x04, 0x06, 0x00, 0x00, 0x04, 0x06, 0x00, 0x00, 0x04, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x4d, 0x4b, 0x01 },/* reply #1.17, Init */
{ 0 } } },
#include "NotifyGUIEvent.h"
#include "UILock.h"
#include "CardFormat.h"
#include "GPS.h"
#include "Shutdown.h"
};
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment