// -*- C++ -*- /* This file is part of UCESB - a tool for data unpacking and processing. * * Copyright (C) 2016 GSI Helmholtzzentrum fuer Schwerionenforschung GmbH * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 2.1 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, * MA 02110-1301 USA */ /* This file provides specifications for: * * VME_CAEN_V767A - 64 ch, geom address not set by software * VME_CAEN_V767 - 128, geom address ncan be set by software */ #ifndef VME_CAEN_V767x # define VME_CAEN_V767x_NUM_CH 64 # define VME_CAEN_V767x VME_CAEN_V767A # include "vme_caen_v767.spec" # undef VME_CAEN_V767x_NUM_CH # undef VME_CAEN_V767x # define VME_CAEN_V767x_NUM_CH 128 # define VME_CAEN_V767x VME_CAEN_V767 # include "vme_caen_v767.spec" # undef VME_CAEN_V767x_NUM_CH # undef VME_CAEN_V767x #else VME_CAEN_V767x(geom) { // Should have our own data type... MEMBER(DATA24 data[VME_CAEN_V767x_NUM_CH] ZERO_SUPPRESS_MULTI(128)); UINT32 marker { 0_31: marker = 0x767a767a; } UINT32 header { 0_11: event_number; 12_20: undef1; 21: 0; 22: 1; 23_26: undef2; #if VME_CAEN_V767x_NUM_CH == 128 27_31: geom = MATCH(geom); #endif #if VME_CAEN_V767x_NUM_CH == 64 27_31: geom; #endif } several UINT32 ch_data NOENCODE { 0_19: value; 20: edge; 21: 0; 22: 0; 23: start; 24_30: channel; 31: undefined; ENCODE(data[channel], (value=value)); } UINT32 eob { 0_15: number_of_hits; 16_20: undef1; 21: 1; 22: 0; 23: undef2; 24_26: status; #if VME_CAEN_V767x_NUM_CH == 128 27_31: geom = MATCH(geom); #endif #if VME_CAEN_V767x_NUM_CH == 64 27_31: geom; #endif } } #endif