diff options
author | Jörg Hohensohn <hohensoh@rockbox.org> | 2004-01-02 07:48:02 +0000 |
---|---|---|
committer | Jörg Hohensohn <hohensoh@rockbox.org> | 2004-01-02 07:48:02 +0000 |
commit | 0aad3753637220d960fcedebcc9ac2cdc1aa507e (patch) | |
tree | 5b9a54039fd659540af87f5b9cf5678b0efd68a1 | |
parent | 924972c743b85dda7d86c52f6c2397dc78464bf5 (diff) | |
download | rockbox-0aad3753637220d960fcedebcc9ac2cdc1aa507e.tar.gz rockbox-0aad3753637220d960fcedebcc9ac2cdc1aa507e.zip |
checks relaxed again, to tolerate firmware 1.15-1.29 for recorders
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@4186 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r-- | apps/plugins/firmware_flash.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/apps/plugins/firmware_flash.c b/apps/plugins/firmware_flash.c index d16a847bb2..4abd8dd1bd 100644 --- a/apps/plugins/firmware_flash.c +++ b/apps/plugins/firmware_flash.c | |||
@@ -44,11 +44,9 @@ | |||
44 | #define ID_PLAYER 2 | 44 | #define ID_PLAYER 2 |
45 | #define ID_REC_V2 3 | 45 | #define ID_REC_V2 3 |
46 | 46 | ||
47 | /* We should never check for ARCHOS_* defines in source code. We must | 47 | /* Here I have to check for ARCHOS_* defines in source code, which is |
48 | check for features/hardware that have been defined in config-*.h files. | 48 | generally strongly discouraged. But here I'm not checking for a certain |
49 | This makes it easier for us to maintain portability. */ | 49 | feature, I'm checking for the model itself. */ |
50 | #define A_SUPPORTED_PLATFORM 1 | ||
51 | |||
52 | #if defined(ARCHOS_PLAYER) | 50 | #if defined(ARCHOS_PLAYER) |
53 | #define FILE_TYPE "player" | 51 | #define FILE_TYPE "player" |
54 | #define KEEP VERSION_ADR /* keep the firmware version */ | 52 | #define KEEP VERSION_ADR /* keep the firmware version */ |
@@ -66,11 +64,10 @@ | |||
66 | #define KEEP MASK_ADR /* keep the mask value */ | 64 | #define KEEP MASK_ADR /* keep the mask value */ |
67 | #define PLATFORM_ID ID_FM | 65 | #define PLATFORM_ID ID_FM |
68 | #else | 66 | #else |
69 | /* this platform is not (yet) flashable */ | 67 | #undef PLATFORM_ID /* this platform is not (yet) flashable */ |
70 | #undef A_SUPPORTED_PLATFORM | ||
71 | #endif | 68 | #endif |
72 | 69 | ||
73 | #ifdef A_SUPPORTED_PLATFORM | 70 | #ifdef PLATFORM_ID |
74 | 71 | ||
75 | /* result of the CheckFirmwareFile() function */ | 72 | /* result of the CheckFirmwareFile() function */ |
76 | typedef enum | 73 | typedef enum |
@@ -286,7 +283,7 @@ bool CheckPlatform(int platform_id, UINT16 version) | |||
286 | { /* it can be a FM or V2 recorder */ | 283 | { /* it can be a FM or V2 recorder */ |
287 | return (platform_id == ID_FM || platform_id == ID_REC_V2); | 284 | return (platform_id == ID_FM || platform_id == ID_REC_V2); |
288 | } | 285 | } |
289 | else if (version >= 118 && version <= 128) | 286 | else if (version >= 115 && version <= 129) |
290 | { /* the range of Recorders seen so far */ | 287 | { /* the range of Recorders seen so far */ |
291 | return (platform_id == ID_RECORDER); | 288 | return (platform_id == ID_RECORDER); |
292 | } | 289 | } |
@@ -1008,5 +1005,5 @@ enum plugin_status plugin_start(struct plugin_api* api, void* parameter) | |||
1008 | return PLUGIN_OK; | 1005 | return PLUGIN_OK; |
1009 | } | 1006 | } |
1010 | 1007 | ||
1011 | #endif /* ifdef A_SUPPORTED_PLATFORM */ | 1008 | #endif /* ifdef PLATFORM_ID */ |
1012 | #endif /* #ifndef SIMULATOR */ | 1009 | #endif /* #ifndef SIMULATOR */ |