Home
Philips FMod-TCP BOX Network Card User Manual
Contents
1. The broadcast address depends on the network subnet mask present on your PC FMod TCP User Manual v 2 8 30 58 RS232 interface chain to send gt FMod TCP ressource application 169 254 5 5 Serial 8000 v Open AA ee a ASCII Hex r or Decimal chain m u 102105118101 99111 Bytes received from RS232 The RS232 interface is easy to use Just write the ASCII HEX or decimal string in the dedicated text box and click corresponding Send button The received bytes are displayed into the Data received boxes same data but different representation FMod TCP User Manual v 2 8 31 58 Load web files interface List of files to load 9 FMod TCP ressource application E fel x Connection About Port Load Web Files 8004 y Open Close List of files html jpeg aif class jar PEA This page allows developers to update web files on the FMod TCP l _Addfies _ File s list Remove file How does it work operations User has simply to choose files with the Add files button Clear list and then click on the Load button If you want to remove or update a file or all files use the Remove file or the Clear list buttons Total Length When the web files are ready for production the developer O Bytes ause the Save web to generate a single file than can Status be loaded on the Dearestyethe FMod
2. O search Favorites iMedia 4 Es Ej Address ES http 1169 254 5 5 eo FMod TCP BOX Appletver 1 0 1718 05 06 Test AD and I Os Test RS232 i Test I2C Main config Firmware rev 1 0 MAC address 00 50 c2 30 80 Da IP Address res 254 s subnet mask 255 E o EN TCP timeout 5 30 Device name FMod TEP BOX UART Speed 9600 bas E RC Speed 100 EHz bd Read actual settings Save user settings Restore user settings Restore factory settings Change Change TIR innoaovarcIirae engineer by Fivelo Innovative Engineering 1015 Lausanne Switzerland r Applet FMODTCPBOX started Polo lig Internet y FMod TCP User Manual v 2 8 24 58 Test A D and I Os This page can be used to access Inputs state and voltage and change Outputs State The Inputs state and voltage are regularly updated automatically 20 kHz You can change the low to high threshold of the inputs between O and 24V This page display also the device supply voltage and warnings Too low high supply voltage Outputs driver over current or temperature E BOX FiveCo s TCP IP Controller Microsoft Internet Explorer Oj x File Edit View Favorites Tools Help qa Back mb Inputs State Voltage supply voltage High 10 54 11 94 High 8 52 EE High POY Warnings Lowy 5 62 Low Lowy 451 Lowy 3 66 Lowy 2 424 Low LATY Low 1 87 10 Low 1 40 11 Low 117 12 Lo
3. Loop 5 Convert accumulator in two 6bits words 6 Add those two 6bits words result is 6brts word 7 If an overflow occurs with the last addition Carry add to the last result 8 Last result is the final result Example in hexadecimal USO Z OXFFDE gt 0x0000FFDE Read host 2 34 OXEDCB gt 0x0001EDA9 TransID 10x0003 OxFFFC gt 0x0002EDA5 3 reg to read 10x0A10 OXF5EF gt 0x0003E394 reg 0A 10 02 10x02 00 OXFDFF gt 0x0004E193 Note that in this case a last 00 is implicitly used 02 gt 02 00 0x0004 OxE193 0xE197 carry 0 UxE LOT carry UXEL9Y Checksum 0xE197 FMod TCP User Manual v 2 8 21 58 Here Is an example of a checksum calculation function in C int RetCheckSum Byte ByteTab int Size FI This Function returns the calculated checksum unsigned int Sum 0 bool AddHighByte true unsigned int ChecksumCalculated for int i 0 1 lt Size i 1f AddHighByte Sum ByteTab 1i lt lt 8 0xFFOO AddHighByte false else Sum ByteTab 1 0x00FEF AddHighByte true if AddHighByte false ChecksumCalculated Sum gt gt 16 amp OXFFFF Sum amp OxFFFF ChecksumCalculated ChecksumCalculated gt gt 16 amp OxFFFF Sum OxFF ChecksumCalculated amp OxFFFF return ChecksumCalculated This function needs a Byte array Bytelab containing the command sequence and this arrays length Size as input It r
4. and 0x1 6 RS232CONFIG flow control Read Write configuration aesa nen O Description RS232 baud rate and flow control configuration Bits 0 2 Baud rate configuration Ou 4800 bds 9600 bps default 19200 bps 38400 bps 5 600 bps 15200 bps 15200 bps 15200 bps eserved ardware flow control bit 0 disabled enabled 2 3 4 3 6 R T Default value 9600 bps without flow control FMod TCP User Manual v 2 8 52 58 12C SPeeD 0x18 I2CSPD I2C speed setting Read Write Byte Unsigned Int 8 bits Description I2C speed setting between 39kKHz and 400kHz The value of this parameter must be computed with the following formula based on the wanted speed 10 I2CSPD _ 1 I 2C Speed wanted Note Speeds greater than 00kHz have some limitations see page 7 Do not use a speed greater than 400kHz lt 24 Greater speed will not work Default value 99 100kHz Examples Most common speeds 100kHz I2CSPD 99 400kHz I2CSPD 24 FMod TCP User Manual v 2 8 53 58 TCP CONNECTIONS OPENED Number of ME OxI A TCPCONNECTIONSOPENED connections that Read only are opened ES fu Description Number of users connected to the device using TCP Value can be O to 4 FMod TCP User Manual v 2 8 54 58 ANALOG INPUTS THRESHOLD Register A
5. compatible Example TYPE 0x00080000 means Type 8 FMod TCP BOX Model O FMod TCP User Manual v 2 8 37 58 VERSION VERSION Software ID Read only Register Size Register structure Unsigned Int 6brts HH HL Version Unsigned Int 6brts LH LL Revision Description Firmware identifier composed with a Version and Revision number Same Version with different Revision is backward compatible Example Firmware Ox0001000A Version Revision 10 is compatible with all earlier revisions of the same version ver 1 0 to 1 9 However mt has new functionalities which are deactivated by default or code optimizations FMod TCP User Manual v 2 8 38 58 RESET CPU Function Address Read Write Control Register Size Register structure nit Description Reboots the device The communication will be lost FMod TCP User Manual v 2 8 39 58 SAVE USER PARAMETERS Function Address Function Name Function Read Write Control SAVEUSERPARAMETERS Saves all in EEPROM Description Saves the following parameters to user EEPROM space 0x12 IPADDRESS bel 5 SUBNETMASK 0xl4 TCPTIMEOUT OxI 5 MODULENAME 0x16 RS232CONFIG FMod TCP User Manual v 2 8 40 58 RESTORE USER PARAMETERS Function Address Read Write Control Register Size Register structure Description Restores the following parameters from user EEPROM spa
6. cplt Int 16 HH HL 16 bits fixed point LH LL Description Voltage value of the 16 inputs pins between 12V and 2MY This value saturates at 15 5V and 24V Notes The A D converter has a 10 bits resolution 0 43V The acquisition is done every 850us and is asynchronous with the read access of the A D VALUE registers When you access this register you get the last A D conversion result which can be up to 850us old FMod TCP User Manual v 2 8 Contact address FiveCo Innovative Engineering PSE C CH 1015 Lausanne Switzerland Tel 41 21 693 86 7 Fax 41 21 693 86 70 www fiveco ch info fiveco ch OOOO Innovative engineering 58 58 FMod TCP User Manual v 2 8
7. network and click the Change IP address button That s rt The device has a new address and a new subnet mask the same as your PC They are automatically saved into EEPROM FMod TCP User Manual v 2 8 11 58 You can now connect the device with the Win32 software or open Its web page by typing Its new IP address into a web browser Notes The IP address won t be changed fa TCP connection exists with the device The protocol used to change the IP address is described later in this manual FMod TCP User Manual v 2 8 12 58 4 Controlling the FMod TCP BOX by TCP or UDP General Information All the device s parameters configuration registers and features can be accessed through a TCP or UDP port In addition an HT TP TCP port is available for web pages downloading and another TCP port for RS232 bus access Those ports are CP Port 80 for HTTP communication TCP Port 8000 for RS232 transceiver TCP Port 8010 to access I O registers see chapter 7 and 12C bus UDP Port 7010 to access I O registers see chapter 7 and DC bus With regards to TCP connections the device allows up to 4 simultaneous connections These ports are described below RS232 TCP 8000 The RS232 bus of the microcontroller is accessible through the TCP port number 8000 The module acts simply as a transceiver for this port Any byte sent from the network ex TCP IP from a PC to the module will be sent to the
8. operation Is not guaranteed Parameter Conditions Supply voltage No device connected to extension connector connector Outputs Ind current Outputs 2 voltage Max voltage to GND N ES _Outpuli 3 14 irene HHH EEE EW Outputs 15 l current ______________ Inputs voltage Operating temperature oS Storage temperature S All external pins are protected against destruction by ESD 2kV E a BORA Ea O A CO in O apo gt 3S gt 4 The power supply input is protected against over and inverted voltage by a 33V Zener diode The protection is guaranteed during lOms within the following current values For inverted voltage QQA the internal polifuse will cut the supply For over voltage 3 25A max the diode will be destroyed before the fuse after I Oms Damages to the device due to over or inverted voltage are not covered by the warranty FMod TCP User Manual v 2 8 6 58 2 Overview Applications The FMod TCP BOX is a TCP IP server that allows system integrators to connect different devices such as home appliances industrial sensors and industrial control systems directly to the Ethernet network lUBasel and to remotely monitor and control those using standard protocols It can either be accessed through a TCP socket connection from a computer or through a simple Web Page in a standard browser which can be directly loaded to the device max 44kb The module is deliver
9. other sides RS232 bus and vice versa Thus there Is no particular protocol dedicated to this feature See later chapters to know how to change parameters such as baud rate and hardware flow control Note This port supports only one user at a time RS232 fixed settings No parity Start Bit 8 Data Bits Stop Bit Important note about baud rate greater than 9600bds Common TCP IP stacks on PC Unix station use a delay of 200ms for the acknowledgement of the TCP received data packets This is done to reduce traffic on the network because TCP allows the acknowledgement of several packets at one time Unfortunately the FMod TCP BOX device needs this acknowledgement to remove the data from Its internal RS232 receive buffer if no acknowledge Is received from the PC the module will resend those data FMod TCP User Manual v 2 8 13 58 So With speeds greater than 9600bds the buffer may be filled faster than data can be sent by TCP and part of those will be lost if no RS232 hardware flow control is used between the FMod TCP BOX and the RS232 device CTS and RTS lines If you cannot use hardware flow control on RS232 bus and you have to get more than 2048 bytes at one time the solution is to reduce the TCP acknowledgement delay on your computer For Windows 2000 XP users you can add change the following value in the registry BEWARE improperly changes done in the Windows registry can results in a system crash
10. to design his own software can use this feature to do a quick start install method Indeed since this protocol uses a broadcast UDP packet even if the device Is not in the same subnet It should receive its new IP address and subnet mask Procedure Send a UDP broadcast message using a local or direct broadcast IP address to your network Inside which the FMod TCP BOX Is connected with the following command Byte Number ofits Example __ _ OxOC FMod TCP BOX new IP 4 bytes OxCOA8 064 Address OxlO FMod TCP BOX new 4 bytes OxFFFFOOOO SubnetMask If the FMod TCP BOX recognizes tts MAC address t will answer this command with a simple acknowledges and change its IP address and subnet mask IF NO TCP CONNECTION IS MADE TO THE DEVICE 0x04 Ox 4 0x04 Length of params 0x0000 0x0000 0xl4 Checksum NS its f0x FMod TCP User Manual v 2 8 20 58 Checksum calculation This checksum Is the same as the IP checksum Definition sum of s complement of all 16 bits words of whole message FiveCo packet except checksum bytes Note all values are unsigned Sequence Clear accumulator Loop x Only if last word Is not made of two bytes the data byte Is the upper byte big endian 2 Compute s complement of each 6bits word result is 6bits 3 Convert last result from 16 bits to 32 bits result is 32bits 0x0000 last result 4 Add last result to the 32 bits accumulator Try the
11. 4 5 5 UNO A O This device is not intended to be used in a medical life support or space product Any failure of this device that may cause serious consequences should be prevented by implementation of backup systems The user agrees that protection against consequences resulting from device system failure is the user s responsibility motion fiveco ch www fiveco ch The Ethernet MAC Address Is fixed and cannot be changed The IP Address can be changed The complete procedure is described below Note If the device has already been configured and the IP address has been changed to an unknown value you can retrieve an SOS IP address the one on label by pressing the SOS button during the normal operation of the device See section Erreur Source du renvoi introuvable Changing IP address To easily change the factory IP address use the Win32 software provided on the CD Rom A W MN ON UM Plug your new device on your PC network Start the Win32 application Click on File gt Easy change IP address The software will scan the network and display a list of all FiveCo s devices found Select the MAC address corresponding to your new device f you have more than one network adapter on your PC the software will ask you to select the one which Is connected to the same network as the FMod TCP BOX The software will suggest a new IP address with the last byte left open Choose a new IP Not already used on your
12. 636 Information Over 32 V 0x00200000 the overvoltage warning bit is set and the overvoltage protection diode should increase power current Below 2 V 0x000C0000 the undervolatge warning bit Is set Below effective 6 5 V 0x00068000 this value has no meaning Active Each time the processor is running FMod TCP User Manual v 2 8 44 58 WARNING 4 Byte Unsigned Int 32 bits each bit independent Description Each information warning error is contained in 2 bits the first one from LSB to MSB shows the actual state the next one shows if this state appeared previously Only the bits that show the past states can be cleared by writing 0x00000000 to WARNING register OI Over temperature occurred on outputs stage E E Over current occurred on outputs stage Under voltage of the power input Over voltage of the power input Other bits are reserved If any warning bit Is set the LED on the SOS button will become red Default value bits 31 gt 0 0x00000000 Active Each time the processor Is running FMod TCP User Manual v 2 8 45 58 COM OPTIONS options 4 Bytes 32 individual bits Description This register Is reserved for future use FMod TCP User Manual v 2 8 46 58 ETHERNET MAC ETHERNETMAC an IIS adon CN CS Description A standard hardware unique identifier worldwide for each device on an
13. Ethernet network Note If the user writes into this register the MAC address will not be modified This register is available only for informational purposes FMod TCP User Manual v 2 8 47 58 IP ADDRESS 0x 12 IPADDRESS IP network ID Read Write 4 Bytes 4 x Unsigned Bytes Description Network identifier used for TCP IP and UDP P The values 255 OxFF and O 0x00 are reserved for broadcast and network addresses and should not be used In this register Notes The module will change for a new IP address only when all of its communications ports are closed Do not forget to use a SAVEUSERPARAMETERS command Default value 169 254 5 5 Example For the IP 192 168 16 14 0xC0 0xA8 0x10 Ox0E write OxCOA8 IOOQE to IPADDRESS FMod TCP User Manual v 2 8 48 58 SUBNET MASK 0x 13 SUBNETMASK IP subnet mask Read Write 4 Bytes 4 x Unsigned Bytes Description Network IP subnet mask used for TCP IP and UDP IP Notes The module will change for a new subnet mask only when all of its communications ports are closed Do not forget to use a SAVEUSERPARAMETERS command If you do not want to use subnets use the following subnet mask when IP address byte O Is gt 0 and lt 127 253000 Class A addresses gt 2 and lt 19 255 255 0 0 Class B addresses gt 19l and lt 223 253 255 255 0 Class C addresses Default value 255 255 0 0 Exa
14. FMod I CP User Manual v 2 8 15 58 Write register s command Byte Number of bits Example Write 0x0022 0x0022 0x1 B34 0x04 Number of bytes In 6 bits 0x0003 command Register Addresses 8 64 bits 0x1234 The two previous entries are replicated for every register that has been asked for reading Checksum NG ts OK The max length of this sequence is 180 bytes The module answers with the nina he sequence Byte t Write Answer ET TT 0x0024 0x02 TransactionlD same as 6 bits Ox B34 demand 0x0000 0x0000 I2C feature The Inter IC bus commonly known as the IC bus is a control bus that provides the communications link between integrated circuits in a system Developed by Philips in the early 1980 s this simple two wire bus has become the de facto worldwide standard for system control finding its way into everything from temperature sensors and voltage level translators to EEPROMs general purpose l O A D and D A converters CODECS and microprocessors of all kinds You can find the 2C s specifications on the Philips web site at the following link http www semiconductors philips com The 2C protocol can access a device by three different manners Write Start AddW Byte Byte2 Stop Read Start AddR Byte Byte2 Stop Read After Write Start AddW ByteW I ByteVW2 ReStart Addk ByteR ByteR2 Stop St Addw A Bytestow RIA AddR AT Bytest
15. RO DEAD O a vonee esp neReTente pee retnetT oneeerT re ee ener ener re reTe 6 BORG Gone os el gible a APPEAR arene tent O 7 A a E ee E NETE OEE ETNE J Se A ETTE OT 10 TEI SI Paade 5 cased pa SD eee aceite lO A Controls Ine ro PE BOK Dy TGP Or Y Dc 2 General ORAGO ai ll oda dida 2 A TC A a a n ee tert cere ere ee 2 Device parameters and I O A D and DC features TCP 8010 or UDP 7010 13 Easy address CONS I LOTO re dl 19 Sisa o o II ee ee 20 O 22 DEN a dd N 22 A A E T N E A EE EE E E A A E 23 Ao o E PO E a 24 A e a eee 23 ACO a E ee ee ee eee eee 26 ANID L DUC AGI ON oe ie a hee eel eed ewes Dh ent E itera 28 OVAs 28 A EE A E E O ad fd ih 30 rocio RR RR RR gt PIROPO A AA Pe S SA TAS MNE CI DO trata las a4 MENTA o ter A A A A eat E A E rea try SA PARRES i RP CS ED OE A bis FMod TCP User Manual v 2 8 4 58 Revision history Revision Date Author Note Firmware Applet Win32 app version version version 10 050506 DSO es MO MO ei Text corrections Warning register bits correction FMod TCP User Manual v 2 8 5 58 Package and operating conditions Starter Kit contents The FMod TCP BOX Starter kit should contain FMod TCP BOX device RS232 DSub cable DIN 41651 40 lines cable CD Rom with dedicated software and Java applet sample This manual Absolute maximum rating Damage may occur If the device is operated using values beyond those mentioned below device
16. See page 10 for quickostart Ethernet Converter Device FMod ICP BOX User Manual Version 2 NOOO e innovative engineering 2 58 Version 1 2 Last revision August 4th 2006 Printed in Switzerland O Copyright 2003 2006 FiveCo Sarl All rights reserved The contents of this manual may be modified by FiveCo without any warning Trademarks Windows is a registered trademark of Microsoft Corporation Ethernet is a registered trademark of Xerox Corporation Java is a registered trademark of Sun Microsystem Philips is a registered trademark of Koninklijke Philips Electronics N V Borland is a registered trademark of Borland Software Corporation Warning This device is not intended to be used in medical life support or space products Any fallure of this device that may cause serious consequences should be prevented by implementation of backup systems The user agrees that protection against consequences resulting from device system failure is the user s responsibility Changes or modifications to this device not explicitly approved by FiveCo will void the user s authority to operate this device Support Web page http www fiveco ch section_motion support_motion_E htm e mail support fiveco ch FMod TCP User Manual v 2 8 3 58 Table of Contents Fac ss ana Operas CONNOR despedida aio gt RARE A A tet een E E ere eee 5 ABONENT a O ea E E E 5 NO 6 ND BN ONO ne O ED A E eee eee 6 SORA
17. Such changes are the users full responsibility Entry HKey_Local_Machine SYSTEM CurrentControlSet Services TepiplParameters Interfaces Interface name Key TcpDelAckTicks Value DWORD with value Ox00 The interface name is the registry name 32 digits number of your Ethernet card which you use to access the module The following web page describes this feature in details http www microsoft com resources documentation Windows 2000 server reskit en us regentry 5880 asp frame true Device parameters and I O A D and 12C features TCP 8010 or UDP 7010 EEE See eee ee e The main TCP port number 8010 or UDP port number 7010 can be used to change some important parameters of the module TCP timeout value IP address Subnet mask Module name Baud rate and flow control I2C speed The user should use the Win32 application enclosed in the package or the default java applet loaded in the module to change those parameters If the user wants to change the parameters by himself the protocol is defined below This port is also used to access Inputs and Outputs value A D conversion result registers see page 34 for a complete description of those registers and I2C bus The I2C feature Is described after registers access feature The last feature accessible through this port Is the Easy IP config that Is used in the Quick start chapter of this document FMod TCP User Manual v 2 8 14 58 Registers access f
18. TCP firmware upgrader software or a custom software Number of bytes in list Save web Create file for factory upload Load Load files into module Connected This option allows users to load their personal web files html java jpeg gif txt Into the flash memory A maximum of 44kB is available for that application An example of pages and Default Java Applet code Is available on the Starter Kit CDRom or on the FiveCo s web page For factory web upload the user can save a single file yourname web See FMod TCP BOX_WebPageUploading manual on the FiveCo web site FMod TCP User Manual v 2 8 Main port interface 32 58 gt FMod TCP ressource application f 215 x Connection About Connection IP 169 25455 Port Main 8010 y Open Close Change RS232 o Hanipol Vera 10 A D converters Input Output Outp uts N State Voltage N State Voltage N Output N Output state C hange Enable flow control 2 Y 8 6 4 A te 1 5 E l 3 M 6 9 4 tt ja 1 2 lt og U i TCP timeout disconnection E 4 o 56M T Inputs state timeout Es Change sr 45M 37 oM 5mar and voltage Addie sr 37M 14 FP osm 6 FP ow y rl E 2 9 4 15 fa 0 3 4 gt E Co M Change IP fes asa 5 f Change 8 F 23M 16 F M IN address of the Subnet Mask i Analog threshold j 6 0 Read Write module ss 55 fo fo as errei is Chan ge 12C port subnet mask foo Jez 30 fe
19. available on the FiveCo s web site can help programmers get started with development Hardware description eS Power connector 7 12 32 VDC Ka Inputs Outputs I2C bus Supply voltage 5V and GND 3 RS232 connector P Dimensions in mm Ethernet connector SOS button Beware Before connecting any cable to the device shut down power supply Front view y RJ45 Ethernet connector SOS button FMod TCP User Manual v 2 8 8 58 See page 9 to know how the SOS button works Two LEDs illuminate the SOS button and the displayed color as the following meanings Green Everything Is normal Red There is an error See Warning register to know the source of the error Red Green The device found another one with the same IP address blinking on the network Disable the other device and reboot the FMod TCP BOX Left side Power connector Inputs Outputs 12C Supply voltage 5V and GND ut 12 342 VDC O 5 C C C a OJO O O OJOJOJO O JO alalalalols olalals O O o fo to fo fo fo fo fo C y jcyCyC YC O EO O E TU C WW 5 Output 2 B relay 2 16 Input 16 36 Output 2 A relay 2 17 5V 37 Output B relay 18 GND 38 Output A relay 19 I2C clock SCL 39 Supply GND I2C data SDA 40 Supply voltage max A Do not supply the device through this pin Use power connector Here are the eq
20. cally those sequences to DC sequences It is mandatory that the sequence has to be transmitted within one TCP packet Otherwise the FMod TCP BOX will ignore tt 2C Bus scanning The following command allows user to ask an I2C bus scanning to list which addresses answer with an acknowledge 12C scan command po Number of bits Example po Number of bits Example 2 CScanAnswer 0x0006 0x0006 6 bits 0x200 Number of valid addresses 0x000 Valid addresses list Note If there is no address in the PC Scan command the FMod TCP BOX will scan all addresses between and 127 12C speed change advanced features The 2C bus speed can be changed at any time by changing the content of the 2CSPD parameter Beware Do not change I2C speed if It Is not mandatory Speed greater than OOKHz are not supported by all I2C slaves 2 Do not change PC speed during 2C communication FMod I CP User Manual v 2 8 18 58 3 The I2C controller does not match all I2C specifications at speed higher than OOKHz This feature will therefore not work with all PC slaves The value of the I2CSPD parameter must be computed with the following formula 10 I2CSPD _ 1 I2C Speed wanted The I2C speed cannot be saved in EEPROM FMod TCP User Manual v 2 8 19 58 Easy IP address config UDP 7010 A really useful feature of the UDP port 47010 Is the Easy IP config one The user who wants
21. ce 0x12 IPADDRESS Ox 3 SUBNETMASK O TEPTIMEOUT Ox15 MODULENAME 0x16 RS232CONFIG FMod TCP User Manual v 2 8 41 58 RESTORE FACTORY PARAMETERS Function Function Name Function Read Write Control Address RESTOREFACTORYPARAMETERS Factory default Register Size Register structure Description Restores the following parameters from factory EEPROM space OxI IPADDRESS Oxl3 SUBNETMASK Oxl4 TCPTIMEOUT 0x1l5 MODULENAME Oxl6 RS232CONFIG Note SAVEUSERPARAMETERS should be performed after this function in order to save restored parameters as user parameters FMod TCP User Manual v 2 8 42 58 SAVE FACTORY PARAMETERS Function Address Read Write Control Register Size Register structure Description Saves the following parameters to factory EEPROM space Oxl2 Oxl3 Oxl4 Oxl5 Oxl6 Note IPADDRESS SUBNETMASK TEPTIMEOUT MODULENAME RS232CONFIG This feature should only be used by a system Integrator that would change the initial factory default settings FMod TCP User Manual v 2 8 43 58 VOLTAGE 0x07 VOLTAGE Power input voltage Read only 4 Bytes Signed 2 s cplt Int 16 HH HL 16 bits fixed point LH LL Description Input Voltage Limits Max Ox FFFFFFxx 32 7 6 996 Min 0x000000xx 0 0 Step 0x00000 xx 0 004 Example When read 0x00234567 2311527 Voltage 35 27 231 1527 655
22. ddress Register Name Function Read Write Control AD converter 0x20 ANALOGINPUTSTHRESHOLD threshold on Read Write inputs CC CU Signed 2 s cplt Int 16 HH HL 16 bits fixed point LH LL Description Defines the threshold used by the AD converter on Inputs pins to define input state as low or high 0 or Default 6 0 V Example If your inputs use 5V TTL signals set this value between and 4 V FMod TCP User Manual v 2 8 55 58 INPUTS 0x2 INPUTS Read only 2 Bytes Unsigned Int 16 bits each bit independent Description Show digital state of each inputs pin The state Is defined by comparing actual input voltage with the ANALOG INPUTS THRESHOLD INPUT 4 Example b 0000 0000 0000 0111 gt Inputs number 2 and 3 are high and others are low FMod TCP User Manual v 2 8 56 58 OUTPUTS 2 Bytes Unsigned Int 16 bits each bit independent Description Controls the state of each of the output pins Bit 2 Bit 3 Bit 4 Bit 5 Bit 6 Bit 7 Bit 8 Bit 9 Bit 10 Bit Bit 12 Bit 13 Bit 14 Example b 0000 0000 0000 O11 gt Outputs number 2 and 3 are high and others are low FMod TCP User Manual v 2 8 57 58 INPUT VOLTAGE x VALUE Registers Register Name Function Read Write Control Addresses 0x30 to 0x3F INPOTVOLTACERALUE SIA dany conversion result omen fumar CU Signed 2 s
23. e user has to choose between an DC Read or Write operation In Write mode the bytes in hexadecimal like 41 42 45 separated by spaces must be written in the dedicated line and the I2C address in the dedicated Address space in hexadecimal or in decimal Then click Send In Read mode the steps are the same except that the user must specify how many bytes have to be read Data to write Is optional only used for ReadAfterWrite I2C method FMod TCP User Manual v 2 8 34 58 Registers management Memory Organization The user must know that a new register value sent through the communication port Is loaded to the running parameters in RAM and used for the current process All these parameters are lost upon power down It Is required to save them to User Parameters or Factory Parameters with the corresponding function EEPROM EEPROM ROM USER Parameters FACTORY Parameters SOS IP address RUNNING Parameters Action Number and description SaveUserParameters 0x03 function O During standard power up or calling RestoreUserParameters 0x04 function RestoreFactoryParameters 0x05 function 4 A 1 SaveFactoryParameters 0x06 function For Integrators engineers only By setting SOS Jumper after power up E 1 By setting SOS Jumper during power up FMod TCP User Manual v 2 8 35 58 Full Register Description List of registers Address Bytes Name General Informa
24. eature TCP IP works in big endian most significant byte first followed by least significant byte The access to the data is done through an easy 6 byte header protocol over ICP Structure of each packet Function ID 2 bytes Transaction ID 2 bytes Length of the parameters 2 bytes Parameters X byte Checksum 2 bytes described later in this chapter NA uN The user sender defines the values of the Transaction IDs himself The module that receives a command sends back an answer for every command The answer contains the same Transaction ID as the corresponding command sent The user is also able to check execution of each command Read a command Byte Read Raon 0x002 0x1B34 0x04 Number of registers to 6 bits 0x000 read X X Registers Addresses 0x06 X The maximum number of registers that can be read at one time Is almost 30 The answer sequence should not be greater than 180 bytes If the number of registers Is too big the FMod I CP BOX will answer only with the value of some of them The module answers with the paca is sequence ByteH Read Answer EFE CU 0x0023 0x02 TransactionlD same as 6 bits Ox B34 demand Number of bytes in answer 0x0019 0x06 Register address 8 bits 0x02 0x06 Reg Register value 8 128 bits 16B 0x12345 The two previous entries are replicated for every register that has been asked for reading m Checksum NG its TOx
25. ed with a default web page including a Java Applet that enables the controlling of the device The connection between this device and the user s product can be done through the following interfaces RS232 Up to 115200 bps with or without TCP 8000 hardware flow control Cut up to 50V IA 24V Outputs High side drivers TCP 8010 24V Inputs Digital 24V inputs or analog 12 V I2C bus 2 wires bus serial bus Note Some examples of applications illustrating the use of the FMod TCP family with serial 12C I O and A D devices can be found on the FiveCo s website http www fiveco ch section_motion tcp_db real_tcp_E htm Software operating principle The operating principle for PC softwares that must exchange data with an FMod TCP BOX device depends on which interface Is used In case of RS232 use the operation is really simple Any byte sent to port TCP 8000 will be redirected to the serial bus and any byte received from the serial bus will be redirected to the TCP connection In the other cases I O A D and I2C the software has to use a dedicated protocol layer on top of the TCP Layer see chapter 4 This protocol Is FMod I CP User Manual v 2 8 7 58 Question amp Answer oriented The PC should send a Question wait for the Answer and so on To configure the device s parameters and to access I O and A D features the protocol uses an Internal Registers Access routine see chapter 4 and 7 The code samples
26. eturns the checksum as an Int FMod TCP User Manual v 2 8 22 58 5 java Applet A specific Java Applet Is provided with the module to control any of its ports without having to write any specific code Overview To connect to the http server on the device simply open your web browser and type the IP address of the module Example with default address httb 169 254 5 5 The applet is downloaded from the device to your computer and runs as a local process on your computer You need to use an internet web browser that is compatible with Java 1 1 Please note that on an MSWindows based computer a few seconds delay can occur when you download the applet due to an MSWindows NetBios issue The navigation through the four panels of the applet is done through the menu bar Test AD andOs E TestRS232 E Test 2c FMod TCP User Manual v 2 8 23 58 Main Config The Main panel shows the general information related to the device e The first part allows the user to change the main settings of the device Don t forget to use the Save user parameters button to make changes permanent The second part allows the user to save restore user and factory parameters and to read the actual configuration of the device If it has been modified by another application 3 FMod TCP BOX FiveCo s TCP IP Controller Microsoft Internet Explorer File Edit View Favorites Tools Help Back amp fat
27. ific code Overview 2151 Connection About Connection IP address of FE Port Load eb Files 8004 y the module Open or close TCP port TCP port number Depends on port Connection Status Disconnected To open a TCP port on the module the user has to set the correct IP address of the module to choose the correct TCP port in the list and to click on the Open button To close the port simply click on the Close button The status bar displays the status of the connection Connected Disconnected Error of connection tf connection was not established within 30s Note If you forgot the IP address of the module you can use the Scan network feature of the Connection menu FMod TCP User Manual v 2 8 29 58 Scan devices E x IF Scan address 755 755 255 255 State UDP Scan finshed List of connected devices MAC Address IP Address O00 50 C2 30 80 00 132 166 716 100 1 0 5 10 FMod TCP This application uses the IP address of your computer and its subnet mask to find the scan broadcast address When you click on scan a broadcast message will be sent to all devices in your subnet and answers will be listed WARNING It only works with devices in your subnet How does It work When you click Scan the software simply sends a Read registers command to a broadcast address on UDP port number 7010 see chapter about main port at page 13
28. mple For the IP 10 2 6 45 and subnet mask 255 255 0 0 IP address class A gt netID 10 subNetID 2 and hostlD 6 45 FMod TCP User Manual v 2 8 49 58 TCP TIMEOUT TCPTIMEOUT Timeout for TCP Read Write connection CN CU Description The TCP timeout is a value in seconds after which the user will be disconnected if the device has not been accessed in the meantime If the value is O the TCP timeout is deactivated In this case however If the client crashes during connection the communication will never be closed on the module s side Because a maximum of 4 communications are allowed at the same time on the module one of them will be blocked If the client crashes four times all of the 4 communications will be blocked and the module will have to be reset The timeout for each TCP IP connection is reloaded when there is traffic through the port Default value 30 Limitations Max value 255 FMod TCP User Manual v 2 8 50 58 MODULE NAME MODULENAME e s ASCII Read Write CA que 6 Bytes 16 only x Unsigned Bytes CHAR Description Name and or description of the module Example For the name Hello Module extend to l6 byte the name Hello Module 5x space 16 Byte So write Ox48656C6C 6F204D6F 64 56C65 20202020 FMod TCP User Manual v 2 8 51 58 RS232 CONFIG Register Address Function Read Write Control RS232 baud rate
29. o Jos grid a Scan I2C of the module Read Number of byte to read 1 Bie Change C Write Hex Data to write ex 42 3F AOS Module MAC 1 7M C Rw ack NQC Address Fbits Ox i Number of address Low voltage Read Data received bytes to read from Read actual settings Save user settings 3 DC Change _ Read actual settings gt nd module Restore factory settings Restore user settings Es T name AAA AAA Hex data to Connected NO NI writeto Bytes received from RC 2C operation 2C Address The configuration interface allows the user to change the device s settings RS232 baud rate The user can change the RS232 baud rate and enable or disable the hardware flow control CTS RTS TCP timeout IP address Subnet mask MAC address Name The user can change the number of seconds allowed before TCP port Is disconnected This feature avoids the problems due to the crash of a TCP client PC The user can change the IP address of the module The user can change the subnet mask of the module Mac address of the module cannot be Module name changed The Inputs state and voltage are simply obtained with a click on the corresponding Read button The Outputs state and the analog threshold are send to the device with a click on the corresponding Write button FMod I CP User Manual v 2 8 33 58 The DC interface is an easy way to test the I2C connection between the module and the user s electronic Th
30. oR I nAlSp FMod TCP User Manual v 2 8 16 58 To be able to do all of these 3 sequences use this command Byte Numberofbits Example I2CRWwithAck 0x0007 0x0007 0x1B34 0x07 X number of bytes to write 8 bits 0x08 xBytes X bytes Y number of bytes to read 8 bits _ 0x05 The four previous entries can be replicated to access the same or other I2C slaves within this command sequence pL Checksum l6bis OK If X O the Read method Is used If Y O the Write method is used FX amp Y 0 the Read after Write method Is used 0x07 0x08 The answer sequence Is the following one Byte Number of bits Example 2 CReadAnswer 0x0008 0x0008 demand Ox A25 Ack state of the I2C com If the same or other I2C slave have been accessed state Is added here in the command the answer bytes and ack Checksum 16 bits The Ack state byte is composed of the following bits eee ack received PP ma ack received 2 Address ack In read sequence O No answer to this address ack received Must be always EN The user can use these bits to check for the presence of his 12C devices and monitor hardware Issues FMod TCP User Manual v 2 8 17 58 Note that the max length of those sequences is 180 bytes Pay close attention to building sequences that do not exceed this and not to ask too much byte in answer The FMod TCP BOX translates automati
31. tion 0x00 00 4 TYPE 0x0 01 4 VERSION 0x02 02 O fct RESETCPU 0x03 03 O fct SAVEUSERPARAMETERS 0x04 04 O fct RESTOREUSERPARAMETERS 0x05 05 O fct RESTOREFACTORYPARAMETERS 0x06 06 O fct SAVEFACTORYPARAMETERS 0x07 07 4 VOLTAGE 0x08 08 4 WARNINGS Communication Ox10 16 4 COMOPTIONS Ox CIZ 6 ETHERNETMAC 0x12 18 4 IPADDRESS Oxy 4 SUBNETMASK 0x14 20 TCPTIMEOUT OKZ 16 MODULENAME 0x16 22 RS232CONFIG 0x18 24 IZESPD xIA 26 TEPCONNECTIONSOPENED I Os and AD 0x20 32 4 ANALOGINPUTSTHRESHOLD Dei us 2 OUTPUTS UXZ3 39 2 INPUTS Analog voltage at inputs 0x30 48 4 INPUTVOLTAGEOVALUE 0x31 49 4 INPUTVOLTAGE VALUE 0x32 50 4 INPUTVOLTAGE2VALUE 0x33 51 4 INPUTVOLTAGESVALUE 0x34 52 4 INPUTVOLTAGE4 VALUE 0x35 53 4 INPUTVOLTAGES5 VALUE 0x36 54 4 INPUTVOLTAGES6 VALUE ETA 4 INPUTVOLTAGE 7VALUE 0x38 56 4 INPUTVOLTAGESVALUE 0x39 57 4 INPUTVOLTAGE9VALUE Ox3A 58 4 INPUTVOLTAGE OVALUE 0x3B 59 4 INPUTVOLTAGE VALUE Ox3C 60 4 INPUTVOLTAGE 2VALUE Ox3D 61 4 INPUTVOLTAGE 3VALUE Ox3E 62 4 INPUTVOLTAGE 4VALUE Ox3F 63 4 INPUTVOLTAGE 5VALUE FMod TCP User Manual v 2 8 36 58 TYPE Register Size Register structure Unsigned Int 6brts HH HL TYPE Unsigned Int 6brts LH LL MODEL Description Product identifier composed with a Type and Model number It defines which kind of peripheral it Is Normally different modules TYPE are not software
32. uivalent electrical specifications of I O pins illustrated by black dots Inputs Outputs 2 Outputs 3 16 f A a 47k0 17 A es 2m FMod TCP User Manual v 2 8 9 58 The PC pins are provided through a Philips PCA9512 driver chip 10kQ pull ups are connected to SCL and SDA Right side 67 amp ee eee Te comedo tt Nc et NC A eceive data 7 Request To Send male like on a computer 3 Transmit data 8 Clear To Send A NC OON The RS232 connector is the same as the ones found on any computer SOS button A button Is dedicated to restore default IP address or factory settings There are tow possible scenarios f you press tt while the device is running the IP address will be restored as soon as all TCP connections are closed Warning you have to send the Save Settings command to the device in order to save it into EEPROM f the button is pressed during startup the default IP address and factory settings of all parameters will be restored AND saved into EEPROM In this case you do not need to send the Save Parameters command FMod TCP User Manual v 2 8 10 58 3 Quick start This section is intended to help users to quickly plug the module into their system and establish a connection between the computer and the device You can find the devices factory communication settings on the following label FMOD TCP BOX INPUT supply 5 32V DC max 3A E MAC 00 50 C2 30 xx xx IP 169 25
33. vided in two parts The part on the right allows scanning the DC bus to find available slave devices The part on the left allows sending a read or a write command to a device on the I2C bus 3 FMod TCP BOX FiveCo s TCP IP Controller Microsoft Internet Explorer File Edit View Favorites Tools Help se Back E gt 2 fut 0 Search a Favorites ey Media E3 ie Address ioe Go FMod TCP BOX Applet ver 1 0 18 05 06 Test AD and liQs Test RS232 I Test 12C TR IC O E O Read Mumber of bytes to read O Scanbus bus Write Hex data to write ex 42 aF RO devices found IZ address Thits hexa Data received send 00000 innovative engineer y Fivello Innovative Engineering 1015 Lausanne Switzerland E E Applet FMODTCPEOX started lo iy Internet You should first check if you want a read or a write Then you have to write hex data to write to the device In the Hex data to write field if you FMod TCP User Manual v 2 8 27 58 checked the Read box the FMod TCP BOX will use the read after write I2C feature After writing the I2C address bits hexa and the number of bytes to read if applicable click on the Send button The answer Is displayed in hex in the Data received field FMod TCP User Manual v 2 8 28 58 6 Win32 Application A specific application is provided with the module to control any of its ports without having to write a spec
34. w 0 90 13 Low 0 57 q4 Low 0 46 15 Low 0 26 16 Low 08 Analog threshold 4 6 0 JOJO ma o a ua ua Clclcliclicicio a a El lE E 4 4 4 4 4 4 4 Be on innAoaw racthlyYe engineering by FrreCo Innowvatrre Engineering 1015 Lausanne Switzerland EE E Applet FMODTCPBOX started Polo lo E nternet F FMod TCP User Manual v 2 8 25 58 Test RS232 This page can be used to access RS232 bus If you click on the Connect to RS232 TCP Port you can send ASCII data to RS232 bus and receive data from it only ASCII Is visible in this application 3 FMod TCP BOX FiveCo s TCP IP Controller Microsoft Internet Explorer File Edit View Favorites Tools Help Back fx at EA Search 35 Favorites eMedia a Es a E B Address E http 169 254 5 5 60 FMod TCP BOX Appletver 1 0 18 05 06 Test AD and Os ESTA Test UART Connectto UART TCP port Transmitto UART Not connected Add LE Daddcr Dada NULL Send Receive from UART JOJOJOJO innovratrclrae engineer by FrreCo Innovatrre Engineering 1015 Lausanne Swatzerlane E Applet FMODTCPEOX started AEE You can check Add LF Add CR and or Add Null boxes to add a Line Feed a Carriage Return and or a Null Byte at the end of the ASCII chain sent to the device FMod TCP User Manual v 2 8 26 58 Test 12C This page can be used to access I2C bus The panel is di
Download Pdf Manuals
Related Search
Related Contents
LEICA DIGILUX 2 User`s Manual Evaluation hybrider Expertensystemtools - Segshop 安全上のご注意 1 Copyright © All rights reserved.
Failed to retrieve file