Cleaned up ANSTO code to merge with sinqdev.sics

This is our new RELEASE-4_0 branch which was taken from ansto/93d9a7c
Conflicts:
	.gitignore
	SICSmain.c
	asynnet.c
	confvirtualmot.c
	counter.c
	devexec.c
	drive.c
	event.h
	exebuf.c
	exeman.c
	histmem.c
	interface.h
	motor.c
	motorlist.c
	motorsec.c
	multicounter.c
	napi.c
	napi.h
	napi4.c
	network.c
	nwatch.c
	nxscript.c
	nxxml.c
	nxxml.h
	ofac.c
	reflist.c
	scan.c
	sicshipadaba.c
	sicsobj.c
	site_ansto/docs/Copyright.txt
	site_ansto/instrument/lyrebird/config/tasmad/sicscommon/nxsupport.tcl
	site_ansto/instrument/lyrebird/config/tasmad/taspub_sics/tasscript.tcl
	statusfile.c
	tasdrive.c
	tasub.c
	tasub.h
	tasublib.c
	tasublib.h
This commit is contained in:
Ferdi Franceschini
2015-04-23 20:49:26 +10:00
parent c650788a2c
commit 10d29d597c
1336 changed files with 9430 additions and 226646 deletions

View File

@@ -8,6 +8,10 @@
Mark Koennecke, November 1996
Revised: Mark Koennecke, September 1997
Removed unused UDP interrupt port stuff
Mark Koennecke, February 2013
Copyright: see copyright.h
@@ -22,10 +26,7 @@
#include <strlutil.h>
#include "fortify.h"
#include "conman.h"
#include "SCinter.h"
#include "nserver.h"
#include "obdes.h"
#include "sics.h"
#include "network.h"
#include "interrupt.h"
#include "status.h"
@@ -40,8 +41,6 @@
#define MAXINTERRUPT 7
#define INTERUPTWAIT 5
static mkChannel *IntPort = NULL;
static pTaskMan pTask = NULL;
/*----------------------------------------------------------------------------*/
static char *pIntText[] = {
"continue",
@@ -53,35 +52,6 @@ static char *pIntText[] = {
"end",
NULL
};
/*---------------------------------------------------------------------------*/
int ServerSetupInterrupt(int iPort, pNetRead pNet, pTaskMan pTasker)
{
int i;
pTask = pTasker;
/* setup interrupt port */
IntPort = UDPOpen(iPort);
if (IntPort == NULL) {
return 0;
} else {
NetReadRegister(pNet, IntPort, udp, NULL);
return 1;
}
}
/*--------------------------------------------------------------------------*/
void ServerStopInterrupt(void)
{
/* close the port */
if (IntPort) {
NETClosePort(IntPort);
free(IntPort);
}
}
/*-------------------------------------------------------------------------*/
void SetInterrupt(int iCode)
{
@@ -89,7 +59,7 @@ void SetInterrupt(int iCode)
iInt = iCode;
TaskSignal(pTask, SICSINT, &iInt);
TaskSignal(pServ->pTasker, SICSINT, &iInt);
}
/*--------------------------------------------------------------------------*/