Home

User Manual - powerbridge.de

image

Contents

1. compactPCl In this document all supported modules and devices will be called TDRVO002 Specials for certain devices will be advised To get more information about the features and use of TDRV002 devices it is recommended to read the manuals listed below User manual of the TDRV002 device Engineering Manual of the TDRV002 device TDRV002 SW 72 LynxOS Device Driver Page 5 of 25 TEWS 2 TECHNOLOGIES 2 Installation Following files are located on the distribution media Directory path TDRV002 SW 72 TDRV002 SW 72 SRC tar gz GZIP compressed archive with driver source code TDRV002 SW 72 1 3 1 pdf PDF copy of this manual ChangeLog txt Release history Release txt Release information For installation the files have to be copied to the desired target directory The GZIP compressed archive TDRV002 SW 72 SRC tar gz contains the following files and directories Directory path tdrv002 tdrv002 c Driver source code tdrv002 h Definitions and data structures for driver and application tdrv0O2 info c Device information definition tdrv0O2 info h Device information definition header tdrv002 cfg Driver configuration file include tdrv002 import Linker import file Makefile Device driver make file example tdrv002exa c Example application source example tdrv002config c Application source to configure programmable transceivers example Makefile Example application source In order to perform an installation extract all file
2. rs485fdm transceiver in RS485 full duplex master mode rs485fds transceiver in RS485 full duplex slave mode rs485hd XXXXXXXX Binary Value for a free configuration BH e g use 01000000 for off Refer to the user manual for more information gt bit 0 RS485 RS232 configuration pin 4 bit bat transceiver in RS486 half duplex mode HDPLX configuration pin RI RTERM configuration pin A configuration pin ITERM configuration pin SLEWLIMIT configuration pin SHDN configuration pin V NV NV VV V V o ope i t t t t t oF WN nm Auto RS485 Operation mode TDRV002 SW 72 LynxOS Device Driver Page 22 of 25 TEWS 22 TECHNOLOGIES A call with the device pathname as argument will allow an interactive configuration It allows the configuration of predefined interface settings Select 1 PN tdrv002config dev tdrv002a1 New Transceiver Configuration for dev tdrv002a2 ex Master ex Slave RS232 RS422 RS485 Full Dupl RS485 Full Dupl RS485 Half Dupl OFF ex A call with two arguments allows a setup of the interface without interaction The first parameter must specify the device pathname and the second will specify the new interface configuration The interface configuration can be specified by predefined configuration names or by a b
3. TEWS 2 The Embedded I O Company TECHNOLOGIES TDRV002 SW 72 LynxOS Device Driver Multiple Channel Serial Interface Version 1 3 x User Manual Issue 1 3 1 September 2012 TEWS TECHNOLOGIES GmbH Am Bahnhof 7 25469 Halstenbek Germany Phone 49 0 4101 40580 Fax 49 0 4101 4058 19 e mail info tews com www tews com TDRV002 SW 72 LynxOS Device Driver Multiple Channel Serial Interface Supported Modules TPMC371 TPMC372 TPMC375 TPMC376 TPMC377 TPMC460 TPMC461 TPMC462 TPMC463 TPMC465 TPMC466 TPMC467 TPMC470 TCP460 TCP461 TCP462 TCP463 TCP465 TCP466 TCP467 TCP469 TCP470 Issue 1 0 0 TENSE TECHNOLOGIES This document contains information which is proprietary to TEWS TECHNOLOGIES GmbH Any reproduction without written permission is forbidden TEWS TECHNOLOGIES GmbH has made any effort to ensure that this manual is accurate and complete However TEWS TECHNOLOGIES GmbH reserves the right to change the product described in this document at any time without notice TEWS TECHNOLOGIES GmbH is not liable for any damage arising out of the application or use of the device described herein 2005 2012 by TEWS TECHNOLOGIES GmbH Date March 24 2005 1 0 1 New Address TEWS LLC New File List March 1 2007 1 1 0 Additional Modules supported Programmable Transceiver Support January 16 2009 command line tool tdrv002config added 1 2 0 Address TEWS LLC removed description for LynxOS 5 x De
4. I O interface programmable transceivers The function specific control parameter arg specifies the new configuration of the programmable transceivers Only allowed for channels supporting a programmable I O interface A combination of the flags below must be specified to configure the interface Defined in tdrv002 h Flag TDRV002 TRANS RS485 RS232 SEL TDRV002 TRANS HDPLX SEL TDRV002 TRANS RENA SEL TDRV002 TRANS RTERM SEL TDRV002 TRANS TTERM SEL TDRV002 TRANS SLEWLIMIT SEL TDRV002 TRANS SHDN SEL TDRV002 AUTO RS485 SEL ENABLE Description RS485 RS232 configuration pin HDPLX configuration pin RENA configuration pin RTERM configuration pin TTERM configuration pin SLEWLIMIT configuration pin SHDN configuration pin RS485 Operation enable Auto mode of XR17D15x The function of the interface configuration pins can be found in the hardware User Manual There are predefined values of the interface configuration described in the hardware manual you can just OR the predefined value instead of a list of configuration flags Below is a list of the values Macro value TDRV002 INTF OFF TDRV002 INTF RS232 TDRV002 INTF RS422 TDRV002 INTF RS485FDM TDRV002 INTF RS485FDS TDRV002 INTF RS485HD TDRV002 SW 72 LynxOS Device Driver Description interface disabled RS232 RS422 Multidrop Full duplex RS485 Full duplex master RS485 Full duplex slave RS485 Half duplex Page 20 of 25 TEWS E TECHNOLOGI
5. TIOSHWH NULL if result lt 0 handle ioctl error ERROR CODES Error Code Description EBUSY The device is busy for example the self test active EPERM The hardware does not support RTS CTS All other returned error codes are system error conditions TDRV002 SW 72 LynxOS Device Driver Page 14 of 25 TEWS 2 TECHNOLOGIES 3 1 2 TIOCHWH NAME TIOCHWH Disable hardware handshake DESCRIPTION This function disables the hardware handshake mode of the TDRVO002 device This function is only available if the hardware channel supports RTS CTS lines There is no argument for this function EXAMPLE include tdrv002 h int result result ioctl Edi TIOCHWH NULL if result 0 handle ioctl error ERROR CODES Error Code Description EBUSY The device is busy for example the self test is active All other returned error codes are system error conditions TDRV002 SW 72 LynxOS Device Driver Page 15 of 25 TEWS 2 TECHNOLOGIES 3 1 3 TIOSLOCLOOP NAME TIOSLOCLOOP Enables local hardware loop back mode DESCRIPTION This function enables the local hardware loop back mode of the TDRVO0O2 device There is no argument for this function EXAMPLE include tdrv002 h int result result ioctl Edi TIOSLOCLOOP NULL if result 0 handle ioctl error ERROR CODES Error Code Description EBUSY The device is busy for exampl
6. allows the operation of a TDRV002 product family with DRM based PCI interface The TDRV002 SW 72 device driver is based on the standard LynxOS terminal manager Due to this way of implementation the driver interface and function is absolute compatible to the standard LynxOS terminal driver All standard utility programs for configuration and maintaining terminal interfaces could be used in the same manner There is only one exception the TDRV002 SW 72 can t be used as console driver Additional supported features Extended baud rates up to 5 5 MBaud gt Each channel has a 64 Byte transmit and receive FIFO with programmable trigger levels Hardware RTS CTS and software handshake Xon Xoff direct controlled by the serial controller The advantage of this feature is that the transmission of characters will immediately stop as soon as a complete character is transmitted and not when the transmit FIFO is empty for handshake under software control Control of Full Modem Lines Direct support of different physical interfaces Configuration of programmable transceiver En disable of local loop back mode Selftest function to check hardware VVVVV Receive hardware handshake is not fully implemented in terminal manager interface Control of modem and handshake lines is not fully supported by older LynxOS versions Support is implemented and tested with LynxOS 5 0 0 and Patch 070 The TDRV002 SW 72 device driver supports the m
7. transmit FIFO are between 1 and 64 Valid transceiver configurations are defined in tdrv002 h sg This structure contains initial tty parameter like baud rate special characters and so on Refer also to the tty man pages A device information definition is unique for every TDRVO002 major device The file tdrv002_info c on the distribution disk contains two device information declarations tdrv0024A for the first major device and tdrv002B for the second major device Some modules of the TDRV002 series supporting more than 8 channels are using more than one PCI Devices for these modules a major device for each of the controllers have to be installed If the driver should support more than two major devices it is necessary to copy and paste an existing declaration and rename it with a unique name for example tdrv002C tdrv002D and so on It is also necessary to modify the device and driver configuration file respectively the configuration include file tdrv002 cfg TDRV002 SW 72 LynxOS Device Driver Page 10 of 25 TEWS E TECHNOLOGIES The following device declaration information uses the auto find method to detect TDRVOO2 compatible device on the PCI bus The Rx trigger level is set to 30 Byte and the Tx trigger level is set to 8 for all minor devices TDRV002 INFO tdrv002A 1 auto find the TDRV002 on any PCI bus 1 Rx Tx trigger level 30 8 TD
8. 2 STS TIMEOUT TDRV002_STS_RCV_OVERFLOW TDRV002_STS_DATA_CORRUPTED TDRV002 STS RTSCTS NOFUNC TDRV002 STS DTRDSR NOFUNC TDRV002 STS RI NOFUNC TDRV002 STS DCD NOFUNC State The transmission timed out characters have not been sent one ore more The reception timed out not all characters have been received The device has received too many characters The sent and received characters are different RTS CTS function is damaged DTR DSR function is damaged RI function is damaged DCD function is damaged If no flag is set all tests have been completed successfully EXAMPLE include tdrv002 h int result unsigned long selftestResult result ioctl fd TIOSELFTEST amp selftestResult if result 0 handle ioctl error TDRV002 SW 72 LynxOS Device Driver Page 18 of 25 TEWS 2 gt TECHNOLOGIES ERROR CODES Error Code Description EBUSY The device is busy for example the selftest is active ENOMEM The function cannot allocate memory for Rx Tx test All other returned error codes are system error conditions TDRV002 SW 72 LynxOS Device Driver Page 19 of 25 3 1 6 TIOSETINTERFACE NAME TEWS 22 TECHNOLOGIES TIOSETINTERFACE Changes configuration of programmable transceiver DESCRIPTION This I O control function sets a new interface configuration This function is only usable for devices supporting a programmable
9. ES EXAMPLE include tdrv002 h int result unsigned int newConfig newConfig TDRV002 RS232 Select RS232 result ioctl fd TIOSETINTERFACE amp newConfig if result 0 handle ioctl error ERROR CODES Error Code Description EBUSY The device is busy for example the selftest is active EPERM The device does not support programmable interface or the selected configuration is not valid All other returned error codes are system error conditions TDRV002 SW 72 LynxOS Device Driver Page 21 of 25 TEWS 22 TECHNOLOGIES 4 Command Line Tools and Examples The command line tools are distributed with the driver and will be found in the example path as source code For usage an executable has to be built 4 1 tdrv002config This tool allows setting up the interface of devices supporting programmable transceivers It allows a change of the configuration without a restart of the device This function is only usable with TDRV002 supported modules which are using programmable transceivers The usage will be displayed with a simple call of tdrvOO2config without an argument tdrv002config Usage tdrv002config device lt config gt device device pathname e g dev tdrv002al config transceiver configuration off transceiver off rs232 transceiver in RS232 mode rs422 transceiver in RS422 mode
10. RV002 INTF OFF channel 0 minor device 0 30 8 TDRV002 INTF OFF channel 1 minor device 1 30 8 TDRV002 INTF OFF channel 2 minor device 2 30 8 TDRV002 INTF OFF channel 3 minor device 3 30 8 TDRV002 INTF OFF channel 4 minor device 4 30 8 TDRV002 INTF OFF channel 5 minor device 5 30 8 TDRV002 INTF OFF channel 6 minor device 6 30 8 TDRV002 INTF OFF channel 7 minor device 7 B9600 B9600 input and output speed HT erase char 1 2nd erase char Ur Q kill char ECHO CRMOD mode GT Te interrupt character PVA oem SES quit char or tet start char or QV stop char Ue tgr EOF 1 brk LCRTBS LCRTERA LCRTKIL LCTLECH local mode word A rer process stop eyt vg delayed stop RT e ets reprint line ro Vary flush output word erase V literal next char TDRV002 SW 72 LynxOS Device Driver Page 11 of 25 TEWS 2 TECHNOLOGIES 2 1 4 Configuration File CONFIG TBL The device and driver configuration file CONFIG TBL respective config tbl on LynxOS 5 0 systems contains entries for device drivers and its major and minor device declarations Each time the system is rebuild the config utility read this file and produces a new set of driver and device configuration tables and a
11. ardware 2 To update the library sys lib libdrivers a enter make install 2 1 1 2 Create Device Information Declaration 1 Change to the directory sys devices xxx or sys devices if sys devices xxx does not exist xxx represents the BSP 2 Add the following dependencies to the Makefile DEVICE FILES all tdrv002 info x And at the end of the Makefile tdrv002 info o DHEADERS tdrv002 info h 3 To update the library sys lib libdevices a enter make install 2 1 1 3 Modify the Device and Driver Configuration File In order to insert the driver object code into the kernel image an appropriate entry in file CONFIG TBL must be created 1 Change to the directory sys lynx os respective sys bsp xxx where xxx represents the BSP that supports the target hardware 2 Create an entry at the end of the file CONFIG TBL Insert the following entry at the end of this file I tdrv002 cfg TDRV002 SW 72 LynxOS Device Driver Page 7 of 25 TEWS 2 TECHNOLOGIES 2 1 1 4 Rebuild the Kernel 1 Change to the directory sys lynx os sys bsp xxx 2 Enter the following command to rebuild the kernel make install 3 Reboot the newly created operating system by the following command not necessary for KDIs reboot aN The N flag instructs init to run mknod and create all the nodes mentioned in the new nodetab After reboot you should find the following new devices depends on the devic
12. cember 9 2009 1 3 0 Support of new boards April 29 2011 1 3 1 Chapter Known Problems added September 13 2012 TDRV002 SW 72 LynxOS Device Driver Page 2 of 25 N Table of Contents TEWS 22 TECHNOLOGIES INTHODUGC TION 2 etu tlt rat uuu uu 4 INSTALLATION ONNECEUIGE MA KE 6 2 1 Device Driver InstallatiOTni iiie cuo aaan aaea 7 2 1 1 Static 7 2 1 1 1 Build the Driver 7 2 1 1 2 Create Device Information Declaration 7 2 1 1 3 Modify the Device and Driver Configuration 7 2 1 1 4 Rebuild the Kernel esses nn nnnennnnnnnnnnnnnnnnh nn nn nnns nnn 8 2 1 2 Dynamic Installationer tite ne Ele paced dette Fra rete Loco ke es 9 2 1 2 1 Build the Driver Object nnne nnn enne 9 2 1 2 2 Create Device Information Declaration 9 2 1 2 3 Uninstall dynamic loaded Driver sssseseeeeenenen menn 9 2 1 3 Device Information Definition File esee 10 2 1 4 Configuration File CONFIG TBL ssssssssesesesesenee
13. corresponding nodetab To install the TDRVOO2 driver and devices into the LynxOS system the configuration include file tdrv002 cfg must be included in the CONFIG TBL The file tdrv002 cfg on the distribution media contains the driver entry C tdrv002 and a major device entry D TDRVO002 1 8 tdrv002A with one minor device entry tdrv002ax for each channel where x represents the zero based channel number If the driver should support more than one major device the following entries for major and minor devices must be enabled by removing the comment character By copy and paste an existing major and minor entries and renaming the new entries it is possible to add any number of additional TDRVO00O2 devices This example shows a driver entry with one major device and eight minor devices Format C driver name open close read write select control install uninstall D device name info block name raw partner nam N node name minor dev C tdrv002 td002open td002close td002read td002write N td002ioctl td002install td002uninstall D TDRV002 1 tdrv002A N tdrv002a1 N tdrv002a2 N tdrv002a3 N tdrv002a4 N tdrv002a5 N tdrv002a6 N tdrv002a7 N tdrv002a8 WN FP The configuration above creates the following nodes in the dev directory dev tdrv002al dev tdrv002a2 dev tdrv002a3 dev tdrv002a4 dev tdrv002a5 dev tdrv002a6 dev t
14. drv002a7 dev tdrv002a8 TDRV002 SW 72 LynxOS Device Driver Page 12 of 25 TEWS 22 TECHNOLOGIES TDRV002 Device Driver Programming The TDRV002 SW 72 device driver is based on the standard LynxOS terminal manager Due to this way of implementation the driver interface and function is absolute compatible to the standard LynxOS terminal driver The TDRV002 SW 72 device driver supports some additional ioctl functions to use some extra features The table below shows the additional functions defined in tdrv002 h Command Code Description TIOSHWH 290 enable hardware handshake RTS CTS only available if channel supports RTS CTS TIOCHWH 291 disable hardware handshake RTS CTS only available if channel supports RTS CTS TIOSLOCLOOP 292 enable local loopback mode TIOCLOCLOOP 293 disable local loopback mode TIOSELFTEST 294 execute selftest TIOSETINTERFACE 295 change configuration of programmable tranceiver TDRV002 SW 72 LynxOS Device Driver Page 13 of 25 TEWS 2 TECHNOLOGIES 3 1 1 TIOSHWH NAME TIOSHWH Enable hardware handshake DESCRIPTION This function enables the hardware handshake mode of the TDRV002 device This function is only available if the hardware channel supports RTS CTS lines There is no argument for this function This function enabled hardware handshake but it does not prevent of data loss by FIFO overrun EXAMPLE include lt tdrv002 h gt int result result ioctl fd
15. e configuration dev tdrv002a1 dev tdrv002a2 dev tdrv002a3 dev tdrv002b1 dev tdrv002b2 TDRV002 SW 72 LynxOS Device Driver Page 8 of 25 TEWS 22 TECHNOLOGIES 2 1 2 Dynamic Installation This method allows you to install the driver after the operating system is booted The driver object code is attached to the end of the kernel image and the operating system dynamically adds this driver to its internal structures The driver can also be removed dynamically 2 1 2 1 Build the Driver Object 1 Change to the directory sys drivers xxx tdrv002 where xxx represents the BSP that supports the target hardware 2 To make the dynamic link able driver enter make dldd 2 1 2 2 Create Device Information Declaration 1 Change to the directory sys drivers xxx tdrv002 where xxx represents the BSP that supports the target hardware 2 To create a device definition file for the major device this works only on native system make t002info 3 To install the driver enter drinstall c tdrv002 0bj If successful drinstall returns a unique lt driver ID gt 4 To install the major device enter devinstall c d driver ID t002info The lt driver ID gt is returned by the drinstall command b To create nodes for the devices enter mknod dev tdrv002al c major no 0 mknod dev tdrv002a2 c major no 1 mknod dev tdrv002a3 c major no 2 The major no is returned by the devinstall command If all
16. e the self test is active All other returned error codes are system error conditions TDRV002 SW 72 LynxOS Device Driver Page 16 of 25 TEWS 22 TECHNOLOGIES 3 1 4 TIOCLOCLOOP NAME TIOCLOCLOOP Disables local hardware loop back mode DESCRIPTION This function disables the local hardware loop back mode of the TDRVO002 device There is no argument for this function EXAMPLE include tdrv002 h int result result ioctl Edi TIOCLOCLOOP NULL if result 0 handle ioctl error ERROR CODES Error Code Description EBUSY The device is busy for example the self test is active All other returned error codes are system error conditions TDRV002 SW 72 LynxOS Device Driver Page 17 of 25 3 1 5 TIOSELFTEST NAME TEWS 2 TECHNOLOGIES TIOSELFTEST Performs a local selftest on the device DESCRIPTION This function performs a local selftest on the device A buffer of data 1kB will be sent in local loop back mode The size of transferred data will be checked received characters will be compared with the transmitted characters The transmission will use the standard interrupt functions For RTS CTS DTR DSR RI DCD this function will check both states The function returns an unsigned long value as argument arg containing a detailed result of the selftest The result is an ored value of the following flags defined in tdrv002 h Flag TDRV002 STS TRM TIMEOUT TDRV00
17. eeenneeeen nnne nennen nnn nnns nnne nens 12 TDRV002 DEVICE DRIVER nnns 13 gii 14 31 2 15 3 1 3 a 16 3 1 4 TIOCLOGLOOP 17 3125 tee Cet eec e ete pel cete 18 3 1 6 20 COMMAND LINE TOOLS AND 22 A1 aue rir t a 22 4 2 0 2 zai de 24 dmi CRM eee a ee 25 5 1 Known Problemis 25 5 1 1 Data Loss with Hardware Handshake iunior rts tk rota cusa dd 25 5 1 2 Inconsistent Definitions for Baud 25 TDRV002 SW 72 LynxOS Device Driver Page 3 of 25 TEWS 2 TECHNOLOGIES 1 Introduction The TDRV002 SW 72 LynxOS device driver is a full duplex tty device driver which
18. inary value setting en or disabling every configuration flag The following configuration names are predefined Configuration name Description off rs232 rs422 rs485fdm rs485fds rs485hd transceiver off default RS232 configuration default RS422 multidrop configuration default RS485 full duplex master configuration default RS485 full duplex slave configuration default RS485 half duplex configuration tdrv002config dev tdrv002al rs232 For a binary configuration the second argument must be a column of zeros and ones like a binary value The first character is assigned to bit 7 the last to bit 0 The value has always 8 characters For a binary configuration value the bits are assigned to the configuration flags as described below Bit Description of the bit 7 Auto RS485 Operation 0 disable auto RS485 operation mode 1 enable auto RS485 operation mode 6 SHDN configuration pin 0 transceiver in normal operation mode 1 transceiver in shutdown mode 5 SLEWLIMIT configuration pin 0 disable slew rate limits 1 enable slew rate limits continued TDRV002 SW 72 LynxOS Device Driver Page 23 of 25 TEWS 22 TECHNOLOGIES continued 4 TTERM configuration pin 0 disable onboard termination for TxD line 1 enable 1200 onboard termination for TxD line 3 RTERM configuration pin 0 disable onboard termination for RxD line 1 enable 1200 onboard termination for RxD line 2 RENA configura
19. odules listed below TPMC371 8 Channel Serial Interface TPMC372 4 Channel Serial Interface Conduction Cooled PMC Conduction Cooled PMC TPMC375 8 Channel Serial Interface prog Transceiver Conduction Cooled PMC TPMC376 4 Channel Serial Interface prog Transceiver TPMC377 4 Chan Isolated Serial Interface prog Transcv Conduction Cooled PMC Conduction Cooled PMC TPMC460 2 x 8 Channel Serial Interface PMC TPMC461 8 Channel Serial Interface PMC TPMC462 4 Channel Serial Interface PMC TPMC463 4 Channel Serial Interface PMC TPMC465 8 Channel Serial Interface prog Transceiver PMC TPMC466 4 Channel Serial Interface prog Transceiver PMC TPMC467 4 Channel Serial Interface prog Transceiver PMC TPMC470 4 Chan Isolated Serial Interface prog Transcv PMC continued TDRV002 SW 72 LynxOS Device Driver Page 4 of 25 TEWS 2 TECHNOLOGIES continued TCP460 2 x 8 Channel Serial Interface compactPCl TCP461 8 Channel Serial Interface compactPCl TCP462 4 Channel Serial Interface compactPCl TCP463 4 Channel Serial Interface compactPCl TCP465 8 Channel Serial Interface prog Transceiver compactPCl TCP466 4 Channel Serial Interface prog Transceiver compactPCl TCP467 4 Channel Serial Interface prog Transceiver compactPCl TCP469 4 Chan Isolated Serial Interface prog Transcv compactPCl TCP470 4 Chan Isolated Serial Interface prog Transcv
20. s of the archive TDRV002 SW 72 SRC tar gz to the desired target directory and copy the files into the system tree as described below 1 2 O Extract driver files tar xzvf TDRV002 SW 72 SRC tar gz tdrv002 Create a new directory in the system drivers directory path sys drivers xxx where xxx represents the BSP that supports the target hardware For example sys drivers pp drm tdrv002 or sys drivers cpci x86 tdrv002 Copy the following files to this directory tdrv002 c tdrv002 import Makefile Copy tdrv002 h to usr include Copy tdrv002_info c to sys devices xxx or sys devices if sys devices xxx does not exist xxx represents the BSP Copy tdrv002_info h to sys dheaders Copy tdrv002 cfg to sys cfg xxx where xxx represents the BSP for the target platform For example sys cfg ppc or sys cfg x86 TDRV002 SW 72 LynxOS Device Driver Page 6 of 25 TEWS 2 TECHNOLOGIES 2 1 Device Driver Installation The two methods of driver installation are as follows 1 Static Installation 2 Dynamic Installation only native LynxOS 4 systems 2 1 1 Static Installation With this method the driver object code is linked with the kernel routines and is installed during system start up 2 1 1 1 Build the Driver Object 1 Change to the directory sys drivers xxx tdrv002 where xxx represents the BSP that supports the target h
21. steps are successful completed the TDRVOO2 is ready to use 2 1 2 3 Uninstall dynamic loaded Driver To uninstall the TDRV002 device enter the following commands devinstall u c lt device ID gt drinstall u lt driver ID gt TDRV002 SW 72 LynxOS Device Driver Page 9 of 25 TEWS 2 TECHNOLOGIES 2 1 3 Device Information Definition File The device information definition contains information necessary to install the TDRV002 major device The implementation of the device information definition is done through a C structure which is defined in the header file tdrvOO2 info h This structure contains the following parameter PCIBusNumber Contains the PCI bus number at which the TDRV002 compatible device is connected Valid bus numbers are in range from 0 to 255 PCIDeviceNumber Contains the device number slot at which the TDRV002 compatible device is connected Valid device numbers are in range from 0 to 31 If both PCIBusNumber and PCIDeviceNumber are 1 then the driver will auto scan for the TDRV002 compatible device The first device found in the scan order will be allocated by the driver for this major device Already allocated devices can t be allocated twice This is important to know if there are more than one TDRV002 major devices FIFO Settings Contains the trigger level for receive and transmit FIFO And the transceiver startup configuration for programmable transceivers Valid settings for receive and
22. tion pin 0 enable normal reception default 1 inhibit echo reception for auto RTS 1 HDPLX configuration pin 0 select full duplex mode 1 select half duplex mode 0 RS485 RS232 configuration pin 0 select RS232 levels 1 select RS485 levels For example A value of 01000000 will shutdown the channel The standard RS422 configuration will be set up with a value of 00001001 For user defined binary configuration setting knowledge of an applicable setting is necessary A detailed description about the configuration features and about applicable settings can be found in the User Manual of the TDRV002 supported device tdrv002config dev tdrv002al 01000000 4 2 tdrv002exa This example searches for devices and allows configuration and use of the devices The example may be used for a quick start and as a template for the use of TDRVOO2 devices The example can be started by calling tdrv002exa TDRV002 SW 72 LynxOS Device Driver Page 24 of 25 TEWS 2 TECHNOLOGIES 5 Appendix 5 1 Known Problems 5 1 1 Data Loss with Hardware Handshake The LynxOS terminal manager interface does not indicate if the SW FIFO within the LynxOS terminal manager interface is filled The TDRV002 may insert data into the FIFO although there is no space available Due to this fact there may be loss of receive data although the hardware handshake is enabled 5 1 2 Inconsistent Definitions for Baud Rates For LynxOS 4
23. x there are different header files where the baud rate value definitions like B9600 B115200 are made The definitions are made in termio h and sys ioctl h in a different way To make a correct setting of baud rates it is necessary to use the definitions made in termio h therefore the termio h must be included before sys ioctl h Keep mind that sys ioctl h may also be included by other header files TDRV002 SW 72 LynxOS Device Driver Page 25 of 25

Download Pdf Manuals

image

Related Search

Related Contents

マニュアル - エプソン  JVC Camcorder GY-HM150U User's Manual  FT-LEVULIAU32.FR rev.2  Prova  Manuel - Resol  Combustible Gas Indicator  

Copyright © All rights reserved.
Failed to retrieve file