background image

BL4S200 User’s Manual

186

A

PPENDIX

 D.  R

ABBIT

 RIO R

ESOURCE

A

LLOCATION

Appendix D provides the pin and block associations on the Rabbit
RIO chips with their corresponding I/O on the BL4S200 boards.
The main shared resource within 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 RIO number and
the block number. The tables in this appendix provide a quick
reference of which block is used by each input and/or output pin
on the BL4S200 board.

Содержание BL4S200

Страница 1: ...BL4S200 C Programmable Single Board Computer with Networking User s Manual 019 0171_E ...

Страница 2: ...national reserves the right to make 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 International Inc The latest revision of this manual is available on the Rabbit Web site www rabbit com for free unregistered download ...

Страница 3: ...s 17 2 2 1 Hardware Reset 18 2 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 8 Where Do I Go From Here 23 Chapter 3 Subsystems 24 3 1 BL4S200 Pinouts 25 3 1 1 Connectors 26 3 2 Digital I O 27 3 2 1 Configurable I O 27 3 2 2 High Current Digital...

Страница 4: ...erter Inputs 110 4 4 7 D A Converter 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 2 2 How to Set Up your Computer for Direct Connect 135 5 2 3 Run the PINGME C Demo 136 5 2 4 Running More Demo Programs With a Direct Connection 137 5 3 Where Do I Go...

Страница 5: ...ackup Battery 180 B 3 Power to Peripheral 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 Resource Allocation 186 D 1 Configurable I O Pin Associations 187 D 2 High Current Output Pin Associations 188 D 3 Interpreting Error Codes 188 Appendix E RabbitNet 190 E 1 G...

Страница 6: ... The BL4S200 is an advanced single 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 serial ports and Ethernet Wi Fi or ZigBee network connectivity 1 2 BL4S200 Features Rabbit 4000 or Rabbit 5000 microprocessor operating at up to 73 73 MHz Industry standa...

Страница 7: ...S200 and BL5S220 models may also 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 computers cannot be programmed via the RabbitLink Appendix A provides detailed specifications Table 1 BL4S200 Models Feature BL4S200 BL4S210 BL5S220 BL4S230 Microprocess...

Страница 8: ... Ethernet Wi Fi or ZigBee network 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 and running so that you can run the sample programs to explore its capabilities and develop your own applications Tool Kit Contents t Getting Started instructions t Dyna...

Страница 9: ...tive or authorized distributor 1 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 Kit Part No 101 1272 Digi XBee USB used as ZigBee coordinator XBee Series 2 RF module RF Interface module The XBee Series 2 RF module is installed on the RF Interface ...

Страница 10: ...orts each of which can sup port 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 D A converter Relay card Display Keypad interface Appendix E provides additional information on RabbitNet peripheral cards and the Rab bitNet protocol Visit our Web sit...

Страница 11: ... compliant have the CE mark Immunity 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 shielding or filtering may be required for a heavy industrial environment Emissions The BL4S200 series of single board computers meets the following emission standards EN55022 19...

Страница 12: ...L4S200 it is the responsibility 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 voltages exceeding SELV levels 42 4 V AC peak or 60 V DC The lithium backup battery circuit on the BL4S200 single board computer has been designed to protect the battery fro...

Страница 13: ...s no longer considered valid and 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 a separate FCC certification NOTE Any regulatory certification is voided if the RF shield on the RCM5400W module is removed 1 6 1 FCC Part 15 Class B The RCM5400W Rabb...

Страница 14: ...ating the RCM5400W RabbitCore module 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 interference and 2 this device must accept any interference received including interference that may cause undesired operation Caution Exposure to Radio Frequency Radiation To ...

Страница 15: ...rating in the same or adjacent bands 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 equipment shall be marked in accordance with the National Regulatory requirements Receiver Class Risk Assessment of Receiver Performance 1 Highly reliable SRD communic...

Страница 16: ... R8 R9 R10 C63 JP4 JP5 JP6 JP3 C62 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 C16 C 4 1 C 4 2 C 4 3 C23 C29 C35 C22 C28 C34 U8 C 4 4 C 4 5 C 4 6 C24 C30 C36 R117 RP1 U4 C37 RP2 R5 R 1 2 1 L2 L3 BT1 C 3 1 C 3 2 U3 C15 C10 U2 C11 C9 C8 U1 R116 R3 R11...

Страница 17: ...nstall the USB drivers Drivers for 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 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 ...

Страница 18: ...yle plugs Snap in the top of the 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 the clip to secure the plug assembly in the AC adapter Plug in the AC adapter The red LED next to the power connector at J5 should light up The BL4S200 is now ready to ...

Страница 19: ...alled along with Dynamic C and an 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 docs folder found in the Dynamic C installation folder The latest versions of all docu ments are always available for free unregistered download from our Web sites as wel...

Страница 20: ...tected the programming cable may 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 both ends of the programming cable to ensure that it is firmly plugged into the PC and the programming header on the BL4S200 with the marked col ored edge of the programm...

Страница 21: ...e program by pressing F9 The Dynamic 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 access point is on 1 11 Signal the signal strength of the access point MAC the hardware MAC address of access point Access Point SSID the SSID the access point is using...

Страница 22: ...D Set or read the current PAN ID 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 associated with a network ATSH Read the upper four bytes of the radio IEEE address ATSL Read the lower four bytes of the radio IEEE address ATNI Set or read the Node Id...

Страница 23: ... rabbit com support If the sample 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 UserBlock folder to save the factory calibration constants before you run any other sample programs in case you inadvertently write over them while running another sampl...

Страница 24: ... Voltages Circuit Memory Figure 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 Backup Circuit RABBIT 4000 5000 D A Converter A D Converter RabbitNet RS 485 RS 232 Data Register High Current Outputs Data Register Configurable I O RABBIT RIO x3 ...

Страница 25: ... K1 HOUT2 n c K1 HOUT0 GND HOUT3 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 DIO21 DIO23 2 7 8 3 9 4 6 1 5 10 General Purpose I O 1 3 4 2 n c GND n c RAW 2 7 8 3 9 4 n c 485 GND PC5_RXB GND 485 GND PC4_TXB 6 1 5 10 Serial Ports E and F are not avail...

Страница 26: ...rds The RabbitNet jacks do not support 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 Table 2 lists Molex connector part numbers for the crimp terminals and housings needed to assemble male Micro Fit connector assemblies for use with their female counterp...

Страница 27: ...ing the setDigOut function call 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 Configurable I O DIO0 DIO31 CAUTION Do not simultaneously jumper more than one setting on a particular jumper header JP9 JP8 JP1 and JP2 when configuring a bank of configurable ...

Страница 28: ... switching threshold is approximately 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 V to 40 V NOTE If the inputs are pulled up to Kx the voltage range over which the digital inputs are protected changes to 5 V Kx to 36 V Figure 8 BL4S200 Digital Input...

Страница 29: ...ns for Sinking Digital Output Table 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 options for a sinking output DIO16 DIO23 KC on J1 JP1 5 6 DIO24 DIO31 KD on J2 JP2 7 8 CAUTION Do not simultaneously jumper more than one setting on a particular jumper h...

Страница 30: ...se their outputs are latch driven 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 to facilitate configuring each block consistently and to identify misconfigured pins when a software function call returns a Mode Conflict error code Table 5 Counter Tim...

Страница 31: ...eriod or frequency Depending on 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 selected voltage The output voltage swing will be from 0 to the voltage you selected The sample program PWM C in the DIO subdirectory in SAMPLES BLxS2xx shows how to set up a...

Страница 32: ...sing the rising edge fall ing edge 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 realized through the event capture function call setCapture Here the count of a particular clock cycle is noted at the start of the event and at the end of the event so ...

Страница 33: ...remainder of the period A PWM output 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 same block of a particular Rabbit RIO chip A PPM ouput is similar to a PWM output except it is shifted by an offset relative to the event that triggered the start of the ...

Страница 34: ... or as an H bridge driver When the BL4S200 is first powered up or reset all the 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 power supply as short as possible Table 6 BL4S200 High Current Outputs High Current Outputs Kx Connector HOUT0 HOUT3 K1 J...

Страница 35: ...k with high current outputs end 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 sourcing drivers The digOutTriStateConfig_H function call configures the high current outputs as tristate drivers with both sinking and sourcing capability ...

Страница 36: ...on a particular model is operating 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 RS 232 serial communication protocol Basically the chip translates the Rabbit microprocessor s CMOS signals to RS 232 signal levels Note that the polarity is reversed i...

Страница 37: ... 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...

Страница 38: ...ions Programming debugging Cloning 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 from a PC while a program is being debugged The Rabbit 4000 or Rabbit 5000 startup mode pins SMODE0 SMODE1 are presented to the programming port so that an externally con...

Страница 39: ...shelf Ethernet cables Figure 14 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 a functioning 100Base T network SPEED and one FDX COL to indicate that the current connection is in full duplex mode steady on or that a half duplex connection is exper...

Страница 40: ...he resistors form an approx 10 1 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 inputs and setting the reference voltage from the D A converter single ended unipolar single ended bipolar differential bipolar or current 4 20 mA on channels 0 3 only ...

Страница 41: ...lar Differential Bipolar 1 0 20 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 gain of 8 When using channels AIN0 AIN3 for current measurements remember to set the corre sponding jumper s on header JP4 The current measurements are realized by actua...

Страница 42: ...ration table in software only holds 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 Sample programs are provided to illustrate how to read and calibrate the various A D inputs for the three operating modes These sample programs are found in the ADC subdi...

Страница 43: ... shows the D A converter outputs 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 Table 9 D A Converter Jumper Configurations D A Converter Output JP3 JP5 JP6 AOUT0 0 to 10 V default 1 2 3 4 1 3 10 V 5 6 1 3 4 20 mA 3 5 AOUT1 0 to 10 V default 2 4 1...

Страница 44: ...ted output The D A converter outputs 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 mode uni polar bipolar and current that you intend to use It is imperative that you calibrate each of the D A converter outputs in the same manner as they are to be use...

Страница 45: ...eference voltages for the digital 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 the anaOutConfig function it is important to run the anaOutConfig function before running anaInConfig if you plan to use the analog outputs to ensure that the reference...

Страница 46: ... be downloaded and debugged when 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 programming cable Power RESET BL4S200 when changing mode Cycle power off on or press RESET after removing or attaching programming cable Program Mode RESET S1 S2 R1 CORE 3 3 V ...

Страница 47: ...e power consumption and further 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 highly on the CPU resources 1 Select the Defines tab from the Dynamic C Options Project Options menu 2 Add the line CLOCK_DOUBLED 0 to always disable the clock doubler ...

Страница 48: ...the maximum clock speed 1 Select 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 1 For strong spreading add the line ENABLE_SPREADER 2 To disable the spectrum spreader add the line ENABLE_SPREADER 0 NOTE The strong spectrum spreading setting is not ...

Страница 49: ...l for tamper detection 3 9 4 microSD 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 but is generally unsuitable for direct program execution Unlike other flash devices the microSD Card has some intelligence which facilitates working with it You do not h...

Страница 50: ...a different one Once the application 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 module or the data stored on the card The Dynamic C FAT file system will handle this overhead automatically when you unmount the microSD Card LED DS4 above the microSD C...

Страница 51: ... On the BL4S210 an application can 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 sector size or type Due to the volatility of the flash memory market the BL4S200 and Dynamic C were designed to accommodate flash devices with various sector sizes Develop...

Страница 52: ...tandard debugging features Breakpoints 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 addresses opcodes mnemonics and machine cycle times Switch between debugging at machine code level and source code level by simply opening or closing the disassembly window Wa...

Страница 53: ...ng the patch Do not simply copy 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 retire the existing installation but keep it available to handle legacy applications 4 1 2 Add On Modules Starting with Dynamic C version 10 40 Dynamic C includes the pop...

Страница 54: ...tions at the beginning of the sample 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 and must be connected to a PC using the programming cable as described in Section 2 2 BL4S200 Connections See Appendix C for information on the power supply connection...

Страница 55: ... 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 C...

Страница 56: ...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...

Страница 57: ...ves the message is reset so you 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 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...

Страница 58: ...capture windows and pulse modulation 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 cap turing real world repetitive signals will usually not have this advantage Refer to Section 3 2 1 3 for more information on how to use the input capture feature Foll...

Страница 59: ...3 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 ...

Страница 60: ...gram cannot be run on the BL4S210 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 correct parity for the UART SIMPLE3WIRE C This program demonstrates basic RS 232 serial communication using the Dynamic C STDIO window Follow these instructions before runn...

Страница 61: ...tory MASTER C This program demonstrates 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 to program the slave Make the following connections between the master and slave SLAVE C This program demonstrates a simple RS 485 transmission of lower case letters to...

Страница 62: ...gram jumper pins 1 2 3 4 5 6 and 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 Dynamic C STDIO window ADC_CAL_SE_BIPOLAR C Demonstrates how to recalibrate a single ended bipolar A D converter channel using two measured voltages to generate two coef...

Страница 63: ...of all single ended analog input 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 OFF between a pin AIN0 AIN7 and AGND then compile and run the sample program and follow the instructions in the Dynamic C STDIO window The voltage readings will be displ...

Страница 64: ...dow DAC_MA_ASYNC C Demonstrates 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 up for asynchronous operation which updates the D A converter output at the time it s being written via the anaOut or anaOutmAmps function calls Before you compile and...

Страница 65: ... unipolar or connect pins 5 6 on 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_VOLT_SYNC C Demonstrates how to output a voltage that can be read with a voltmeter The output voltage is computed using the calibration constants that are stored in the...

Страница 66: ... t write user specified text to 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 microSD Card at its lowest level and writing to pages will likely make the microSD Card unreadable by a PC For PC compatibility you must use the Dynamic C FAT file syste...

Страница 67: ...ciated with features specific to 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 libraries specific to using TCP IP functions on the BL4S200 Further informa tion about TCP IP is provided in Chapter 5 Using the Ethernet TCP IP Features ...

Страница 68: ...on Calls 4 4 1 Board Initialization 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 in Appendix A ...

Страница 69: ...NVAL invalid parameter value SEE 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 set as an input 0 31 pins DIO0 DIO31 RETURN VALUE The logic state of the specified channel 0 logic low 1 logic high EINVAL channel value is out of range EPERM pin functi...

Страница 70: ...RETURN VALUE Data read from the 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 DIO16 DIO24 D1 DIO1 DIO9 DIO17 DIO25 D2 DIO2 DIO10 DIO18 DIO26 D3 DIO3 DIO11 DIO19 DIO27 D4 DIO4 DIO12 DIO20 DIO28 D5 DIO5 DIO13 DIO21 DIO29 D6 DIO6 DIO14 DIO22 DIO30 MSB D...

Страница 71: ...upt events on both edges handle 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 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 c...

Страница 72: ...nnel_b channel to use as Input B 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 of a particular RIO chip index_polarity polarity of the index channel not used when channel_index set to 1 l 0 index on low level non zero index on high level RETURN VA...

Страница 73: ...H_ENABLE continuous up count mode 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 options options based on mode N A if the continuous up mode is selected BL_EDGE_RISE down count on rising edge BL_EDGE_FALL down count on falling edge BL_EDGE_BOTH down...

Страница 74: ...T 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 not been configured to support this function call Appendix D provides the details of the pin and block associations to allow you to identify the channels that need to be reconfigured to support this function call SEE ALSO brdInit ge...

Страница 75: ... CNT_TIL_END then it specifies the 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 until end event detected BL_CNT_ON_BEGIN count while begin signal is active NOTE If an end event occurs before the begin event the count will begin then end immediately o...

Страница 76: ...limit options use BL_PRESCALE use 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 EACCESS resource needed by this function is not available EFAULT internal data fault detected positive number Mode Conflict the positive number is a bitmap that corresponds...

Страница 77: ...er reading RETURN VALUE 0 success 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 register within the counter block hosting the given channel PARAMETERS channel a channel that uses the desired counter block begin pointer to word variable to place begi...

Страница 78: ...TURN VALUE 0 success EINVAL invalid 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 hosting the given channel The active block is determined by the function the configurable I O channel is set up to perform PARAMETER channel a channel that uses the desir...

Страница 79: ...ck hosting the given channel This 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 value for the limit register RETURN VALUE 0 success EINVAL invalid parameter value SEE ALSO brdInit setCapture resetCounter ...

Страница 80: ...other PARAMETERS channel channel 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 of the synch signal BL_EDGE_RISE synchronize event on rising edge BL_EDGE_FALL synchronize event on falling edge BL_EDGE_BOTH synchronize events on both edges 0 disable ...

Страница 81: ... success EPERM brdInit was not run 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 chan nel is also initialized to logic 0 or logic 1 based on the state parameter The digOut function should be used to control the output state after configuration as it is...

Страница 82: ...ow control of pins that are configured 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 GND 1 puts the output in a high impedance tristate RETURN VALUE 0 success EINVAL invalid parameter value EPERM pin function was not set up as a digital output SEE ALSO br...

Страница 83: ... output bank pins 0 DIO0 DIO7 1 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 puts the output in a high impedance tristate RETURN VALUE 0 success EINVAL invalid parameter value or board not initialized SEE ALSO brdInit digOut setDigOut Data Bits Ba...

Страница 84: ...I O channel being set up for PWM 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 parameter to use bound edge to set the duty cycle a duty cycle above 100 0 will be set to 100 0 invert whether the PWM output is inverted the PWM output normally starts with ...

Страница 85: ...t 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 not been configured to support this function call Appendix D provides the details of the pin and block associations to allow you to identify the channels that need to be reconfigured to support this function call SEE ALSO brdInit setFreq setDuty setTog...

Страница 86: ... be set to 100 0 NOTE A zero offset 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 to use bound edge to set the duty cycle a PPM duty cycle above 100 0 will be set to 100 0 NOTE PPM will not wrap around the PPM period If offset is set to 25 the 75 to ...

Страница 87: ...n EACCES resource needed by this 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 not been configured to support this function call Appendix D provides the details of the pin and block associations to allow you to identify the channels that need to b...

Страница 88: ... drift If this drift is of concern 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 function call PARAMETERS channel all channels on the same RIO chip and block as this channel 0 29 DIO0 DIO29 will have their frequency set Duty cycle and offset percenta...

Страница 89: ...nels DIO30 and DIO31 do not support 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 0 to 100 a duty cycle above 100 0 will be set to 100 0 RETURN VALUE 0 success EINVAL invalid parameter value EPERM channel function does not permit this operation SEE A...

Страница 90: ...ity and cannot be used with this 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 produce the smallest offset possible which is one count If you must have a zero offset use setPWM instead of setOffset RETURN VALUE 0 success EINVAL invalid parameter value...

Страница 91: ...et to 0 or 1 RETURN VALUE 0 success 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 a disabled PWM PPM output The pin is restored to the same PWM PPM operation it had before being disabled PARAMETER channel channel that is getting its PWM PPM enabled ...

Страница 92: ...tion byte to configure output channels 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 5 high current output channel HOUT5 Bit 4 high current output channel HOUT4 Bit 3 high current output channel HOUT3 Bit 2 high current output channel HOUT2 Bit 1 high c...

Страница 93: ... HOUT7 state sets a given channel 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 impedance tristate Sourcing configuration 0 connects the load in a high impedance tristate 1 connects the load to K1 or K2 RETURN VALUE 0 success EINVAL if not configured c...

Страница 94: ...s tristate 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 5 high current output channel HOUT5 Bit 4 high current output channel HOUT4 Bit 3 high current output channel HOUT3 Bit 2 high current output channel HOUT2 Bit 1 high current output channel HOUT1 Bit 0 high current output channel H...

Страница 95: ...ut pins 0 to 7 HOUT0 HOUT7 state 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 GND 1 connects the load to K1 or K2 2 puts the output in a high impedance tristate RETURN VALUE 0 success EINVAL invalid parameter or channel not configured for trista...

Страница 96: ...lock duty PWM duty cycle should 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 put using these macros HCPWM_TRI_LOW normally tristated and pulsed to sinking HCPWM_TRI_HIGH normally tristated and pulsed to sourcing HCPWM_LOW_HIGH normally sinking a...

Страница 97: ...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 not been configured to support this function call Appendix D provides the details of the pin and block associations to allow you to identify the channels that need to be reconfigured to support this function call SEE ALSO brdInit setFreq_H setDuty_...

Страница 98: ...ffset use setPWM_H instead of setPPM_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 100 will have the same effect NOTE PPM will not wrap around the PPM period If offset is set to 25 the 75 to 100 duty cycle will have the same effect as offset 25 duty 75...

Страница 99: ...tion EACCES resource needed by this 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 not been configured to support this function call Appendix D provides the details of the pin and block associations to allow you to identify the channels that need t...

Страница 100: ...ion by itself may cause the duty 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 chip and block as this channel 0 7 HOUT0 HOUT7 will have their frequency set Duty cycle and offset percentages will be maintained frequency frequency of the PWM and PPM ou...

Страница 101: ...een bound to this channel s PWM 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 VALUE 0 success EINVAL invalid parameter value EPERM channel function does not permit this operation SEE ALSO brdInit setPWM_H setPPM_H setOffset_H setFreq_H setToggle_H s...

Страница 102: ...annel that is getting its offset 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 a zero offset use setPWM_H instead of setOffset_H RETURN VALUE 0 success EINVAL invalid parameter value EPERM channel function does not permit this operation SEE ALSO ...

Страница 103: ...s associated with PARAMETERS channel 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 falling edge BL_EDGE_BOTH synchronize events on both edges RETURN VALUE 0 success EINVAL invalid parameter value SEE ALSO brdInit setPWM_H setPPM_H ...

Страница 104: ...PARAMETERS channel configurable 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 increment inphase begin BL_IER_ROLL_D counter rollover on decrement BL_IER_ROLL_I counter rollover on increment BL_IER_MATCH3 Match 3 condition BL_IER_MATCH2 Match 2 condit...

Страница 105: ...AMETERS channel high current output 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_IER_ROLL_I counter rollover on increment BL_IER_MATCH3 Match 3 condition BL_IER_MATCH2 Match 2 condition BL_IER_MATCH1 Match 1 condition BL_IER_MATCH0 Match 0 condition ...

Страница 106: ...sabled to set the IER value Disabling 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 RIO Interrupt Enable and Status registers RETURN VALUE 0 success EINVAL Invalid parameter given EPERM Handler is enabled can t change IER SEE ALSO addISR addISR_H enabl...

Страница 107: ...ble non zero enables the ISR zero 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 interrupts are not being used Any enabled ISR events will be passed to the appropriate ISR handler RETURN VALUE None SEE ALSO addISR addISR_H enableISR setIER ...

Страница 108: ...n see the Dynamic C User s Manual 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 used by your application program Call this function after executing serXopen and before using any other serial port function calls PARAMETER mode the defined serial port...

Страница 109: ... disables the transmitter after 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 VALUE None SEE ALSO brdInit serMode ser485En ser485Rx void ser485Rx void FUNCTION DESCRIPTION Disables the RS 485 transmitter This puts you in listen mode which allows yo...

Страница 110: ...hannel 6 AIN6 biased by D A converter 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 differential mode will always configure pairs For all of the pairs indicated above both or neither will be configured for the differential mode depending on the mode sele...

Страница 111: ...n for the A D converter channel 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_SPIBUSY SPI port busy EINVAL invalid parameter SEE ALSO brdInit anaInCalib anaIn anaInVolts anaInmAmps anaInDiff ...

Страница 112: ...of the maximum voltage range are 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 macros to set the mode for the channel being configured SE0_mode single ended unipolar 0 20 V SE1_mode single ended bipolar 10 V DIFF_MODE differential bipolar 20 V mA...

Страница 113: ...to the second A D converter value 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 Single Ended Unipolar Single Ended Bipolar Differential Bipolar 0 GAIN_X1 0 20 V 10 V 20 V 1 GAIN_X2 0 10 V 5 V 10 V 2 GAIN_X4 0 5 V 2 5 V 5 V 3 GAIN_X5 0 4 V 2 V 4 V 4 GA...

Страница 114: ...nnel analog input channel number 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 AIN3 AIN2 3 AIN3 AIN3 4 AIN4 AIN4 AIN5 5 AIN5 6 AIN6 AIN6 AIN7 7 AIN7 Gain Code Macro Voltage Range Single Ended Unipolar Single Ended Bipolar Differential Bipolar 0 GAI...

Страница 115: ...sions 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_SPIBUSY BL_TIMEOUT BL_OVERFLOW BL_WRONG_MODE System errors can create run time error unless disabled ERR_ANA_INVAL invalid parameter value SEE ALSO brdInit anaInConfig anaInCalib anaInmAmps anaInDiff anaInVolts ...

Страница 116: ...ode accesses will occur 1 The user 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 only applies for the single ended bipolar A D converter operation PARAMETERS channel analog input channel number 0 to 7 corresponding to AIN0 AIN7 gaincode the gain co...

Страница 117: ... converter is not calibrated for 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 errors can create run time error unless disabled ERR_ANA_CALIB fault detected in reading calibration facto r ERR_ANA_INVAL invalid parameter value SEE ALSO brdInit anaI...

Страница 118: ...W error If the gain code for a given 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 below gaincode the gain code of 0 to 7 channel Differential Inputs 0 AIN0 AIN1 2 AIN2 AIN3 4 AIN4 AIN5 6 AIN6 AIN7 Gain Code Macro Actual Gain Differential Voltage Ran...

Страница 119: ...converter is not calibrated for 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 errors can create run time error unless disabled ERR_ANA_CALIB fault detected in reading calibration factor ERR_ANA_INVAL invalid parameter value SEE ALSO brdInit anaInC...

Страница 120: ...ETURN VALUE A current value corresponding 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 converter is not calibrated for this channel gain BL_OVERFLOW A D converter overflow BL_SPIBUSY shared SPI port is already in use BL_TIMEOUT A D converter timeou t BL_WR...

Страница 121: ...e the following calculation and 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_code Single Ended Input Lines mA Input Lines 0 AIN0 AIN1 8 AIN0 AIN0 1 AIN2 AIN3 9 AIN1 AIN1 2 AIN4 AIN5 10 AIN2 AIN2 3 AIN6 AIN7 11 AIN3 AIN3 4 Reserved 12 AIN4 Reserv...

Страница 122: ...L4S200 A D converter configurations 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_ERRCODESTART or less as follows BL_SPIBUSY BL_TIMEOUT BL_OVERFLOW BL4S200 A D Converter Input channel_code Differential 0 4 Single Ended Unipolar 8 15 Single Ended Bipolar...

Страница 123: ...e A D converter input circuit and 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_UNIPOLAR 0 unipolar operation 0 10V and 4 20 mA DAC_BIPOLAR 1 bipolar operation 10V and 4 20 mA NOTE This parameter has no effect when the D A converter is configured for 4 ...

Страница 124: ...updated immediately in the asynchronous 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 should only be to strobe external D A converter channels 0 and 1 PARAMETER channels bitmap of channels to be strobed 1 Channel 0 2 Channel 1 3 Channels 0 and 1 RETURN VA...

Страница 125: ...cuits PARAMETER mode D A converter 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 not call this function until you have configured both D A converter channels to the desired voltage or current operation Unconfigured D A converter channels will be se...

Страница 126: ...the D A converter output channel 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 calibration data unipolar configuration value1 the first D A converter value 0 4095 volts1 the voltage or current corresponding to the first D A converter value 0 10 V 1...

Страница 127: ... PARAMETERS ch the D A converter 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 maximum 4095 RETURN VALUE 0 success BL_SPIBUSY SPI port busy SEE ALSO anaOutDriver anaOutVolts anaOutCalib ...

Страница 128: ...ibra tion constants to calculate 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 busy ERR_ANA_INVAL invalid config parameter ERR_ANA_CALIB error reading calibration data SEE ALSO brdInit anaOut anaOutStrobe anaOutConfig anaOutCalib ...

Страница 129: ...alibra tion constants to calculate 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 success BL_SPIBUSY SPI port busy ERR_ANA_CALIB error reading calibration data SEE ALSO brdInit anaOut anaOutVolts anaOutStrobe anaOutConfig anaOutCalib ...

Страница 130: ...r mode is critical for determining 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 The cmd parameter format is as follows Use the following calculation and tables to determine cmd cmd channel 12 rawdata value RETURN VALUE 0 success BL_SPIBUSY SPI port...

Страница 131: ...fied and is made active only when 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 variable pointed to by its associated flag The sample code below shows how a protected variable is defined and how its value can be restored protected nf_device nandFla...

Страница 132: ...hrough CAT 5 6 Ethernet cables and 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 Connect the AC adapter and the programming cable as shown in Chapter 2 Getting Started 2 Ethernet Connections If you do not have access to an Ethernet network use a crossov...

Страница 133: ...ing it back in or by momentarily 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 Ethernet hub or to an active Ethernet card The orange ACT light flashes each time a packet is received BL4S200 User s PC Crossover CAT 5 6 Ethernet cable Direct Connec...

Страница 134: ...DRESS MY_NETMASK MY_GATEWAY and 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 to 10 10 6 1 If you would like to change the default values for example to use an IP address of 10 1 1 2 for the BL4S200 board and 10 1 1 1 for your PC you can edit th...

Страница 135: ...e network interface card used for 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 select the Local Area Connection first and then click on the Properties button to bring up the Ethernet interface dialog Then Configure your interface card for a 10Base T ...

Страница 136: ...nection is made Note If the LNK 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 the MS DOS window and running the ping program ping 10 10 6 100 or by Start Run and typing the command ping 10 10 6 100 Notice that the orange ACT light flashes on the BL...

Страница 137: ...tal input to indicate that the TCP 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 on your PC Start Run telnet 10 10 6 100 As long as you have not modified the TCPCONFIG 1 macro in the sample program the IP address is 10 10 6 100 as shown otherwise use...

Страница 138: ...n that is used with the BL5S220 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 print servers 802 11b g can operate in one of two modes in a managed access mode BSS called an infrastructure mode or an unmanaged mode IBSS called the ad hoc mode The...

Страница 139: ...ce enabled Commands issued to the 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 Ad Hoc Mode In the ad hoc mode each device can set a channel number and an SSID to communicate with If devices are operating on the same channel and SSID they can talk ...

Страница 140: ...connect the programming header on 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 compile and run it by pressing F9 Each sample program has comments that describe the purpose and function of the pro gram Follow the instructions at the beginning of t...

Страница 141: ...17 R29 JP11 JP1 5 JP1 9 JP2 1 JP22 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 L1 C6 C5 AGN D CVT LN6I N LN4I N LN2I N LN0I N VRE F LN7 IN LN5 IN LN3 IN LN1 IN AGN D AGN D R11 R12 RX4 7 RX43 P1 R31 P2 C136 C135 U19 C119 C118 C121 C115 C105 C104 C1...

Страница 142: ...ou will need a PC with an available 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 mode or you will need at least a PDA or PC with Wi Fi to use the ad hoc mode ...

Страница 143: ...t settings only if that is necessary 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 _PRIMARY_STATIC_IP 10 10 6 100 define _PRIMARY_NETMASK 255 255 255 0 define MY_NAMESERVER 10 10 6 1 define MY_GATEWAY 10 10 6 1 There are similar macros defined for the variou...

Страница 144: ... to the Local Area Connection to 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 may have to select the Local Area Connection first and then click on the Properties but ton to bring up the Ethernet interface dialog Then configure your interface car...

Страница 145: ...ess network name with the access 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 described in Step 2 for Infrastructure Mode via Ethernet connection by clicking on Network Connections then on Local Area Connection Now click on Wireless Network Connection to...

Страница 146: ...ion is the only approved option 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 The end user is responsible for enabling 802 11d on the access point and then selecting the correct country to be broadcast in the beacon packets NOTE This option sets ...

Страница 147: ...bbit recommends that you check the 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 the 802 11d option enabled and is set for the correct region or country Check the TCP IP configuration parameters the IP address and the SSID in the macros which are rep...

Страница 148: ...ou are not pinging from the local 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 points using WEP keys You will need two access points to run this sample program The access points should be isolated or on separate networks The sample program associates...

Страница 149: ... a RabbitCore module on an ad hoc 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 TCPCONFIG 1 Use the next macro unchanged as long as you have only one BL5S220 Otherwise use this macro unchanged for the first BL5S220 define NODE 1 Then change the macro to ...

Страница 150: ...SS set IFS_ WIFI_SSID to the SSID 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 the Dynamic C TCP_CONFIG LIB library Then use a TCPCONFIG macro greater than or equal to 100 which will invoke your CUSTOM_CONFIG LIB library to be used Remember to add ...

Страница 151: ...INGLED_STATS C This program is similar 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 may modify PING_DELAY define to change the amount of time in milliseconds between the outgoing pings Modify the value in the MOVING_AVERAGE macro to change the moving av...

Страница 152: ...0 and the access point have the 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 startup of the sample program by about 30 seconds Change PING_WHO to the host you want to ping You may modify PING_DELAY to change the amount of time in milliseconds between ...

Страница 153: ...CCMP cypher suite and enter a suitable 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 in this sample program macro then copy and paste it to your access point This ensures that both the BL5S220 and the access point have the same key TIP For an initial te...

Страница 154: ...FIG 1 There are two TCPCONFIG macros 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 up for the TCPCONFIG macros define _PRIMARY_STATIC_IP 10 10 6 100 define _PRIMARY_NETMASK 255 255 255 0 define MY_NAMESERVER 10 10 6 1 define MY_GATEWAY 10 10 6 1 The u...

Страница 155: ...WIFI_REGION_AMERICAS Disable enable 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 encryption options are available IFPARAM_WIFI_ENCR_NONE no encryption is used IFPARAM_WIFI_ENCR_ANY any type of encryption is used IFPARAM_WIFI_ENCR_WEP use WEP encryption Yo...

Страница 156: ...I_WPA_PSK_PASSPHRASE now is the 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 matches the 256 bit 64 byte hexadecimal key used by your access point Specify a 64 hexadecimal digit 256 bits key here This key will be used and will over ride any passph...

Страница 157: ...threshold IFC_WIFI_RTS_THRESHOLD 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_WIFI_RTS_THRESHOLD 2347 Examples are available within Dynamic C Select Function Lookup from the Help menu or press ctrl H Type TCPCONFIG in the Function Search field and h...

Страница 158: ...PCONFIG macros Otherwise the Wi 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 before modifying any parameters that require the interface to be down see Section 6 3 2 by calling ifdown IF_WIFI0 Then bring the interface back up Finally no radio trans...

Страница 159: ...u 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 mail form at www rabbit com support If the sample programs ran fine you are now ready to go on An Introduction to TCP IP An Introduction to Wi Fi and the Dynamic C TCP IP User s Manual provide background and reference ...

Страница 160: ...ns that are characterized by low 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 smoke and intruder warning and building automation The power consumption of the individual device could be met for a year or longer using the originally installed batte...

Страница 161: ...ory and is not a part of the stan 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 compile and run it by pressing F9 Each sample program has comments that describe the purpose and function of the pro gram Follow the instructions at the beginning of the s...

Страница 162: ...8 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 ...

Страница 163: ...trol Panel System Hardware Device 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 no ZigBee devices are displayed you will have to reconfig ure the Digi XBee USB and recompile the sample program once you make sure the BL4S230 is powered up The timeo...

Страница 164: ...efault in the sample programs is 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 loaded to the XBee RF module is different depend ing on whether the BL4S230 is a router default or a coordinator See Appendix F Additional Configuration Instructions for ...

Страница 165: ...Each node should have a unique identifier 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 up and use AT commands with the XBee RF module The program will print out a list of AT commands in the Dynamic C STDIO window You may type in either ATxx or just the x...

Страница 166: ...4S230 to the Demonstration Board 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 GPIO GUI folder to connect to the Digi USB XBee coordinator and scan for devices Make sure the BL4S230 and the Digi USB XBee coordinator are configured with the same PA...

Страница 167: ...problems at this point Use the Dynamic 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 mail form at www rabbit com support If the sample programs ran fine you are now ready to go on An Introduction to ZigBee provides background information on the ZigBee pr...

Страница 168: ...BL4S200 User s Manual 168 APPENDIX A SPECIFICATIONS Appendix A provides the specifications for the BL4S200 and describes the conformal coating ...

Страница 169: ...0 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 C15C16R28R27R26 R25 C20 U5 JP12 JP13 JP14 R71 R70 R5 JP1 JP2 R72 JP3 JP4 JP5 JP6 JP7 JP8 JP9 JP1...

Страница 170: ...3 C137 C138 R79 R80 DS1 DS2 LINK 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 C38 C33 C34 C32 R34 C35 R60 R61 R59 R58 R36 U2 C100 C10 C9 U4 R83 R84 JP5 U12 C6 C5 C26 C27 U17 J2 C2 C73 JP1 JP3 JP2 JP4 R5 R4 R3 R2 R1 C108 C110 L18 C113 TP26 TP25 TP...

Страница 171: ... 512KB Data SRAM 512KB 512KB 512KB 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 digital inputs 0 36 V DC switching threshold 1 4 V 1 9 V typical or as sinking digital outputs up to 40 V 200 mA each High Current Digital Outputs 8 outputs individually so...

Страница 172: ...1 MB s Hardware Connectors RJ 45 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 port 2 5 IDC 1 27 mm pitch Network Connectors One RJ 45 Ethernet One RP SMA antenna Real Time Clock Yes Timers Ten 8 bit timers 6 cascadable 3 reserved for internal periph...

Страница 173: ...trical or EMI interference between 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 connectors at J1 J2 J3 J9 J10 J11 and J12 for phys ical connection to other boards via wiring harnesses There are 3 mm Micro Fit connec tors at J5 and J7 for power supp...

Страница 174: ... effects of moisture and contaminants 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 replaced using standard soldering procedures for surface mounted components A new conformal coating should then be applied to offer continuing protection against the effec...

Страница 175: ...Inputs pulled up to 3 3 V JP2 DIO24 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 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 ...

Страница 176: ...n resistors connected 1 3 4 6 Bias 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 pulled up to KA 3 4 Inputs pulled up to 5 V 5 6 Inputs pulled down to GND 7 8 Inputs pulled up to 3 3 V Although pins 1 3 and 4 6 of header JP7 are shown jumpered for the...

Страница 177: ...ut RXC RS 485 Pulled up PC4 Output 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 Not connected PD2 Output TXF RS 232 except BL4S210 Serial Port F Low PD3 Output RXF RS 232 except BL4S210 Low PD4 PD5 Output Not connected Low PD6 Output TXE RS 232 exc...

Страница 178: ...ircuits In turn the regulated 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 module to ensure adequate capacity for its circuits LINEAR POWER REGULATOR POWER IN J5 C9 10 µF LM1117T U3 3 3 V 3 1 2 1 3 B240 D10 47 µF C10 330 µF 5 V L1 C5 150 µH D9 B240...

Страница 179: ...ls Do not use these voltage supplies 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 is provided by two different sources depending on whether the main part of the BL4S200 is powered or not When the BL4S200 is powered normally and the 3 3 V supply is with...

Страница 180: ...t time and when ever you replace 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 main power off on any time the RabbitCore module is removed from the BL4S200 main board since that is where the backup battery is located Rabbit s Technical Note TN235 E...

Страница 181: ...ble current at DCIN based on the 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 Power Supply and Vcc 5 V Current Used at J7 VRAW Power Supply Input at J2 V Current at J7 with Vcc 5 V 100 mA 200 mA 300 mA 400 mA 500 mA 600 mA 623 mA 8 0 545 450 355 26...

Страница 182: ...BL4S200 User s Manual 182 APPENDIX C DEMONSTRATION BOARD Appendix C explains how to use the Demonstration Board with the BL4S200 sample programs ...

Страница 183: ...7 BL4S200 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...

Страница 184: ...on screw terminal header J1 and 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 Figure C 3 Pushbutton Switch Configuration GND LED1 LED2 LED3 LED4 V OUTPUTS J3 V_ALT SW4 SW3 SW2 SW1 GND J1 POWER INPUTS 3 3 kW V JP15 SW1 SW4 ACTIVE LOW 3 3 kW V JP1...

Страница 185: ... The power supply voltage input 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 originally input Figure C 5 shows the location of the adjustable output voltage and the potentiometer Figure C 5 Location of Adjustable Output Voltage K in sinking mode in sourc...

Страница 186: ...s The main shared resource within 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 RIO number and the block number The tables in this appendix provide a quick reference of which block is used by each input and or output pin on the BL4S200 board ...

Страница 187: ... 1 1 DIO2 2 2 DIO3 3 3 DIO4 1 1 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 0 3 2 DIO23 1 3 DIO24 4 0 4 2 DIO25 1 3 DIO26 5 0 5 2 DIO27 1 3 DIO28 0 7 0 6 0 DIO29 1 7 0 6 0 DIO30 2 6 0 Not controlled by any RIO chip DIO31 7 0 ...

Страница 188: ...ounter timer block with the pin 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 Mode Conflict error code of 3 This error code is a 4 bit value that identifies other pins other pins using the same coun ter timer block that conflict with the requested...

Страница 189: ...at can be used with an external 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 input and output functionality making these pins ideal for single pin functions requiring a counter timer Table D 3 shows all counter timer modes of the RIO block and whi...

Страница 190: ...nections All RabbitNet connections 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 master Figure 1 Connecting Peripheral Cards to a Master MASTER SLAVE SLAVE MASTER SLAVE Rabbit 3000 Microprocessor Straight through CAT 5 6 Ethernet cable Crossover CAT ...

Страница 191: ...available on the con nector The 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 connectors are used Signal 0 1 friction lock connectors Power 0 156 friction lock connectors RabbitNet RJ 45 connector Display Keypad interface Allows you to connect yo...

Страница 192: ...for a data rate of 1 MHz Rabbit 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 RJ 45 8 pin female connectors The cables may be swapped end for end without affecting functionality E 2 1 Control and Routing Control starts at the master when the maste...

Страница 193: ...ization the network is enumerated 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 functions PARAMETERS portflag bit that represents a RabbitNet port on the master single board computer from 0 to the maximum number of ports A set bit re quires a servic...

Страница 194: ...ermine that the peripheral card 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 router downstream port RETURN VALUE Pointer to device information 1 indicates that the peripheral card either cannot be identified or is not connected to the master SE...

Страница 195: ...se a maximum of 3 macros for the 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 revision RN_MATCH_CODEREV match code revision RN_MATCH_SN match serial number For example rn_search newdev newdev flags RN_MATCH_PORT RN_MATCH_SN newdev ports 0x03 search p...

Страница 196: ...ter rn_write int rn_write int handle 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 peripheral card is connected to a master PARAMETERS handle address index to device information Use rn_device or rn_find to establish the handle regno command register number...

Страница 197: ... device information Use rn_device 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 15 NOTE A data length of 0 will transmit the one byte command register number RETURN VALUE The status byte from the previous command 1 means that device information indi...

Страница 198: ...t only the microprocessor logic 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 timeout FUNCTION DESCRIPTION Sets software watchdog timeout period Call this function prior to enabling the software watchdog timer This function will check device inform...

Страница 199: ...pdated by soft ware on the master 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 handle address index to device information Use rn_device or rn_find to establish the handle wdttype 0 enables both hardware and software watchdog timers 1 enables hardware ...

Страница 200: ...pheral card is connected to a master 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 left in seconds can be determined from count 0 025 seconds RETURN VALUE The status byte from the previous command 1 means that device information indicates the periphe...

Страница 201: ...handle address index to device information 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 7 HW reset has occurred 6 SW reset has occurred 5 HW watchdog enabled 4 SW watchdog enabled 3 2 1 0 Reserved RETURN VALUE The status byte from the previous command ...

Страница 202: ... 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 7 Data available and waiting to be processed MOSI master out slave in 6 Write collision MISO master in slave out 5 Overrun MOSI master out slave in 4 Mode fault device detected hardware fault 3 Data compare error detected by...

Страница 203: ...dy 10 Busy 11 Device not connected 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 cards 0 Last command accepted 1 Last command unexecuted 0 Not expired 1 HW or SW watchdog timer expired Use the function rn_rst_status to determine which timer expired ...

Страница 204: ...ly to interact with the Dynamic 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 use any other firmware versions with that version of Dynamic C Once you have successfully loaded the firmware compile and run another sample program to make sure the MOD...

Страница 205: ...ion 7 2 2 explains how to set up 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 the macro in the Dynamic C LIB Rabbit4000 XBee XBEE_API LIB library define DEFAULT_CHANNELS ZB_DEFAULT_CHANNELS For example to limit the channels to three channels the...

Страница 206: ... again 4 Under the Modem Configuration 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 API do not select other settings Version the version of the firmware included with the version of Dynamic C you are using should be of the type 21 5 Now change the netw...

Страница 207: ...BL4S200 User s 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 ...

Страница 208: ... could be listed If you select a 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 a get a message that X CTU is unable to open the COM port verify that you selected the COM port with the USB Serial Port then try unplugging the Digi XBee USB from the ...

Страница 209: ...t 41 configurable I O inputs 28 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 Connectivity Kit 9 crimp tool 9 Micro Fit connector parts 26 D D A converter 43 calibration 44 calibration constants 44 function calls anaOut 127 anaOutCalib 126 anaOut...

Страница 210: ...etIER 106 tickISR 107 IP addresses 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 175 176 JP3 digital input DIN16 DIN19 pullup pulldown configuration 28 29 34 176 JP4 digital input DIN20 DIN23 pullup pulldown configuration 28 29 30 34 JP5 digital inpu...

Страница 211: ...A C 62 D A converter DAC_CAL_MA 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_IO C 57 INTERRUPTS C 57 PPM C 58 PULSE_CAPTURE C 58 PWM C 58 QUADRATURE_DECOD ER C 59 how to set IP address 134 microSD Card SDFLASH_INSPECT C 66 PC notebook configurati...

Страница 212: ...o 154 Wi Fi configuration at run 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 connections 132 133 10Base T Ethernet card 132 additional resources 137 Ethernet hub 132 steps 132 Tool Kit 8 AC adapter 8 DC power supply 8 Demonstration Board 8 Dynami...

Страница 213: ...ion schemat 090 0229 pdf 090 0266 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 com documentation schemat 090 0252 pdf 090 0272 Rabbit Demonstration Board www rabbit com documentation schemat 090 0272 pdf You may use the URL information provided a...

Отзывы: