diff --git a/dsu3plugin/dsu3plugin.cpp b/dsu3plugin/dsu3plugin.cpp --- a/dsu3plugin/dsu3plugin.cpp +++ b/dsu3plugin/dsu3plugin.cpp @@ -170,6 +170,18 @@ bool dsu3plugin::cacheEnable() return setCacheEnable(true); } +bool dsu3plugin::cacheIsEnable() +{ + if(parent==NULL) + return false; + unsigned int DSUBASEADDRESS = SocExplorerEngine::self()->getEnumDeviceBaseAddress(this,0x01 , 0x004,0); + if(DSUBASEADDRESS == (unsigned int)-1) + DSUBASEADDRESS = 0x90000000; + WriteRegs(uIntlist()<<2,DSUBASEADDRESS+0x400024); + unsigned int reg = ReadReg(DSUBASEADDRESS+0x700000); + return ((reg&0x0F)==0x0F); +} + bool dsu3plugin::setCacheEnable(bool enabled) { if(parent==NULL) @@ -313,13 +325,6 @@ void dsu3plugin::writeSection(const QStr } -unsigned int dsu3plugin::Write(unsigned int *Value,unsigned int count,unsigned int address) -{ - if(parent!=NULL) - return parent->Write(Value,count,address); - return 0; -} - bool dsu3plugin::memSet(unsigned int address,int value, unsigned int count) { unsigned int* buffer = (unsigned int*)malloc(count*sizeof(unsigned int)); @@ -332,10 +337,3 @@ bool dsu3plugin::memSet(unsigned int add } return false; } - -unsigned int dsu3plugin::Read(unsigned int *Value,unsigned int count, unsigned int address) -{ - if(parent!=NULL) - return parent->Read(Value,count,address); - return 0; -} diff --git a/dsu3plugin/dsu3plugin.h b/dsu3plugin/dsu3plugin.h --- a/dsu3plugin/dsu3plugin.h +++ b/dsu3plugin/dsu3plugin.h @@ -42,13 +42,12 @@ public: ~dsu3plugin(); bool memSet(unsigned int address, int value, unsigned int count); public slots: - unsigned int Write(unsigned int *Value,unsigned int count,unsigned int address=0); - unsigned int Read(unsigned int *Value,unsigned int count, unsigned int address=0); void openFile(); void openFile(QString fileName); bool configureTarget(); bool cacheDisable(); bool cacheEnable(); + bool cacheIsEnable(); bool setCacheEnable(bool enabled); bool flashTarget(); void run(); diff --git a/spwplugin/StarDundee/stardundeespw_usb.cpp b/spwplugin/StarDundee/stardundeespw_usb.cpp --- a/spwplugin/StarDundee/stardundeespw_usb.cpp +++ b/spwplugin/StarDundee/stardundeespw_usb.cpp @@ -25,7 +25,7 @@ #include #include -QString dwLinkStatusQString[6] = { +const QString dwLinkStatusQString[6] = { "CFG_SPACEWIRE_ERROR_RESET", "CFG_SPACEWIRE_ERROR_WAIT", "CFG_SPACEWIRE_READY",