Hardware Release -- 68

		      Specification for a
		     ---------------------     
		     CAMAC Ramp Controller
		     ---------------------
		      (CAMAC Module C165)
						W.Knopf, September 9, 1983
						Revised:
						November 13, 1984, version 1.20/5.20
						Feb. 19, 1987  M.J.Petter  1.28/5.28


	I.	GENERAL DESCRIPTION:
		--------------------
		Two slot wide CAMAC module providing for STATUS
		read-back, CONTROL and REFERENCE VOLTAGE output to
		power supply.

	     -	16 status lines (-24 VDC, opto-coupled),
		   can be hardware configured for +5 VDC.
	     -	Relay contacts for ON, OFF, RESET and POLARITY control,
		   all of which are of 1 sec. duration,
	     -	16-bit buffered D/A output, +/- 10.00 VDC
	     -  Optional isolated D/A output


	II.	RAMP CONTROL:
		-------------
	    1.	On board decoding of Accelerator Clock and MDAT for time
		and amplitude reference.
		Only one type code of MDAT data is hardware implemented;
		this implies that modules monitoring the Main Ring current
		need a PLA different from the Doubler energy monitoring
		modules.

	    2.	1 KHz update of D/A.
		
	    3.	Multiple ramp waveforms to be downloaded by host consisting
		of amplitude and time (64 values of 16 bits each).
		Two active ramps are supported.

	    4.	Single CAMAC function for ramp selection.

	    5.	Single CAMAC function for scale factor.

	    6.	Single CAMAC function for slope selection.

	    7.	Built-in default ramp waveforms.

	    8.  Clock event selection for ramp control.

	    9.  Switch to second ramp on clock event.


		CAMAC RAMP CONTROLLER FUNCTIONS.
		================================
	Note: Numbers in square brackets are module execution times.


A)	POWER SUPPLY CONTROL FUNCTIONS:
	-------------------------------
	These CAMAC functions will cause the appropriate relay to be
	activated for approx. 1 sec.

	RESET			-	F(26) * A(7)

	ON			-	F(26) * A(1)

	OFF			-	F(24) * A(1)

	POSITIVE POLARITY	-	F(26) * A(3)

	NEGATIVE POLARITY	-	F(24) * A(3)

	Default values after module reset: OFF, POS. POLARITY,
	LAM disabled, ramp disabled/set to zero.

	This reset applies to power-up, CAMAC F(9)*A(0)
	and to front panel push-button reset.




B)	RAMP AND POWER SUPPLY REFERENCE VOLTAGE FUNCTIONS:
	--------------------------------------------------

	SET RAMP DATA POINTER	-	F(16) * A(7) * N
					[ 20.4 usec ]

	 High byte = ramp number, low byte = data offset in bytes.
	 This function sets the pointer for subsequent data trans-
	 fer (read/write) of ramp data. Tables are arranged as
	 alternate 16-bit values of f(t) and delta(t), so offset
	 should always be an even number.
	 Upon reaching the last entry for the selected ramp the
	 pointer will wrap arount to the first entry of the table.

	WRITE RAMP DATA		-	F(16) * A(0)
					[ 18.9 usec ]

	 This function will load pre-selected ramp tables and
	 post-increment the pointer. If the active ramp is selected,
         the data is ignored and the CAMAC VALUE ERROR bit (bit #14)
	 is set in the LAM source register.

	READ RAMP DATA		-	F(1)  * A(0)
					[ 12.3 usec ]

	 Read data from pre-selected ramp and post-increment pointer.

	SET D/A VOLTAGE		-	F(16) * A(1)
					[ 10.8 usec ]

	 Forces D/A output to selected value; this function is not
	 dependent on RAMP ENABLED/DISABLED status.

	READ D/A VOLTAGE	-	F(0)  * A(1)
					[ 8.9 usec ]

	 This read function will return the actual input value
	 present at the D/A.

	READ CALCULATED RAMP	-	F(0)  * A(7)
					[ 8.9 usec ]

	 This function will return the present unscaled value of
	 the ramp.

	DEFINE CLOCK EVENT	-	F(16) * A(6)
					[ 93 usec ]

	 High byte = event number, low byte = associated clock event
	 number.
	 Events and their function are:
	 	1	-	reset to start of ramp 1
				install scale factor #1
				force ramp enable/energy enable
				       ( if previously selected )
				Install new ramps ( if selected )
		2	-	reset to start of ramp 2
				install scale factor #2
				force ramp enable/energy enable
					(if previously selected)
				install new ramps (if selected)
		3	-	start of front porch slope
		4	-	end of front porch slope
		5	-	start of flat top slope
		6	-	end of flat top slope
		7	-	start timer for switch to scale factor #2


	SET CLOCK EVENT POINTER	-	F(17) * A(14)
					[ 13.6 usec ]

	 Set pointer for subsequent read-back of clock event assignments.
	 Should be in the range of 1 - 7.

	READ CLOCK EVENT ASSIGNMENT	-	F(0) * A(14)
						[ 18.3/20.7 usec ]

	 Return event number in high byte, clock event number in low byte;
	 post-increment to next event, wrap around at end.

	ENABLE RAMP OUTPUT	-	F(26) * A(2)

	 This will enable ramp calculation and D/A update
	 after the next ramp #1 reset clock event.

	DISABLE RAMP OUTPUT	-	F(24) * A(2)

	 This will immediately disable ramp calculation and
	 D/A update.
	 D/A value will hold at the last loaded value.

	EXECUTE RAMP NUMBER	-	F(16) * A(5) * r2r1
					[ 26.2 usec ]

	 The high byte of r2r1 contains ramp #2, the low byte of r2r1
	 contains ramp #1.
	 This will install the selected ramp number as the next active
	 ramp ( n = 0 to 10 ) after the next ramp reset clock event.
	 A value of zero for either r2 or r1 will install a null table,
	 forcing the D/A output to zero if that table is selected.
	 Disabling of any clock event should be done by loading TCLK
	 event 0FEH ( hardware clock NOP ).

	READ ACTIVE RAMP NUMBER  -      F(1)  * A(5) * r2r1
					[ 8.9 usec ]

	 Returns active (but not necessarily loaded) ramp numbers.

	SET F.T. SCALE FACTOR	-	F(17) * A(1)
					[ 10.6 usec ]

	 Set ramp scale factor #2

	READ F.T. SCALE FACTOR	-	F(1)  * A(1)
					[ 8.9 usec ]

	SET F.P. SCALE FACTOR	-	F(17) * A(2)
					[ 10.6 usec ]

	 Set ramp scale factor #1

	READ F.P. SCALE FACTOR	-	F(1)  * A(2)
					[ 8.9 usec ]

	SET F.T. SLOPE		-	F(17) * A(3)
					[ 8.9 usec ]

	 Set slope value for time = start of flat top to end of flat top.

	READ F.T. SLOPE		-	F(1)  * A(3)
					[ 8.9 usec ]

	SET F.P. SLOPE		-	F(17) * A(4)
					[ 8.9 usec ]

	 Set slope value for time = start of front porch to end of front porch.

	READ F.P. SLOPE		-	F(1)  * A(4)
					[ 8.9 usec ]

	SET S.F. SWITCH		-	F(17) * A(6)
					[ 11.3 usec ]

	 Delay of scale factor switch from scale factor #1 to scale factor #2

	READ S.F. SWITCH	-	F(1)  * A(6)
					[ 8.9 usec ]

	ENABLE ENERGY SCALING	-	F(26) * A(4)

	 Enable scaling of ramp values by Doubler current (IRING)
	 or Main Ring current as read from MDAT link.
	 This is enabled at reset time.

	DISABLE ENERGY SCALING	-	F(24) * A(4)

	 Disable scaling of ramp values by Doubler current.

	RESTORE DEFAULT RAMPS	-	F(16) * A(14)
					[ 575 usec ]
	 Restores default ramps in memory;
	 current ramp pointers and clock event selections are
	 not affected.


C)	MODULE LAM AND STATUS FUNCTIONS:
	--------------------------------

	READ STATUS		-	F(0)  * A(0)
					[ 13.1 usec ]

	 Return 16-bit status of power supply. This value is determined
	 from the values present at the I/O connector.

	SET NOMINAL VALUES	-	F(16) * A(2)
					[ 8.9 usec ]

	READ NOMINAL VALUES	-	F(0)  * A(2)
					[ 8.9 usec ]

	SET STATUS MASK		-	F(16) * A(3)
					[ 8.9 usec ]

	READ STATUS MASK	-	F(0)  * A(3)
					[ 8.9 usec ]

	SET LAM MASK		-	F(16) * A(4)
					[ 8.9 usec ]

	READ LAM MASK		-	F(0)  * A(4)
					[ 8.9 usec ]

	READ & CLEAR STATUS ERROR -	F(0)  * A(5)
					[ 12.5 usec ]
	 Status error consists of:
		(status .xor. nominal value) .and. mask

	READ/CLEAR LAM SOURCE REG. -	F(0)  * A(6)
					[ 12.5 usec ]
	 The READ/CLEAR will clear only the high byte of the LAM source register

		LAM source register bits:
			bit # 2 -	ramp enable/disable
			bit # 3 -	energy scaling enable/disable
		
			bit #11 -	status error
			bit #12 -	missing TCLK (updated at 1 Hz rate)
			bit #13 -	missing MDAT (updated at 1 Hz rate)
			bit #15 -	illegal CAMAC write value

	ENABLE LAM		-	F(26) * A(0)

	 The LAM is raised relative to only the high byte of the LAM source register

	DISABLE LAM		-	F(24) * A(0)

	TEST LAM		-	F(8)  * A(0)
		Q = 1 -> LAM is set
		Q = 0 -> LAM is reset
		This is a true immediate hardware response.

	READ MODULE I.D.	-	F(6)  * A(0)
					[ 7.9 usec ]

	READ VERSION NUMBER	-	F(6)  * A(1)
					[ 7.9 usec ]

	RESET MODULE		-	F(9)  * A(0)

	 This is a hardware reset and will not alter table values.
	 Ramp is disabled and D/A set to zero.
	 Exception: After execution of a CAMAC F(16)*A(13) the reset
	 function will restart the module like a power-on clear.


D)	FUNCTIONAL DESCRIPTION:

    1.	Reference voltage output to be updated at 1 KHz rate.

	Output function defined as:

	V(out) = S.F. * ( E * V(t) ) where

	S.F. = Scale factor  (S.F.1 < T(switch) < S.F.2)

	E    = Energy in Saver or Main Ring, set to value of 1
	       when E is disabled.

	V(t) = Table value, interpolated for 1 msec. intervals.

	Note: Ramp voltage is unipolar 0 to 10 V in firmware 

              versions 1.xx, bipolar -10 V to + 10 V in versions 5.xx.

    2.	Scale factors to be changed at any time by CAMAC function,

	switch between S.F.1 and S.F.2 to be triggered by clock event

	and selected delay from that event. (t = 2 to 65536 msec)

    3.  Slopes are added to output at front porch and flat top time only.


E)
	The following are CAMAC functions which are intended for
	diagnostic purposes only and need not be supported by the system
	in general.

    a)			READ FUNCTIONS.

	F(0)*A(8)   - Read time into ramp  (ticker/256) ticker = 1 KHz

	F(1)*A(7)   - Read energy  (MDAT .SHR. 1)

	F(6)*A(3)   - Read diagnostic status word

	F(6)*A(4)   - Read diagnostic data


   b)		WRITE FUNCTIONS

	F(16)*A(13) - Destroy the reset test word.
			(Will cause a hard reset on next F(9)*A(0) )

	F(16)*A(14) - Restore default ramp tables.

	 Transfer default ramps from ROM to RAM; does not reset ramp.
	 Current ramp numbers remains current.

	F(19)*A(2)  - Write diagnostic control word (type code).

	F(19)*A(3)  - Write diagnostic data.


	Standard contact configuration.
	===============================

	All relay contacts are activated with an appropriate
	CAMAC function command. Relay activation is momentary,
	of 1 sec. duration.

	ON/OFF:
		pin 8R - common
		pin 9R - on (n.o.)
		pin 7R - off (n.c.)

	RESET:
		pin 8L - common
		pin 9L - reset (n.o. - NOR for Normally Open Reset)
		pin 7L - reset (n.c. for normally closed reset)

	POLARITY REVERSAL:
		pin 5L - common
		pin 4L - positive polarity (n.c.)
		pin 6L - negative polarity (n.o.)

	D/A OUTPUT:
		16 bit, single ended, referenced to pins 1L & 1R common,
		buffered with output amplifier (voltage follower).
		Optionally used with opto-isolated output amplifier,
		referenced to pin 2L (common).

	STATUS INPUT (firmware version 1.xx):
		-24 VDC, referenced to pins 1R and 1L (ground), 1.5 ma
		current sinking.
		Status bit is set when -24 VDC is applied to input of
		status line.

	Optional 5 VDC STATUS INPUT (firmware version 5.xx):
	
		Opto-isolators are sourced on board by +5 VDC and
		require external current sinking on the status input
		of 1 to 1.5 ma to ground (pins 1L and 1R) to produce
		a logic level of ONE.
		Preferred drivers are open collector type. 
		The -24 VDC (pin 18L) is not supplied on this version.


			Standard configuration.
			-----------------------
	Output connector (36 pin VIKING type) for power supply operation
	----------------------------------------------------------------

1L   Ground				1R   Ground   
2L   Isolated output Common		2R   Open
3L   Open				3R   (Neg Polarity N/C)

4L   Pos Polarity N/C			4R   Open
5L   Pos/Neg Polarity Common 		5R   Open
6L   Neg Polarity N/O			6R   (On N/C)

7L   Reset N/C				7R   Off N/C
8L   Reset Common			8R   On/Off Common
9L   Reset N/O				9R   On N/O

10L  DS 5				10R  D/A Output or Isolated Output
11L  DS 7				11R  DS 6
12L  DS 3				12R  DS 4

13L  DS 1				13R  DS 2
14L  DS 10				14R  DS 0 - LSB
15L  DS 8				15R  DS 9 

16L  DS 12				16R  DS 11
17L  DS 14				17R  DS 13
18L  -24 VDC Output (fused at 1 amp)	18R  DS 15 - MSB

Security, Privacy, Legal