Resumen del contenido incluido en la página 1 
                    
                         
SDM-SW8A 8 Channel
Switch Closure Module
Revision: 7/07
Copy right © 1987-2007
Campb e ll Scienti f i c , In c.                                                                                                                                                                                                                                                                                                                                                                                                   
                    
                    Resumen del contenido incluido en la página 2 
                    
                        Warranty and Assistance  The SDM-SW8A SWITCH CLOSURE INPUT MODULE is warranted by  CAMPBELL SCIENTIFIC, INC. to be free from defects in materials and  workmanship under normal use and service for twelve (12) months from date  of shipment unless specified otherwise.  Batteries have no warranty.   CAMPBELL SCIENTIFIC, INC.'s obligation under this warranty is limited to  repairing or replacing (at CAMPBELL SCIENTIFIC, INC.'s option) defective  products.  The customer shall assume all costs of remov
                    
                    Resumen del contenido incluido en la página 3 
                    
                        SDM-SW8A Table of Contents  PDF viewers note:  These page numbers refer to the printed version of this document.  Use  the Adobe Acrobat® bookmarks tab for links to specific sections.  1.  Function........................................................................1  2.  Specifications ..............................................................2  3.  Power Supply Considerations....................................3  4.  Connections...........................................................
                    
                    Resumen del contenido incluido en la página 4 
                    
                        SDM-SW8A Table of Contents  List of Tables  1.  Datalogger to SDM-SW8A Connections................................................... 2  2.  SDM-SW8A to SDM-SW8A Connections................................................ 3  3.  Address Jumpers ........................................................................................ 5  4.  Measurement Jumpers................................................................................ 6  5.  Instruction 102 – SDM-SW8A .........................
                    
                    Resumen del contenido incluido en la página 5 
                    
                        SDM-SW8A Switch Closure Input  Module  1.  Function  The 8 channel SDM-SW8A Switch Closure Input Module (see Figure 1)  measures up to 8 channels of switch closure or voltage pulse inputs.  Each  channel may be configured to read single-pole double-throw (SPDT) switch  closure, single-pole single-throw (SPST) switch closure, or voltage pulse.   Output options include counts, duty cycle, and state.  The SW8A is addressed by the datalogger, allowing multiple SW8As to be  connected to one datalogge
                    
                    Resumen del contenido incluido en la página 6 
                    
                        SDM-SW8A Switch Closure Input Module  2.  Specifications  Operating voltage: 12 VDC nominal (9.6 to 16)  Current drain: 3 mA quiescent, 6 mA active (max)  o Environmental: -25 to +50 C, 0 to 90% RH,  noncondensing  Measurement types: Switch closure (SPDT, SPST) DC voltage  pulse  Input voltage threshold: From below 0.9 to above 4.0 VDC,±20  VDC max  Maximum input frequency: 100 Hz (50% duty cycle)  Minimum input pulse width: 5 ms high, 5 ms low  Maximum bounce time: 3 ms open without counting  O
                    
                    Resumen del contenido incluido en la página 7 
                    
                        SDM-SW8A Switch Closure Input Module    TABLE 2.  SDM-SW8A to SDM-SW8A Connections   SDM-SW8A that’s connected to    a CR10(X), CR800, CR850,    CR1000, CR23X, CR3000, SDM-SW8A that’s  SDM-SW8A CR5000, or CR7 connected to a 21X  +12 12 V +12          C3 C3 C3  C2 C2 C2  C1 IN C1 IN C1 IN  C1 OUT not used (see Note 2) C1 OUT (see Note 3)    Notes:  (1) If using an auxiliary power supply, instead of connecting the datalogger’s   12 V or +12 terminal to the SW8A, connect the power supply’s positive
                    
                    Resumen del contenido incluido en la página 8 
                    
                        SDM-SW8A Switch Closure Input Module  4.  Connections  All connections to the datalogger, power supply, and other SW8As are made  from terminals located under "TO DATALOGGER" on the SW8A (refer to  Figure 1).  Sensor connections are made at the remaining terminals.    4.1  Connections to Dataloggers and Other SW8As  Connections between an SW8A and the CR10 and 21X dataloggers are shown  in Table 1.  Connections to multiple SW8As are shown in Table 2.    1. The order in which connections are made
                    
                    Resumen del contenido incluido en la página 9 
                    
                        SDM-SW8A Switch Closure Input Module    TABLE 3.  Address Jumpers   Pins  Address 1-8 2-7 3-6 4-5  00 c c c c  01 c c c nc  02 c c nc c  03 c c nc nc  10 c nc c c  11 c nc c nc  12 c nc nc c  13 c nc nc nc  20 nc c c c  21 nc c c nc  22 nc c nc c  23 nc c nc nc  30 nc nc c c  31 nc nc c nc  32 nc nc nc c  33 nc nc nc nc  c = connected     nc = not connected      FIGURE 2.  SDM-SW8A Address and Port Configuration Jumpers with Sensor Wiring Examples  5                                              
                    
                    Resumen del contenido incluido en la página 10 
                    
                        SDM-SW8A Switch Closure Input Module  5.2  Measurement Jumpers  Near each input channel is a jumper triplet used to configure the channel for  the measurement type.  The SDM-SW8A is shipped from the factory with each  channel configured for DC Voltage pulse.  An example of each configuration  is illustrated in Figure 2.  Table 4 shows jumper pins and the corresponding  measurement type.  TABLE 4.  Measurement Jumpers  Measurement Type Pins  Jumpered  SPDT Switch Closure 1 and 6  SPST Switch Cl. 
                    
                    Resumen del contenido incluido en la página 11 
                    
                        SDM-SW8A Switch Closure Input Module    Parameter Enter  & Data Type  FunctOp The FunctOp is used to determine the result that will be returned by the  Constant SW8A.   Numeric Function  Code  0 Returns the state of the signal at the time the instruction is    executed.  A 0 is stored for low and a 1 is stored for high.   1 Returns the duty cycle of the signal.  The result is the  percentage of time the signal is high during the scan interval.   2 Returns a count of the number of positive transi
                    
                    Resumen del contenido incluido en la página 12 
                    
                        SDM-SW8A Switch Closure Input Module    NOTE Instruction 102 is not contained in all CR10 or 21X PROMS.  To  verify that the datalogger contains the Instruction, enter 102 into  a datalogger Programming Table.  If the Instruction is accepted,  the PROM contains the Instruction.  Repetitions (Reps, Parameter 1) specifies the number of SW8A channels to  read.  Parameter 2 is the address of the first SW8A.  If more Reps are  requested than exist in one module, the datalogger automatically increment
                    
                    Resumen del contenido incluido en la página 13 
                    
                        SDM-SW8A Switch Closure Input Module  7.  Datalogger Program Details  7.1  Datalogger Scan Rate  The Module samples channel state every 2 ms and accumulates the information  for duty cycle and counts.  Each channel has one 16 bit accumulator for duty  cycle and one for counts.  The accumulators are reset when the datalogger  requests information from the SW8A and when the count exceeds 65535.  The  datalogger scan rate must be frequent enough to avoid SW8A accumulator  overflow.  Each Duty Cycle
                    
                    Resumen del contenido incluido en la página 14 
                    
                        SDM-SW8A Switch Closure Input Module  forces a watchdog reset by addressing the Module and requesting sufficient  information to cause a minimum of 65 clock line transitions.  Advantages to  the trapping routine are:  • The bombed processor is detected before erroneous values (-99999) are  included in subsequent processing.  • The processor may be reset sooner.  • The time of processor failure may be logged by the datalogger.  • Number of failures may be logged.  A trapping routine, as described
                    
                    Resumen del contenido incluido en la página 15 
                    
                        SDM-SW8A Switch Closure Input Module  8.2  SPST Switch Closure  Single-pole single-throw switches are either open (high state) or connected to  ground (low state).  Typical SPST switches include contact closure (reed  switch) anemometers, tipping bucket rain gauges, and  open collectors  (semiconductor switches).  Many control devices utilize open collectors and  provide terminals for monitoring the switch.    For all SW8A measurements, the 100 Hz maximum input frequency and 5 ms  pulse width sp
                    
                    Resumen del contenido incluido en la página 16 
                    
                        SDM-SW8A Switch Closure Input Module  50% Duty Cycle - The "worst case" duty cycle measurement error for a 50%  duty cycle at a given input frequency is  ±ERROR = Hz * 0.4  where ERROR = Actual Duty Cycle ±Measured  Duty Cycle.  For example, a 50% duty cycle at 10 Hz could be measured as 46% to 54% in  the worst case.  Minimum/Maximum - The measurable minimum/maximum duty cycle is  defined by the 5 ms pulse width specification of the SW8A.  For example, at a  10 Hz frequency, the minimum and max
                    
                    Resumen del contenido incluido en la página 17 
                    
                        SDM-SW8A Switch Closure Input Module  addressed SW8A is present.  The 21X works similarly, except the data from  the SW8A is input to single ended analog channel 1, not C1.   Depending on the Command, Reps, and Channel information, the module will  shift out one or more bytes to the datalogger, again using C2 as a clock driven  by the datalogger.  The module shifts out each bit on the falling edge of the  clock; the datalogger reads each bit on the rising edge of the clock.      Each time an ent
                    
                    Resumen del contenido incluido en la página 18 
                    
                        SDM-SW8A Switch Closure Input Module  This is a blank page.      14                                                                                                                                                                                                                                                                                                                                                                                                                                                 
                    
                    Resumen del contenido incluido en la página 19 
                    
                        Appendix A.  Program Example  The Edlog program is an example only and is not meant to be used verbatim.   In application, the concepts illustrated here are likely to be only fragments of a  larger program.  The example program reads all 8 ports of an SW8A which is set to address 00.   It is read three times per scan, once each for State, Duty Cycle, and Count  information.  The scan rate is fixed at 1 second, with a 5 minute output of  State, average Duty Cycle, and average Count.  To prevent e
                    
                    Resumen del contenido incluido en la página 20 
                    
                        Appendix A.  Program Example    FIGURE A-1.  Example Program Flow Chart  PROGRAM EXAMPLE  Input Locations Used:   1:STATE #1 13:DUTY #5    2:STATE #2 14:DUTY #6    3:STATE #3 15:DUTY #7    4:STATE #4 16:DUTY #8    5:STATE #5 17:COUNT#1    6:STATE #6 18:COUNT #2    7:STATE #7 19:COUNT #3    8:STATE #8 20:COUNT #4     9:DUTY #1 21:COUNT #5    10:DUTY #2 22:COUNT #6    11:DUTY #3 23:COUNT #7   12:DUTY #4 24:COUNT #8    25:RESET CNT    Output Arrays: ID = 105, 27 ELEMENTS   ID = 112,  4 ELEMENTS