diff --git a/slsDetectorSoftware/mythenDetectorServer/Makefile.picasso b/slsDetectorSoftware/mythenDetectorServer/Makefile.picasso new file mode 100644 index 000000000..11e3645fd --- /dev/null +++ b/slsDetectorSoftware/mythenDetectorServer/Makefile.picasso @@ -0,0 +1,46 @@ +# $Id: Makefile,v 1.1.1.1 2006/02/04 03:35:01 freza Exp $ +# first compile +# make cris-axis-linux-gnu + +AXIS_USABLE_LIBS = UCLIBC GLIBC +include $(AXIS_TOP_DIR)/tools/build/Rules.axis + +PROGS= mythenDetectorServer +PICASSO= picassoDetectorServer +PICASSOFLAGS= -DPICASSOD + +INSTDIR= $(prefix)/bin +INSTMODE= 0777 + +SRCS= server.c server_funcs.c communication_funcs.c firmware_funcs.c mcb_funcs.c trimming_funcs.c sharedmemory.c +OBJS= $(SRCS:%.c=%.o) + +CFLAGS+= -Wall -DC_ONLY -DMCB_FUNCS -DVERBOSE -DVERYVERBOSE -DPICASSOD +#-Werror + +LDLIBS+= -lm + +picasso: $(PICASSO) +mythen: $(PROGS) +all: $(PROGS) $(PICASSO) + +boot: $(OBJS) + +$(PROGS): $(OBJS) + echo $(OBJS) + $(CC) $(LDFLAGS) $^ $(LDLIBS) $(CFLAGS) -o $@ + +$(PICASSO): $(OBJS) + echo $(OBJS) + $(CC) $(LDFLAGS) $^ $(LDLIBS) $(CFLAGS) $(PICASSOFLAGS) -o $@ + + +install: $(PROGS) + $(INSTALL) -d $(INSTDIR) + $(INSTALL) -m $(INSTMODE) $(PROGS) $(INSTDIR) + +clean: + rm -rf $(PROGS) $(PICASSO) *.o + +depend: + makedepend -Y -- $(CFLAGS) -- $(SRCS) 2>/dev/null diff --git a/slsDetectorSoftware/mythenDetectorServer/picasso_defs.h b/slsDetectorSoftware/mythenDetectorServer/picasso_defs.h new file mode 100755 index 000000000..35ab28b38 --- /dev/null +++ b/slsDetectorSoftware/mythenDetectorServer/picasso_defs.h @@ -0,0 +1,42 @@ +#ifndef SERVER_DEFS_H +#define SERVER_DEFS_H + +#include "sls_detector_defs.h" + +#include + + +// Hardware definitions + +#define NCHAN 128 +#define NCHIP 12 //10 modified for PICASSO +#define NMAXMODX 24 +#define NMAXMODY 1 +#define NMAXMOD NMAXMODX*NMAXMODY +#define NDAC 6 +#define NADC 0 + +#define NCHANS NCHAN*NCHIP*NMAXMOD +#define NDACS NDAC*NMAXMOD + +#define NTRIMBITS 6 +#define NCOUNTBITS 24 + +//#define TRIM_DR ((2**NTRIMBITS)-1) +//#define COUNT_DR ((2**NCOUNTBITS)-1) +#define TRIM_DR (((int)pow(2,NTRIMBITS))-1) +#define COUNT_DR (((int)pow(2,NCOUNTBITS))-1) + + +#define ALLMOD 0xffff +#define ALLFIFO 0xffff + +#ifdef VIRTUAL +#define DEBUGOUT +#endif + +#define CLK_FREQ 100E+6 + + +#define THIS_SOFTWARE_VERSION 0x20090205 +#endif