background image

BL4S200 User’s Manual

37

The BL4S200 can be used in an RS-485 multidrop network. Connect the 485+ to 485+ 
and 485– to 485– using single twisted-pair wires (nonstranded, tinned) as shown in 
Figure 12. Note that a common ground is recommended.

Figure 12.  BL4S200 Multidrop Network

The BL4S200 comes with a 220 

 termination resistor and two 681 

 bias resistors 

installed and enabled with jumpers across pins 1–2 and 5–6 on header JP7, as shown in 
Figure 13.

Figure 13.  RS-485 Termination and Bias Resistors

RS-485–

RS485+

GND

RS-485–

RS485+

GND

RS-485–

RS485+

GND

RESET

S1

S2

R1

CORE +3.3 V

DS1

DS2

J9

J10

J11

J12

J8

J7

J6

J5

J4

J3

J2

J1

RCM1

R7
R8
R9

R10

C63

JP4

JP5

JP6

JP3

C62

C47

JP7

RS485

JP9

JP8

KB

+5 V

GND

+3.3 v

KA

+5 V

GND

+3.3 V

C52

C55

C57

C61

C56

C60

C50 C51

C49

C59

C54

C48

C53

C58

U7

C38 C39 C40

C21

C27

C33

C17

C19

C25

C14

R4

R2

C12

C13 U5

U6

C16

C41 C42 C43

C23

C29

C35

C22

C28

C34

U8

C44 C45 C46

C24

C30

C36

R117

RP1

U4

C37

RP2

R5

R121

L2

L3

BT1

C31

C32

U3

C15

C10

U2

C11

C9

C8

U1

R116
R3

R118

C18

C20

C26

JP1

JP2

D2

D3

L1

D4

C1

C2

C3

C4

C6

TERM

TERM

KC

+5 V

GND

+3.3 V

KD

+5 V

GND

+3.3 V

CAUTION! HOT!

CAUTION! HOT!

D6

D5

D8

D7

D9

C5

C7

D10

DS4

DS3

R6

BOARD

+3.3 V

POWER

  IN

R–NET PWR

4

1

7

14

8

R13

R12

R11

6

10

5

6

10

5

6

10

5

2

4

3

6

10

5

D1

6

10

5

6

10

5

6

10

5

Battery

D56

D57

D58

D59

D60

J1

R1

R2

R19

R3

R4

C3

L1

C1

C2

Y1

4

1

3

R16

R17

C4

C8

C5

C6
C7

R20

U2

R21

R22
R23

C13

C12

L2

C10

JP15

C21

U7

R38

J2

R37

R36

C22

DS1

LINK

SPEED

FDX

DS3

DS2

R39
R40

R41

R35

C23

R34

U6

R33

R31

R32

D1

R66

C14

C11

C9

R7

R6

DS4

R42

J3

U18

R65

R67

R64

R29

R68

R69

R30

R24

C15 C16 R28 R27 R26

R25

C20

U5

JP12
JP13
JP14

R71

R70

R5

JP1

JP2

R72 JP3

JP4

JP5
JP6
JP7

JP8
JP9

JP10
JP11

U3 R8

R9

Q2

Q3

C91

C93

U1

R10

R1

1

R13

R12

R14

R15

C17

C18

C19

C92

C90

   JP7

4

3

2

1

R12

681 

W

R11

220 

W

R13

681 

W

485+

485–

6

7

termi-

nation

bias

bias

U23

JP7

2

1

6

5

6

5

Factory

Default

Downloaded from 

Elcodis.com

 

electronic components distributor

 

Содержание BL4S200

Страница 1: ...BL4S200 C Programmable Single Board Computer with Networking User s Manual 019 0171_D Downloaded from Elcodis com electronic components distributor...

Страница 2: ...ake changes and improvements to its products without providing notice Trademarks Rabbit RabbitCore and Dynamic C are registered trademarks of Digi International Inc RabbitNet is a trademark of Digi In...

Страница 3: ...Installing Dynamic C 19 2 4 Starting Dynamic C 20 2 5 Run a Sample Program 20 2 5 1 Troubleshooting 20 2 6 Run a Wi Fi Sample Program BL5S220 only 21 2 7 Run a ZigBee Sample Program BL4S230 only 22 2...

Страница 4: ...rter Outputs 123 4 4 8 SRAM Use 131 Chapter 5 Using the Ethernet TCP IP Features 132 5 1 TCP IP Connections 132 5 2 TCP IP Sample Programs 134 5 2 1 How to Set IP Addresses in the Sample Programs 134...

Страница 5: ...eripheral Cards 181 Appendix C Demonstration Board 182 C 1 Connecting Demonstration Board 183 C 2 Demonstration Board Features 184 C 2 1 Pinout 184 C 2 2 Configuration 184 Appendix D Rabbit RIO Resour...

Страница 6: ...le board computer that incorporates the powerful Rabbit 4000 or Rabbit 5000 microprocessor flash memory options static RAM digital I O ports A D converter inputs D A converter outputs RS 232 RS 485 se...

Страница 7: ...be programmed remotely using the Remote Program Update library with Dynamic C v 10 54 or later See Application Note AN421 Remote Program Update for more information NOTE BL4S200 Series single board c...

Страница 8: ...k connectivity configurable I O high current outputs RS 232 and RS 485 serial I O and an A D converter These Getting Started instructions included with the Tool Kit will help you get your BL4S200 up a...

Страница 9: ...3 3 Optional Add Ons Rabbit has available a Mesh Network Add On Kit and additional tools and parts to help you to make your own wiring assemblies with the friction lock connectors Mesh Network Add On...

Страница 10: ...one peripheral card Distances between a master processor unit and peripheral cards can be up to 10 m or 33 ft The following low cost peripheral cards are currently available Digital I O A D converter...

Страница 11: ...mmunity The BL4S200 series of single board computers meets the following EN55024 1998 immunity standards EN61000 4 3 Radiated Immunity EN61000 4 4 EFT EN61000 4 6 Conducted Immunity Additional shieldi...

Страница 12: ...of the end user to use proper ESD precautions to prevent ESD damage to the BL4S200 Safety All inputs and outputs to and from the BL4S200 series of single board computers must not be connected to volta...

Страница 13: ...the FCC ID can not be used on the final product In these circum stances the systems integrator or end user will be responsible for re evaluating the end device including the transmitter and obtaining...

Страница 14: ...odule 1 6 2 Industry Canada Labeling FCC ID VCB E59C4472 This device complies with Part 15 of FCC rules Operation is subject to the following two conditions 1 this device may not cause harmful interfe...

Страница 15: ...ands Regulatory Marking The equipment shall be marked where applicable in accordance with CEPT ERC Rec ommendation 70 03 or Directive 1999 5 EC whichever is applicable Where this is not applicable the...

Страница 16: ...62 C47 JP7 RS485 JP9 JP8 K B 5 V G N D 3 3 v K A 5 V G N D 3 3 V C52 C55 C57 C61 C56 C60 C 5 0 C 5 1 C49 C59 C54 C48 C53 C58 U7 C 3 8 C 3 9 C 4 0 C21 C27 C33 C17 C19 C25 C 1 4 R4 R2 C 1 2 C13 U5 U6 C1...

Страница 17: ...or other operating systems are available online at www ftdichip com Drivers VCP htm RESET S1 S2 R1 CORE 3 3 V DS1 DS2 J9 J10 J11 J12 J8 J7 J6 J5 J4 J3 J2 J1 RCM1 R7 R8 R9 R10 C63 JP4 JP5 JP6 JP3 C62 C...

Страница 18: ...plug assembly into the slot at the top of the AC adapter as shown in Figure 4 then press down on the spring loaded clip below the plug assembly to allow the plug assembly to click into place Release...

Страница 19: ...n icon for the docu mentation menu is placed on the workstation s desktop Double click this icon to reach the menu If the icon is missing create a new desktop icon that points to default htm in the do...

Страница 20: ...be connected to the wrong COM port a connection may be faulty or the target sys tem may not be powered up First check to see that the red power LED next to header J5 is lit If the LED is lit check bo...

Страница 21: ...amic C STDIO window will display Starting scan and will display a list of access points ad hoc hosts as shown here The following fields are shown in the Dynamic C STDIO window Channel the channel the...

Страница 22: ...If you set the ID you must write it to non volitile memory WR and then reset the network software NR ATOP Read the operating PAN ID ATMY Read the current network address Will be 0xFFFE if we are not...

Страница 23: ...e program ran fine you are now ready to go on to explore other BL4S200 features and develop your own applications When you start to develop your application run USERBLOCK_READ_WRITE C in the SAMPLES U...

Страница 24: ...5 shows these Rabbit based subsystems designed into the BL4S200 Figure 5 BL4S200 Subsystems SRAM microSD Card Program Flash SRAM Network 32 kHz osc 58 98 MHz osc optional RabbitCore Module Battery Bac...

Страница 25: ...n c GND HOUT1 2 7 8 3 9 4 6 1 5 10 High Current Outputs KD DIO24 DIO26 DIO28 DIO30 GND DIO25 DIO27 DIO29 DIO31 2 7 8 3 9 4 6 1 5 10 General Purpose I O KC DIO16 DIO18 DIO20 DIO22 GND DIO17 DIO19 DIO2...

Страница 26: ...upport Ethernet con nections Be careful to make your Ethernet connection to the Ethernet jack on the Rab bitCore module note that the wireless BL5S220 and BL4S230 models do not have an Ethernet port T...

Страница 27: ...The inputs are factory configured to be pulled up to 5 V but they can also be pulled up to K or DCIN or pulled down to 0 V in banks by changing a jumper as shown in Figure 7 Figure 7 BL4S200 Configura...

Страница 28: ...ately 1 40 V Anything below this value is a logic 0 and anything above 1 90 V is a logic 1 The con figurable I O are each fully protected over a range of 0 V to 36 V and can handle short spikes from 5...

Страница 29: ...ble 4 BL4S200 Sinking Outputs Digital Inputs Kx Configuration Header Pins Jumpered Pulled Up Pulled Down DIO0 DIO7 KA on J10 JP9 1 2 I O pulled up to Kx DIO8 DIO15 KB on J9 JP8 3 4 Do not use these op...

Страница 30: ...n since sufficient Rabbit RIO resources are not available to support their use for specialized outputs Appendix D provides further details on the blocks and pins associated with each Rabbit RIO chip t...

Страница 31: ...the pin s selected from one to four PWM outputs could operate based on the same counter block Remember to set the corresponding jumper Table 4 so that the I O for that bank are pulled up to the select...

Страница 32: ...ge or either edge as triggers to start end the count This feature is configured using the setCounter function call A more extensive use of the timing abilities of the BL4S200 configurable I O can be r...

Страница 33: ...tput is normally set up to start when triggered by an event and may be set up so that the leading and trailing edges of several PWM outputs are aligned as long as the all the PWM outputs are on the sa...

Страница 34: ...outputs are disabled that is at a high impedance tristate Each bank of four high current output has its own K supply as shown in Table 6 When wiring the high current outputs keep the distance to the p...

Страница 35: ...with _H do not confuse these function calls with their configurable I O counterparts The digOutConfig_H function call configures the high current outputs as two state outputs with either sinking or so...

Страница 36: ...ng at 3 3 1 RS 232 The BL4S200 RS 232 serial communication is supported by an RS 232 transceiver This transceiver provides the voltage output slew rate and input voltage immunity required to meet the...

Страница 37: ...3 C23 C29 C35 C22 C28 C34 U8 C44 C45 C46 C24 C30 C36 R117 RP1 U4 C37 RP2 R5 R121 L2 L3 BT1 C31 C32 U3 C15 C10 U2 C11 C9 C8 U1 R116 R3 R118 C18 C20 C26 JP1 JP2 D2 D3 L1 D4 C1 C2 C3 C4 C6 TERM TERM KC 5...

Страница 38: ...ng The programming port is used to start the BL4S200 in a mode where the BL4S200 will download a program from the port and then execute the program The programming port transmits information to and fr...

Страница 39: ...RJ 45 Ethernet Port Pinout Three LEDs are placed next to the RJ 45 Ethernet jack on the BL4S200 model one to indicate Ethernet link activity LINK ACT one to indicate when the BL4S200 is con nected to...

Страница 40: ...attenuator and the capacitors filter noise pulses from the A D converter inputs Figure 15 Buffered A D Converter Inputs The A D converter chip can only accept positive voltages By pairing the analog...

Страница 41: ...V 10 V 20 V 2 0 10 V 5 V 10 V 4 0 5 V 2 5 V 5 V 5 0 4 V 2 V 4 V 8 0 2 5 V 1 25 V 2 5 V 10 0 2 V 1 V 2 V 16 0 1 25 V 0 625 V 1 25 V 20 0 1 V 0 5 V 1 V 4 20 mA operation is available with an amplifier g...

Страница 42: ...lds calibra tion constants based on mode channel and gain Other factors affecting the calibration must be taken into account by calibrating using the same mode and gain setup as in the intended use Sa...

Страница 43: ...Figure 17 D A Converter Outputs Table 9 summarizes the jumper settings to configure each D A converter output Note that the software configuration requires both channels to be configured the same way...

Страница 44: ...puts are factory calibrated and the calibration constants are stored in the user block 3 5 1 D A Converter Calibration To get the best results form the D A converter it is necessary to calibrate each...

Страница 45: ...al inputs to provide single ended unipolar or differential measurements 0 V or to provide single ended bipolar measurements V voltage range 9 Because the D A converter chip operation is con figured by...

Страница 46: ...the BL4S200 is in the Program Mode Refer to the Rabbit 4000 Microprocessor User s Manual and the Rabbit 5000 Microprocessor User s Manual for more information on the programming port and the programm...

Страница 47: ...reduce radiated emissions The clock doubler is disabled with a simple configuration macro as shown below NOTE Do not disable the clock doubler on the Wi Fi model BL5S220 since Wi Fi operations depend...

Страница 48: ...the Defines tab from the Dynamic C Options Project Options menu 2 Normal spreading is the default and usually no entry is needed If you need to specify nor mal spreading add the line ENABLE_SPREADER...

Страница 49: ...roSD Cards The RabbitCore module on the BL4S200 model supports a removable microSD Card up to 1 GB to store data and Web pages The microSD Card is particularly suitable for mass storage applications b...

Страница 50: ...tion program detects a new card the file system can be opened These steps allow the microSD Card to be installed or removed without affecting either the program which continues to run on the RCM4300 m...

Страница 51: ...an be developed in RAM but cannot run stand alone from RAM after the programming cable is disconnected Standalone applications can only run from flash memory NOTE Do not depend on the flash memory sec...

Страница 52: ...kpoints Set breakpoints that can disable interrupts Single stepping Step into or over functions at a source or machine code level C OS II aware Code disassembly The disassembly window displays address...

Страница 53: ...over an entire file since you may overwrite an update of course you may copy over any programs you have written Once you are sure the new patch or update works entirely to your satisfaction you may re...

Страница 54: ...mple program To run a sample program open it with the File menu if it is not still open then compile and run it by pressing F9 The BL4S200 must be in Program mode see Section 3 7 USB Programming Cable...

Страница 55: ...C57 C61 C56 C60 C50 C51 C49 C59 C54 C48 C53 C58 U7 C38 C39 C40 C21 C27 C33 C17 C19 C25 C14 R4 R2 C12 C13 U5 U6 C16 C41 C42 C43 C23 C29 C35 C22 C28 C34 U8 C44 C45 C46 C24 C30 C36 R117 RP1 U4 C37 RP2 R5...

Страница 56: ...3 C29 C35 C22 C28 C34 U8 C44 C45 C46 C24 C30 C36 R117 RP1 U4 C37 RP2 R5 R121 L2 L3 BT1 C31 C32 U3 C15 C10 U2 C11 C9 C8 U1 R116 R3 R118 C18 C20 C26 JP1 JP2 D2 D3 L1 D4 C1 C2 C3 C4 C6 TERM TERM KC 5 V G...

Страница 57: ...can keep the message on the screen indefinitely by pressing the button repeatedly HIGH CURRENT OUPUTS HOUT0 HOUT3 CONNECTOR J3 BL4S200 RESET S1 S2 R1 CORE 3 3 V DS1 DS2 J9 J10 J11 J12 J8 J7 J6 J5 J4 J...

Страница 58: ...tion windows that are synchronized This guarantees that we always catch the begin edge first on a quickly repeating wave form This was done to create an interactive element to this sample program but...

Страница 59: ...C17 C19 C25 C14 R4 R2 C12 C13 U5 U6 C16 C41 C42 C43 C23 C29 C35 C22 C28 C34 U8 C44 C45 C46 C24 C30 C36 R117 RP1 U4 C37 RP2 R5 R121 L2 L3 BT1 C31 C32 U3 C15 C10 U2 C11 C9 C8 U1 R116 R3 R118 C18 C20 C2...

Страница 60: ...0 model NOTE For the sequence that does yield parity errors the errors won t occur for each byte received This is because certain byte patterns along with the stop bit will appear to generate the corr...

Страница 61: ...strates a simple RS 485 transmission of lower case letters to a slave The slave will send back converted upper case letters back to the master BL4S200 and display them in the STDIO window Use SLAVE C...

Страница 62: ...7 8 on header JP4 Then connect a current meter in series with the power supply connected to one of pins AIN0 AIN3 and AGND then compile and run the sample program and follow the instructions in the D...

Страница 63: ...channels using a sliding window The voltage is calculated from coefficients read from the reserved user block Before you compile and run this sample program connect the power supply which should be O...

Страница 64: ...how to output a current that can be read with an ammeter The output current is computed with using the calibration constants that are stored in the reserved user block The D A converter circuit is set...

Страница 65: ...both headers JP3 and JP6 bipolar Now connect a voltmeter across one of the D A converter outputs then compile and run the sample program and follow the instructions in the Dynamic C STDIO window DAC_...

Страница 66: ...a selected page The sample program prints out a single line for a page if all bytes in the page are set to the same value Otherwise it prints a hex ASCII dump of the page This utility works with the m...

Страница 67: ...the BL4S200 The functions in the BLxS2xx LIB library are described in Section 4 4 BL4S200 Function Calls RN_CFG_BLS2xx LIB used to configure the BL4S200 for use with RabbitNet peripheral boards TCPIP...

Страница 68: ...ion brdInit void brdInit void FUNCTION DESCRIPTION Call this function at the beginning of your program This function initializes the system I O ports The ports are initialized according to Table A 3 i...

Страница 69: ...ALSO brdInit digIn digInBank digIn int digIn int channel FUNCTION DESCRIPTION Reads the state of a channel set to any form of digital input functionality PARAMETERS channel configurable I O channel s...

Страница 70: ...bank of digital inputs EINVAL invalid parameter value EPERM pin functionality does not permit this operation SEE ALSO brdInit digIn setDigIn Data Bits Bank 0 Bank 1 Bank 2 Bank 3 LSB D0 DIO0 DIO8 DIO1...

Страница 71: ...handle for the ISR handler to service this interrupt RETURN VALUE 0 success EINVAL invalid parameter value EPERM pin type does not permit this function EACCES resource needed by this function is not a...

Страница 72: ...also known as quadrature or Q channel_index channel to use as index input 1 if not used NOTE The Quadrature Decoder count may still be reset by existing or new synch signals set up on the same block...

Страница 73: ...e with count stopping on any match event edge edge setting macro for the up count event BL_EDGE_RISE up count on rising edge BL_EDGE_FALL up count on falling edge BL_EDGE_BOTH up count on either edge...

Страница 74: ...ositive number Mode Conflict the positive number is a bitmap that corresponds to the pins on a particular block of a RIO chip that have not been configured to support this function call Appendix D pro...

Страница 75: ...he end event input mode mode macro for the counter timer BL_CNT_RUN continuous count mode BL_CNT_BEGIN_END start count on begin event continue to count until end event detected BL_CNT_TIL_END count un...

Страница 76: ...e prescaled clock BL_SAVE_LIMIT save current limit register value other wise limit set to 0xFFFF RETURN VALUE 0 success EINVAL invalid parameter value EPERM pin type does not permit this function EACC...

Страница 77: ...s EINVAL invalid parameter value SEE ALSO brdInit setCounter setDecoder setCapture resetCounter getBegin int getBegin int channel word begin FUNCTION DESCRIPTION Reads the current value of the begin r...

Страница 78: ...lid parameter value SEE ALSO brdInit setCapture resetCounter resetCounter int resetCounter int channel FUNCTION DESCRIPTION Resets the current count of the counter register within the counter block ho...

Страница 79: ...s new value will take effect on the next counter overflow or by resetting the counter via the resetCounter function call PARAMETERS channel a channel that uses the desired counter block limit new valu...

Страница 80: ...that is on the block that will have its synch set source source of the synch signal 1 to use the RIO chip s Global Synch signal or input capable channel to use as an external synch signal edge edge o...

Страница 81: ...un before calling this function SEE ALSO brdInit setDigOut int setDigOut int channel int state FUNCTION DESCRIPTION Configures the output channel as a simple digital output The output state of the cha...

Страница 82: ...igured by the setDigOut function call to be a sinking digital output PARAMETERS channel digital output channel 0 31 DIO0 DIO31 state set output to one of the following states 0 connects the load to GN...

Страница 83: ...DIO8 DIO15 2 DIO16 DIO23 3 DIO24 DIO31 data data value to be written to the specified digital output bank the data format and bitwise value are as follows Bitwise value 0 connects the load to GND 1 pu...

Страница 84: ...0 29 DIO0 DIO29 frequency PWM frequency in Hz should be from 2 Hz to 50 kHz use 1 to preserve the existing frequency on the RIO block duty PWM duty cycle should be from 0 to 100 use 1 and bind parame...

Страница 85: ...Conflict the positive number is a bitmap that corresponds to the pins on a particular block of a RIO chip that have not been configured to support this function call Appendix D provides the details of...

Страница 86: ...set will produce the smallest offset possible which is one count If you must have a zero offset use setPWM instead of setPPM duty PPM duty cycle should be from 0 to 100 use 1 and bind_ duty parameter...

Страница 87: ...function is not available EFAULT internal data fault detected positive number Mode Conflict the positive number is a bitmap that corresponds to the pins on a particular block of a RIO chip that have...

Страница 88: ...rn call setOffset and setDuty to reset the duty cycle and offset to the desired value NOTE Configurable I O channels DIO30 and DIO31 do not support PWM PPM functionality and cannot be used with this f...

Страница 89: ...ort PWM PPM functionality and cannot be used with this function call PARAMETERS channel channel that is getting its duty cycle set 0 29 DIO0 DIO29 duty duty cycle of the PWM PPM output should be from...

Страница 90: ...function call PARAMETERS channel channel that is getting its offset set 0 29 DIO0 DIO29 duty PPM offset should be from 0 to 100 an offset above 100 0 will be set to 100 0 NOTE A zero offset will prod...

Страница 91: ...ess EINVAL invalid parameter value EPERM channel function does not permit this operation SEE ALSO brdInit setPWM setPPM pulseEnable pulseEnable int pulseEnable int channel FUNCTION DESCRIPTION Enables...

Страница 92: ...annels HOUT0 HOUT7 as sinking or sourcing outputs Each bit corresponds to one of the following high current outputs Bit 7 high current output channel HOUT7 Bit 6 high current output channel HOUT6 Bit...

Страница 93: ...l to one of the following output states depending on how the output was configured by the digOutConfig_H function call Sinking configuration 0 connects the load to GND 1 puts the output in a high impe...

Страница 94: ...esponds to one of the following high current outputs Bit 7 high current output channel HOUT7 Bit 6 high current output channel HOUT6 Bit 5 high current output channel HOUT5 Bit 4 high current output c...

Страница 95: ...sets a given channel to one of the following output states as long as it has been enable as a tristate output by the digOutTriStateConfig_H function call Tristate configuration 0 connects the load to...

Страница 96: ...be from 0 to 100 use 1 and bind parameter to use bound edge to set the duty cycle a duty cycle above 100 0 will be set to 100 0 mode sets the normal or begin state and the pulsed state of the PWM out...

Страница 97: ...ode Conflict the positive number is a bitmap that corresponds to the pins on a particular block of a RIO chip that have not been configured to support this function call Appendix D provides the detail...

Страница 98: ...tPPM_H duty PPM duty cycle should be from 0 to 100 use 1 and bind_ duty parameter to use bound edge to set the duty cycle a PPM duty cycle above 100 0 will be set to 100 0 set to 25 duty in range 75 1...

Страница 99: ...his function is not available EFAULT internal data fault detected positive number Mode Conflict the positive number is a bitmap that corresponds to the pins on a particular block of a RIO chip that ha...

Страница 100: ...cycle and offset values to drift If this drift is of concern call setOffset_H and setDuty_H to reset the duty cycle and offset to the desired value PARAMETERS channel all channels on the same RIO chi...

Страница 101: ...PPM PARAMETERS channel channel that is getting its duty cycle set 0 7 HOUT0 HOUT7 duty duty cycle of the PWM PPM output should be from 0 to 100 a duty cycle above 100 0 will be set to 100 0 RETURN VAL...

Страница 102: ...set 0 7 HOUT0 HOUT7 duty PPM offset should be from 0 to 100 an offset above 100 0 will be set to 100 0 NOTE A zero offset will produce the smallest offset possible which is one count If you must have...

Страница 103: ...nnel channel that is on the block that will have its synch set edge edge of the synch signal 0 will disable the synch BL_EDGE_RISE synchronize event on rising edge BL_EDGE_FALL synchronize event on fa...

Страница 104: ...I O channel to bind to ISR 0 31 io BL_INPUT_BLOCK for input block BL_OUTPUT_BLOCK for output block ier bit mask of interrupt s this handler services BL_IER_DQE decrement quadrature end BL_IER_IIB incr...

Страница 105: ...put channel to bind to ISR 0 7 ier bit mask of interrupt s this handler services BL_IER_DQE decrement quadrature end BL_IER_IIB increment inphase begin BL_IER_ROLL_D counter rollover on decrement BL_I...

Страница 106: ...bling the ISR can be done by calling enableISR with a zero for the enable parameter PARAMETERS isr_handle index to the desired ISR ier bit mask of interrupts this handler services bit positions match...

Страница 107: ...o disables the ISR RETURN VALUE 0 success EINVAL invalid parameter given SEE ALSO addISR addISR_H setIER tickISR tickISR void tickISR void FUNCTION DESCRIPTION Polls the RIO chip s for ISR events if i...

Страница 108: ...l and Technical Note 213 Rabbit Serial Port Software Use the following function calls with the BL4S200 serMode int serMode int mode FUNCTION DESCRIPTION This function call sets the serial interfaces u...

Страница 109: ...the byte that is transmitted is detected in the receive data buffer Block data mode disable the transmitter after the same number of bytes transmitted are detected in the receive data buffer RETURN VA...

Страница 110: ...erter internal channel 7 AIN7 biased by D A converter internal channel 7 When the differential mode is selected this function call configures both the selected channel and its differential mate The di...

Страница 111: ...pair The values are as follows SE0_MODE single ended unipolar 0 20 V SE1_MODE single ended bipolar 10 V DIFF_MODE differential bipolar 20 V mAMP_MODE 4 20 mA operation RETURN VALUE 0 success BL_SPIBUS...

Страница 112: ...recommended when calibrating a channel PARAMETERS channel analog input channel number 0 to 7 corresponding to AIN0 AIN7 opmode the mode of operation for the specified channel Use one of the following...

Страница 113: ...e RETURN VALUE 0 success EINVAL invalid parameter ERR_ANA_CALIB error writing calibration constants SEE ALSO brdInit anaInConfig anaIn anaInmAmps anaInDiff anaInVolts Gain Code Macro Voltage Range Sin...

Страница 114: ...0 to 7 corresponding to AIN0 AIN7 gaincode the gain code of 0 to 7 use a gain code of 4 for 4 20 mA operation channel Single Ended Differential 4 20 mA 0 AIN0 AIN0 AIN1 AIN0 1 AIN1 AIN1 2 AIN2 AIN2 A...

Страница 115: ...ART or less to indicate an error condition A D converter operation errors will not create run time error BL_SPIBUSY BL_TIMEOUT BL_OVERFLOW BL_WRONG_MODE System errors can create run time error unless...

Страница 116: ...er block will be read to get the calibration constants for the new gain value 2 The D A converter will be written to bias the A D converter input circuit for proper opera tion The D A converter access...

Страница 117: ...this channel gain BL_OVERFLOW A D converter overflow BL_SPIBUSY shared SPI port is already in use BL_TIMEOUT A D converter timeout BL_WRONG_MODE A D converter is in wrong mode run anaInConfig System...

Страница 118: ...iven channel has changed from the previous cycle the user block will be read to get the calibration constants for the new gain value PARAMETERS channel the analog input channel number 0 2 4 6 as shown...

Страница 119: ...this channel gain BL_OVERFLOW A D converter overflow BL_SPIBUSY shared SPI port is already in use BL_TIMEOUT A D converter timeout BL_WRONG_MODE A D converter is in wrong mode run anaInConfig System e...

Страница 120: ...esponding to the current on the analog input channel or a value of BL_ERRCODESTART or less to indicate an error condition A D converter operation errors will not create run time error BL_NOT_CAL A D c...

Страница 121: ...tables to determine cmd cmd 0x80 gain_code 4 channel_code D7 D6 D4 D3 D0 1 gain_code channel_code gain_code Multiplier 0 1 1 2 2 4 3 5 4 8 5 10 6 16 7 20 channel_code Differential Input Lines channel_...

Страница 122: ...ons to the A D converter channel_code listed above RETURN VALUE A value corresponding to the voltage on the analog input channel which will be either in the range 20480 2047 or an error code of BL_ERR...

Страница 123: ...d the correct configuration of the A D converter would be affected if the D A converter configura tion was changed later PARAMETERS polarity sets the output configuration polarity as follows DAC_UNIPO...

Страница 124: ...hronous mode when a value is written to it It is called internally by anaInConfig to strobe the D A converter offsets when the D A converter is in the synchronous mode but its normal use in programs s...

Страница 125: ...er power off mode BL_HIGH_Z 0 high output impedance BL_OHM100 1 100 k to GND BL_OHM2_5 2 2 5 k to GND RETURN VALUE 0 success EINVAL invalid parameter SEE ALSO anaOut anaOutVolts anaOutmAmps CAUTION Do...

Страница 126: ...0 1 corresponding to AOUT0 AOUT1 calib_index index used to go to the proper location in the lookup table for writing the calibration data 0 0 10 V calibration data 1 10 V calibration data 2 4 20 mA c...

Страница 127: ...output channel 0 1 corresponding to AOUT0 AOUT1 rawdata data value corresponding to the voltage desired on the output channel 0 4095 If a value larger than 4095 is given the channel will be set to ma...

Страница 128: ...the correct data values PARAMETERS ch the D A converter output channel 0 1 corresponding to AOUT0 AOUT1 voltage the voltage desired on the output channel RETURN VALUE 0 success BL_SPIBUSY SPI port bu...

Страница 129: ...te the correct data values PARAMETERS ch the D A converter output channel 0 1 corresponding to AOUT0 AOUT1 current the current desired on the output channel valid range is 4 20 mA RETURN VALUE 0 succe...

Страница 130: ...ng whether a strobe needs to follow anaOut in _bias_adc so any mode change is detected here not relying on that mode to only be changed through the high level anaOutConfig function call PARAMETER cmd...

Страница 131: ...n the update is 100 complete This assures the integrity of the data in case a reset or a power failure occurs during the update process At power on the application program uses the active copy of the...

Страница 132: ...nd a hub or an RJ 45 crossover CAT 5 6 Ethernet cable The CAT 5 6 Ethernet cables and Ethernet hub are available from Rabbit in a TCP IP tool kit More information is available at www rabbit com 1 Conn...

Страница 133: ...grounding the board reset input at pin 9 on screw terminal header J2 When working with the BL4S200 the green LNK light is on when a program is running and the board is properly connected either to an...

Страница 134: ...MY_NAMESERVER macros in each program 2 You can leave TCPCONFIG at the usual default of 1 which will set the IP configurations to 10 10 6 100 the netmask to 255 255 255 0 and the nameserver and gateway...

Страница 135: ...r the Ethernet interface you intend to use e g TCP IP Xircom Credit Card Network Adapter and click on the Properties button Depending on which version of Windows your PC is running you may have to sel...

Страница 136: ...light does not light you may not have a crossover cable or if you are using a hub perhaps the power is off on the hub The next step is to ping the board from your PC This can be done by bringing up th...

Страница 137: ...CP IP connection should be closed and a digital output to toggle an LED to indicate that there is an active connection Follow the instructions included with the sample program Run the Telnet program o...

Страница 138: ...A variety of Wi Fi hard ware exists from wireless access points WAPs various Wi Fi access devices with PCI PCMCIA CompactFlash USB and SD MMC interfaces and Wi Fi devices such as Web based cameras and...

Страница 139: ...e chip set in the interface allow a host program to override the default configurations and execute functions implemented on the interface cards for example scanning for hosts and access points 6 1 2...

Страница 140: ...n the module to your PC 4 Power must be applied to the BL5S220 Refer to Chapter 2 Getting Started if you need further information on these steps To run a sample program open it with the File menu then...

Страница 141: ...22 JP20 JP17 JP1 3 R19 R9 RX57 RX55 RX97 RX49 UX3 3 UX3 1 RX8 9 UX3 UX3 7 UX4 2 UX4 1 RX6 3 RX6 5 RX6 1 RX59 R26 R25 Q1 C15 C19 C20 U3 C18 C17 JP16 JP6 JP5 JP12 JP4 JP3 JP14 JP8 JP7 JP18 JP9 JP10 C16...

Страница 142: ...ble USB port to program the BL5S220 You will need either an access point for an existing Wi Fi network that you are allowed to access and have a PC or notebook connected to that network infrastructure...

Страница 143: ...sary to run the sample programs you will likely need to change some of the Wi Fi settings Network Parameters These lines contain the IP address netmask nameserver and gateway parameters define _PRIMAR...

Страница 144: ...select the network interface card used you intend to use e g TCP IP Xircom Credit Card Network Adapter and click on the Proper ties button Depending on which version of Windows your PC is running you...

Страница 145: ...point SSID macro for the infrastructure mode as explained in Section 6 3 Dynamic C Wi Fi Configurations Ad Hoc Mode Set the IP address and netmask for your wireless enabled PC or notebook as describe...

Страница 146: ...for the BL5S220 in Japan 2 Country or region is set via the 802 11d feature of the access point This option uses beacons from an access point to configure the BL5S220 country or region automati cally...

Страница 147: ...he regulations for the country where your system incorporating the BL5S220 will be deployed for any other requirements Before you compile and run this sample program verify that the access point has t...

Страница 148: ...l subnet Now press F9 to compile and run the sample program When prompted in the Dynamic C STDIO window type s for static configuration or d for DHCP WIFIMULTIPLEAPS C demonstrates changing access poi...

Страница 149: ...c Wi Fi network This sample program uses some predefined macros The first macro specifies the default TCP IP configuration from the Dynamic C LIB Rabbit4000 TCPIP TCP_ CONFIG LIB library define TCPCON...

Страница 150: ...D of your access point as a C style string for example or use an empty string to associate with the strongest BSS available Alternatively you may create your own CUSTOM_CONFIG LIB library modeled on t...

Страница 151: ...imilar to PINGLED C but it also displays receiver transmitter statistics in the Dynamic C STDIO window Before you compile and run this sample program change PING_WHO to the host you want to ping You m...

Страница 152: ...same key TIP For an initial test it may be easier to use the 64 hex digit form of the key rather than the ASCII passphrase A passphrase requires considerable computation effort which delays the startu...

Страница 153: ...itable pre shared key The key may be entered either as 64 hexadecimal digits or as an ASCII string of up to 63 characters TIP There is a good chance of typos since the key is long First enter the key...

Страница 154: ...cros specifically set up for Wi Fi applications with the BL5S220 TCPCONFIG 0 is not supported for Wi Fi applications These default IP address netmask nameserver and gateway network parameters are set...

Страница 155: ...ble encryption IFC_WIFI_ENCRYPTION indicates whether or not encryp tion is enabled The default encryption disabled is shown below define IFC_WIFI_ENCRYPTION IFPARAM_WIFI_ENCR_NONE The following encryp...

Страница 156: ...time If possible you should use IFC_WIFI_WPA_PSK_HEXSTR instead of IFC_WIFI_ WPA_PSK_PASSPHRASE to set the key Set WPA hexadecimal key IFC_WIFI_WPA_PSK_HEXSTR is a string of hexadecimal digits that ma...

Страница 157: ...sets the RTS threshold the frame size at which the RTS CTS mechanism is used This is sometimes useful on busy or noisy networks Its range is 0 to 2347 The default 2347 means no RTS CTS define IFC_WIF...

Страница 158: ...Fi interface is neither up nor down and must be brought up explicitly by calling either ifup IF_WIFI0 or ifconfig IF_WIFI0 You must bring the interface down when you configure Dynamic C at run time be...

Страница 159: ...Dynamic C Check the Rabbit Technical Bulletin Board and forums at www rabbit com support bb and at www rabbit com forums Use the Technical Support e mail form at www rabbit com support If the sample...

Страница 160: ...data rates and low power consumption A network of devices using the ZigBee proto col works via a self organizing mesh network that can be used for industrial control embedded sensors data collection...

Страница 161: ...n dard BL4S200 Tool Kit See section F 2 Digi XBee USB Configuration for more information on the Digi XBee USB device To run a sample program open it with the File menu if it is not still open then com...

Страница 162: ...C33 C17 C19 C25 C14 R4 R2 C12 C13 U5 U6 C16 C41 C42 C43 C23 C29 C35 C22 C28 C34 U8 C44 C45 C46 C24 C30 C36 R117 RP1 U4 C37 RP2 R5 R121 L2 L3 BT1 C31 C32 U3 C15 C10 U2 C11 C9 C8 U1 R116 R3 R118 C18 C2...

Страница 163: ...e Manager Ports on your PC if you need help in identifying the USB COM port 6 Any ZigBee devices discovered will be displayed in the Devices Discovered window to the right If the utility times out and...

Страница 164: ...for the BL4S230 to be a router Set XBEE_ROLE to NODE_TYPE_COORD NODE_TYPE_ROUTER or NODE_TYPE_ENDDEV to match your XBee s firmware define XBEE_ROLE NODE_TYPE_ROUTER NOTE Remember that the firmware lo...

Страница 165: ...dentifier define NODEID_STR RabbitXBee The XBee sample programs in the Dynamic C SAMPLES XBee folder illustrate the use of the XBee function calls AT_INTERACTIVE C This sample program shows how to set...

Страница 166: ...as explained in Section 7 2 1 Then compile and run this sample program on the BL4S230 Run the Windows GUI client on your PC Configure the GUI client XBEE_GPIO_GUI exe in the Dynamic C Utilities XBee...

Страница 167: ...ynamic C Help menu to get further assistance with Dynamic C Check the Rabbit Technical Bulletin Board and forums at www rabbit com support bb and at www rabbit com forums Use the Technical Support e m...

Страница 168: ...4S200 User s Manual 168 APPENDIX A SPECIFICATIONS Appendix A provides the specifications for the BL4S200 and describes the conformal coating Downloaded from Elcodis com electronic components distribut...

Страница 169: ...59 D60 J1 R1 R2 R19 R3 R4 C3 L1 C1 C2 Y1 4 1 3 R16 R17 C4 C8 C5 C6 C7 R20 U2 R21 R22 R23 C13 C12 L2 C10 JP15 C21 U7 R38 J2 R37 R36 C22 DS1 LINK SPEED FDX DS3 DS2 R39 R40 R41 R35 C23 R34 U6 R33 R31 R32...

Страница 170: ...ACT JP6 R32 C51 C49 C52 C54 C55 C39 C40 C43 C44 C46 C47 C53 C57 C64 C16 1 2 3 Y3 U9 C19 R18 Y2 C21 R20 R21 C30 U1 C29 C58 R11 R25 R24 C56 R22 R17 R23 R16 U10 R13 C18 Q1 C14 C4 C3 C28 C31 C45 C41 C42...

Страница 171: ...KB 512KB Backup Battery Renata CR2032 or equivalent 3 V lithium coin type 235 mA h standard socket mounted Configurable I O 32 individually software configurable I O channels may be configured as digi...

Страница 172: ...connectors two RabbitNet Micro Fit connectors seven polarized 2 5 with 3 mm pitch one polarized 2 7 with 3 mm pitch one polarized 2 2 with 3 mm pitch one polarized 2 3 with 3 mm pitch Programming por...

Страница 173: ...en adjacent boards An exclusion zone of 0 12 3 mm is rec ommended below the BL4S200 Figure A 2 shows this exclusion zone Figure A 2 BL4S200 Exclusion Zone A 1 2 Headers The BL4S200 has 3 mm Micro Fit...

Страница 174: ...nants over time Refer to the individual RabbitCore module s User s Manual for additional information on where the conformal coating was applied Any components in the conformally coated area may be rep...

Страница 175: ...O24 DIO31 1 2 Inputs pulled up to KD 3 4 Inputs pulled up to 5 V 5 6 Inputs pulled down to GND 7 8 Inputs pulled up to 3 3 V JP4 JP5 JP6 JP3 JP7 JP9 JP8 JP1 JP2 2 Battery J1 R1 R2 R19 R3 R4 C3 L1 C1 C...

Страница 176: ...as and termination resistors not connected JP8 DIO8 DIO15 1 2 Inputs pulled up to KB 3 4 Inputs pulled up to 5 V 5 6 Inputs pulled down to GND 7 8 Inputs pulled up to 3 3 V JP9 DIO0 DIO7 1 2 Inputs pu...

Страница 177: ...ut TXB RS 232 BL4S210 Serial Port B Inactive high PC5 Input RXB RS 232 BL4S210 Pulled up PC6 Output TXA Programming Port Serial Port A Low PC7 Input RXA Programming Port Pulled up PD0 PD1 Output ENET...

Страница 178: ...ed 5 V DC power supply is used to drive two regulated 3 3 V power supplies and 12 V power supplies used by the op amps driving the outputs A separate 3 3 V power supply is provided for the RabbitCore...

Страница 179: ...plies for other applications B 2 Batteries and External Battery Connections The SRAM and the real time clock on the BL4S200 modules have battery backup Power to the SRAM and the real time clock VRAM i...

Страница 180: ...the battery This step will minimize the current drawn by the real time clock oscillator circuit from the backup battery should the BL4S200 experience a loss of main power NOTE Remember to cycle the m...

Страница 181: ...current drawn at Vcc For example if the raw power supply input is 12 V and the Vcc supply at J7 draws 200 mA 641 mA will be available for DCIN Table B 1 DCIN Current Available at J7 in mA Based on Po...

Страница 182: ...S200 User s Manual 182 APPENDIX C DEMONSTRATION BOARD Appendix C explains how to use the Demonstration Board with the BL4S200 sample programs Downloaded from Elcodis com electronic components distribu...

Страница 183: ...3 V DS1 DS2 J9 J10 J11 J12 J8 J7 J6 J5 J4 J3 J2 J1 RCM1 R7 R8 R9 R10 C63 JP4 JP5 JP6 JP3 C62 C47 JP7 RS485 JP9 JP8 KB 5 V GND 3 3 v KA 5 V GND 3 3 V C52 C55 C57 C61 C56 C60 C50 C51 C49 C59 C54 C48 C53...

Страница 184: ...the outputs on screw terminal header J3 Figure C 2 Demonstration Board Pinout C 2 2 Configuration The pushbutton switches may be configured active high or active low via jumper settings on header JP15...

Страница 185: ...at V on screw terminal header J3 is available as V_ALT on screw terminal header J1 There is a potentiometer immediately above the V_ALT location to allow you to reduce the voltage from the V originall...

Страница 186: ...n the RIO chips are the counter timer blocks each RIO chip has eight counter timer blocks The BL4S200 boards have three RIO chips which gives a total of 24 blocks A given block is defined by both the...

Страница 187: ...0 0 0 DIO5 1 1 DIO6 2 2 DIO7 3 3 DIO8 3 0 2 0 DIO9 1 1 DIO10 2 2 DIO11 3 3 DIO12 5 0 4 0 DIO13 1 1 DIO14 2 2 DIO15 3 3 DIO16 2 0 0 0 2 DIO17 1 3 DIO18 1 0 1 2 DIO19 1 3 DIO20 2 0 2 2 DIO21 1 3 DIO22 3...

Страница 188: ...s that returned the Mode Conflict error code For example if you already configured DIO8 and DIO9 as Quadrature Decoder inputs then try to set DIO11 as a counter input the function call will return a M...

Страница 189: ...synchronization signal It would also allow synchro nization of a pulse capture response to a PWM based output pulse The last 4 configurable I O pins have nonshared RIO blocks available for both the in...

Страница 190: ...ns are made point to point A RabbitNet master port can only be connected directly to a peripheral card and the number of peripheral cards is limited by the number of available RabbitNet ports on the m...

Страница 191: ...following connectors are used Signal 0 1 friction lock connectors Power 0 156 friction lock connectors RabbitNet RJ 45 connector D A converter 8 channels of 0 10 V 12 bit D A conversion The following...

Страница 192: ...recommends a practical limit of 10 m 33 ft Connections between peripheral cards and masters are done using standard 8 conductor CAT 5 6 Ethernet cables Masters and peripheral cards are equipped with R...

Страница 193: ...d and relevant tables are filled in If the port is already initialized calling this function forces a re enumeration of all devices on that port Call this function first before using other RabbitNet f...

Страница 194: ...is connected to a master PARAMETER pna the physical node address indicated as a byte 7 6 2 bit binary representation of the port number on the master 5 4 3 Level 1 router downstream port 2 1 0 Level 2...

Страница 195: ...search criteria RN_MATCH_PORT match port bitmask RN_MATCH_PNA match physical node address RN_MATCH_HANDLE match instance reg 3 RN_MATCH_PRDID match id version reg 1 RN_MATCH_PRDREV match product revi...

Страница 196: ...ndle int regno char data int datalen FUNCTION DESCRIPTION Writes a string to the specified device and register Waits for results This function will check device information to determine that the perip...

Страница 197: ...e or rn_find to establish the handle regno command register number as designated by each device recdata pointer to the address of the string to read from the device datalen number of bytes to read 0 1...

Страница 198: ...is reset RETURN VALUE The status byte from the previous command 1 means that device information indicates the peripheral card is not connected to the master rn_sw_wdt int rn_sw_wdt int handle float ti...

Страница 199: ...r The peripheral card will soft reset if the timeout set by rn_sw_wdt expires This function will check device information to determine that the peripheral card is connected to a master PARAMETERS hand...

Страница 200: ...ster PARAMETERS handle address index to device information Use rn_device or rn_find to establish the handle count pointer to return the present count of the software watchdog timer The equivalent time...

Страница 201: ...nformation Use rn_device or rn_find to establish the handle retdata pointer to the return address of the communication byte A set bit indicates which error occurred This register is cleared when read...

Страница 202: ...dle retdata pointer to the return address of the communication byte A set bit indicates which error occurred This register is cleared when read 7 Data available and waiting to be processed MOSI master...

Страница 203: ...ed 0 Device 1 Router 0 No error 1 Communication error Use the function rn_comm_status to determine which error occurred Reserved for individual peripheral cards Reserved for individual peripheral card...

Страница 204: ...C librar ies in different ways Rabbit has tested the firmware associated with a particular version of Dynamic C for correct operation and only this version is included on the Dynamic C CD ROM do not u...

Страница 205: ...the BL4S230 configuration patterns for the sample programs via macros in the Dynamic C LIB Rabbit4000 XBee XBEE_API LIB library folder Channel mask defaults to 0x1FFE i e all 16 possible channels via...

Страница 206: ...ration tab click the Read button X CTU will now display the networking and I O parameters for the Digi XBee USB being used as the ZigBee coordinator Modem XBEE XB24 ZB Function Set ZIGBEE COORDINATOR...

Страница 207: ...Manual 207 with the BL4S230 but the general documentation about ZigBee and the use of AT com mands for the XBee and the XBee PRO RF modules is relevant Downloaded from Elcodis com electronic componen...

Страница 208: ...serial port without the Digi XBee USB connected the X CTU response to Test Query will be communi cation with modem OK but the modem type will be unknown and the firmware version will be blank If you...

Страница 209: ...configurable I O outputs 29 high current outputs 34 RS 485terminationandbias resistors 37 Digi XBee USB ZigBee co ordinator 205 conformal coating 174 connections Ethernet cable 133 connectivity tools...

Страница 210: ...es how to set 134 how to set PC IP address 135 J jumper configurations 175 JP1 digital input DIO00 DIO07 pullup pulldown configuration 175 JP2 digital input DIO08 DIO15 pullup pulldown configuration 1...

Страница 211: ...C 64 DAC_CAL_VOLTS C 64 DAC_MA_ASYNC C 64 DAC_MA_SYNC C 64 DAC_RD_CALDATA C 65 DAC_VOLT_ASYNC C 65 DAC_VOLT_SYNC C 65 digital I O DIGIN_BANK C 55 DIGIN C 55 DIGOUT_BANK C 56 DIGOUT C 56 HIGH_CURRENT_I...

Страница 212: ...time 158 specifications BL4S200 dimensions 169 electrical 171 exclusion zone 173 headers 173 temperature 171 spectrum spreader settings 48 status byte 203 subsystems 24 T tamper detection 49 TCP IP c...

Страница 213: ...6 RCM5400W Schematic www rabbit com documentation schemat 090 0266 pdf 090 0246 RCM4500W Schematic www rabbit com documentation schemat 090 0246 pdf 090 0252 USB Programming Cable Schematic www rabbit...

Отзывы: