From: Jan Michel Date: Wed, 17 Oct 2018 14:00:46 +0000 (+0200) Subject: add trb5sc to trbflash X-Git-Url: https://jspc29.x-matter.uni-frankfurt.de/git/?a=commitdiff_plain;h=1d817f19eb26e14e76176baf41de3fb4bff7000b;p=trbnettools.git add trb5sc to trbflash --- diff --git a/libtrbnet/trbflash.c b/libtrbnet/trbflash.c index 6809439..9b7697a 100644 --- a/libtrbnet/trbflash.c +++ b/libtrbnet/trbflash.c @@ -94,7 +94,8 @@ typedef enum CBM_TOF_1 = 20, FLASH_TRB3SC = 21, FLASH_DIRICH = 22, - FLASH_DIRICH_CONCENTRATOR = 23 + FLASH_DIRICH_CONCENTRATOR = 23, + FLASH_TRB5SC = 24 } FlashType; @@ -122,7 +123,8 @@ static const char FlashTypeStr[][32] = { "CBM TOF V1", "TRB3sc", "Dirich", - "DirichConcentrator" + "DirichConcentrator", + "Trb5sc" }; typedef struct { @@ -369,6 +371,13 @@ static int setFlashParam(FlashParam* flashParam, uint16_t hardwareId) flashParam->numPages = 32768; break; + case 0xa500: + flashParam->flashType = FLASH_TRB5SC; + flashParam->manId = 0x1720c2; + strcpy(flashParam->allowedStringId[0], "trb5sc"); + flashParam->numPages = 32768; + break; + default: return -1; } @@ -1796,7 +1805,7 @@ int main(int argc, char** argv) } for (i = 0; i < status; i++) { - char text[32] = ""; + char text[33] = ""; char cc[2] = " \0"; int c; fprintf(stdout, "\nEndPoint: 0x%04x Page #%d\n",