SICS-638 Send a pause to the histmem when SICS receives an INT1712 interrupt.
This is done by mapping AnstoHttpPauseNoCon() to Halt in the histmem interface. An ANSTO stop command astop has been added to send a Stop to the histmem which is needed when uploading a new configuration.
This commit is contained in:
@@ -663,6 +663,9 @@ pPriv->pause = 1;
|
||||
|
||||
return OKOK;
|
||||
}
|
||||
static int AnstoHttpPauseNoCon(pHistDriver self) {
|
||||
return AnstoHttpPause(self, NULL);
|
||||
}
|
||||
/*---------------------------------------------------------------------*/
|
||||
static int AnstoHttpContinue(pHistDriver self, SConnection *pCon){
|
||||
pAnstoHttp pPriv = NULL;
|
||||
@@ -934,7 +937,7 @@ pHistDriver CreateAnstoHttpDriver(pStringDict pOption){
|
||||
/* configure all those functions */
|
||||
pNew->Configure = AnstoHttpConfigure;
|
||||
pNew->Start = AnstoHttpStart;
|
||||
pNew->Halt = AnstoHttpHalt;
|
||||
pNew->Halt = AnstoHttpPauseNoCon;
|
||||
pNew->GetCountStatus = AnstoHttpStatus;
|
||||
pNew->GetError = AnstoHttpError;
|
||||
pNew->TryAndFixIt = AnstoHttpFixIt;
|
||||
@@ -967,6 +970,14 @@ pHistDriver CreateAnstoHttpDriver(pStringDict pOption){
|
||||
|
||||
|
||||
self = (pHistMem)pData;
|
||||
if(strcmp(argv[1],"astop") == 0) {
|
||||
if(!SCMatchRights(pCon,usUser)) {
|
||||
return 0;
|
||||
}
|
||||
AnstoHttpHalt(self->pDriv);
|
||||
SCSendOK(pCon);
|
||||
return 1;
|
||||
}
|
||||
if(strcmp(argv[1],"pause") == 0) {
|
||||
if(!SCMatchRights(pCon,usUser)) {
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user