From 6259d7ae38723d8e060494b3acb208de912c0a1f Mon Sep 17 00:00:00 2001 From: hadaq Date: Thu, 10 Sep 2009 19:46:16 +0000 Subject: [PATCH] bugfix in readCtrlReg fixed, was reading statusRegister before --- trbrich/trbflash.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/trbrich/trbflash.c b/trbrich/trbflash.c index 781fe5e..d0ce5d7 100644 --- a/trbrich/trbflash.c +++ b/trbrich/trbflash.c @@ -63,7 +63,7 @@ static const char FlashTypeStr[][16] = {"INVALID", "ADCM1", "ADCM2", "MDC"}; static FlashType flashType = FLASH_INVALID; -static const char trbflash_version[] = "$Revision: 2.05 $"; +static const char trbflash_version[] = "$Revision: 2.06 $"; static uint32_t mdcFlashSelect = 1; @@ -175,7 +175,7 @@ static int readCtrlRegister(uint16_t trb_address, /* Wait until NoMoreData is withdrawn */ do { - if ((status = trb_register_read(trb_address, SetupReg, + if ((status = trb_register_read(trb_address, CtrlReg, trbBuffer, TRB_BUFFER_SIZE)) == -1) { fprintf(logFile, "Error > readCtrlRegister: TRBNet %s\n", trb_strerror(trb_errno)); -- 2.43.0