Home

Linux Auto-Run User Manual

image

Contents

1. Chapter 3 Applications Supported through Auto Run Function 10 3 1 Process M nitOl sssini ccostenereteveiwnansdeteustadsbacestcetestcetdeatentianenstes 10 3 2 Modbus Gateway Optional 11 Chapter 4 EEN REE EE 12 4 1 Pictures amp Notices Index riad miennes 12 4 2 Linux CONTAINS ia i i l nen 13 4 3 Customer Service nunaune anemi dekke ASE EAEE REA 14 Korenix Overview Chapter 1 Overview The auto run function is an advanced feature provided in the SW v1 3 release of JetBox 9300 9310 This function allows customers to run specific configuration or run specific applications in the JetBox 9300 0310 automatically The auto run configuration or application can then be stored onto a SD card There are two ways to apply the auto run function Configured by customers autorun sh file Software service provided by Korenix CUST file Configured by customers Insert the SD card into the JetBox and reboot the JetBox to run the configuration or the applications autorun sh file 1 The content of autorun sh must be written in Linux shell command 2 The content must be executable in Linux Software service provided by Korenix CUST file 1 The content is written by Korenix according to customers requirement 2 The content is encrypted by Korenix A notice 1 Each SD card has its own CUST file and CANNOT be interchanged with other 9300 Series JetBox when written by Korenix A notice 2 If both autorun sh and CUST files were i
2. Notice 9 If the command of process monitor is incorrect or the monitored processes are improper it might keep the process monitor checking in ah unlimited 160p i sia ini i i eet 10 Notice 10 In SW1 3 the process monitor could only support one add on parameter after the process name In later SW version all add on parameters can be supported 10 4 2 Linux Commands WLAN related Linux commands Linux commands Description iwconfig Iwconfig is similar to ifconfig but is dedicated to the wireless interfaces It is used to set the parameters of the network interface which are specific to the wireless operation for example the frequency Iwconfig may also be used to display those parameters and the wireless statistics extracted from proc net wireless All these parameters and statistics are device dependent Each driver will provide only some of them depending on hardware support and the range of values may change iwlist Iwlist is used to display some additional information from a wireless network interface that is not displayed by iwconfig The main argument is used to select a category of information iwlist displays in detailed form all information related to this category including information already shown by iwconfig Iwspv is used to set a list of addresses to monitor in a wireless network interface and to read back quality of link information for each of those This information is the same as the one available in proc ne
3. port ON iocmd dio_no i ioctl fd SET DO amp iocmd sleep 1 for i 0 i lt 4 i set port OFF iocmd dio_no i ioctl fd CLR_DO amp iocmd sleep 1 exit close fd Functional Description Korenix return 0 Compile this source code into the executable file for the JetBox A notice 8 You will need the JetBox 9300 9310 SDK to compile the application source code Content of the autorun sh file to execute the demobox application mnt card boxdemo amp Store the demobox application and autorun sh file onto a SD card then insert the card into the JetBox and reboot When the system is ready it will execute the demobox application automatically 2 4 Example II WLAN Setting Below is an example for WLAN setting through autorun sh file It will enable the attached Ralink IEEE802 11b g USB dongle and assigns the static IP 192 168 1 84 and the gateway 192 168 1 1 to the JetBox to link to the Korenix3 wireless AP Typically you would enter the JetBox Linux environment and set up the WLAN through Linux commands however you can now write these WLAN setting commands in the autorun sh file so it may execute automatically after the JetBox boots up Content of autorun sh for the WLAN setting ifconfig rausbO up iwconfig rausbO key xxxxxxxxxx iwconfig rausbO essid korenix3 sleep 2 ifconfig rausbO 192 168 1 84 route add default gw 192 168 1 1 Korenix Functional Description Lo Store t
4. run in the JetBox 000 5 Notices Notice 1 Each SD card has its own CUST file and CANNOT be interchanged with other 9300 Series JetBox when written by Korenix rrrrrrrsvrrvrnre 4 Notice 2 If both autorun sh and CUST files were inside one SD card the system applies autorun sh file first and then CUST file The system keeps the CUST setting if there were any conflicts between autonrun sh file and CUST file 4 Notice 3 After the JetBox 9300 9310 SW version1 5 the system will transfer the autorun sh file format to UNIX automatically before executing IT 3235280 lens rt sante der tn re set naiss E ara ini ee lee 5 Notice 4 The content of autorun sh file must be written in Linux shell command and is ex cutable nine tretiurredauends 5 Notice 5 The autorun sh file must be UNIX text file format You can use the text editor For example metapad associated in the JetBox 9300 9310 CD ROM to write the content of autorun sh sse 6 Notice 6 Each SD card has its own CUST file and CANNOT be interchanged with other 9300 Series JetBox when written by Korenix 6 Notice 7 The new autorun sh file must exist in TFTP server otherwise the Appendix Korenix update will not succeed and a warning message will pop up 6 Notice 8 You will need the JetBox 9300 9310 SDK to compile the application source code rrrnnnnnnnnrvnrnnrrnannnnnrnnnnnsrnsnnnnnnnnnsnssnsnnnnnnnnrsnnsnne 9
5. Customer service koreCARE korenix com Appendix Korenix
6. Ul and a system check for an SD card If the system check locates an SD card the autorun sh file or CUST file will execute automatically A notice 4 The content of autorun sh file must be written in Linux shell command Korenix Functional Description and is executable A notice 5 The autorun sh file must be UNIX text file format You can use the text editor For example metapad associated in the JetBox 9300 9310 CD ROM to write the content of autorun sh A notice 6 Each SD card has its own CUST file and CANNOT be interchanged with other 9300 Series JetBox when written by Korenix 2 2 Autorun sh Update Although users make their settings ready in the beginning sometimes users still need to modify some parameters depending on the occasions The Autorun sh Update function provides the flexibility to let users update the autorun sh file through TFTP server under the CLI of the JetBox Users telnet the JetBox LAN IP address to enter the CLI of the JetBox specify the TFTP server and swap the original autorun sh in the SD card of the JetBox with the new one in the TFTP server Step by step to update the autorun sh file 1 Telnet lt the JetBox LAN IP address gt to enter the CLI 2 Select 9 Backup and Restore then 3 Autorun Update 3 Enter TFTP server IP address 4 The system will update the autorun sh directly 5 Reboot the JetBox to apply the new setting of autorun sh A notice 7 The new autorun sh file must
7. exist in TFTP server otherwise the update will not succeed and a warning message will pop up p Functional Description Korenix 2 3 Example I Running a Marquee Light Below is an example application for the JetBox utilizing the autorun sh file It will use the digital outputs to control the attached four indicators to light up in sequence The source code of the example application is as follows demobox boxdemo JetBox Demo Program kk This program is a demo tool that can set DO to high and low state This program can also setup PoE state kk Copyright C 2007 2008 Korenix Ltd boxdemo c program source Copyright C 2007 2008 Korenix Ltd Digital 1 0 Controller DIO System peripherals Based on JetBox9300 series datasheet include lt termios h gt include lt stdio h gt include lt unistd h gt include lt fcntl h gt include lt string h gt include lt sys signal h gt include lt sys types h gt include lt sys ioctl h gt include lt sys stat h gt include at91_dio h Korenix Functional Description include lt syslog h gt tdefine KNX IOFILE dev dio int main int argc char argv int i fd struct krx iocmd iocmd fd open KNX_IOFILE O_RDWR O NOCTTV O NONBLOCK if fd lt 0 perror KNX_IOFILE goto exit set diocfg iocmd sec_idx DO_SECTION while 1 for i 0 i lt 4 i set
8. he autorun sh file onto a SD card insert the SD card into the JetBox and reboot the JetBox The setting will automatically activate after the JetBox boots up Chapter 3 Applications Supported through Auto Run Function 3 1 Process Monitor The monitoring function is an advanced feature provided in the SW v1 3 release of JetBox 9300 9310 This function allows customers to monitor the status of the specific processes defined in the autorun sh and restart the processes or send out a warning message once the processes stop The content of autorun sh for process monitor procmon c lt command gt n lt seconds gt l a 0 3 l b lt command gt c cmdline Monitor process name b backup cmdline Backup action process name a 0 do nothing 1 restart 2 backup program 3 backup amp restart action type default l restart n f period checking in seconds default 5 second Example procmon c snmpd Monitor if snmpd keeps alive notice 9 If the command of process monitor is incorrect or the monitored processes are improper it might keep the process monitor checking in an unlimited loop notice 10 In SW1 3 the process monitor could only support one add on parameter after the process name In later SW version all add on parameters can be Applications Supported through Auto Run Function Korenix supported 3 2 Modbus Gateway Optional The Modbus Gateway is optional value added s
9. korenix JetBox 95xx 93xx Linux Auto Run Function User Manual www korenix com Copyright Notice Copyright 2009 Korenix Technology Co Ltd All rights reserved Reproduction without permission is prohibited Information provided in this manual is intended to be accurate and reliable However the original manufacturer assumes no responsibility for its use or for any infringements upon the rights of third parties that may result from its use The material in this document is for product information only and is subject to change without notice While reasonable efforts have been made in the preparation of this document to assure its accuracy Korenix assumes no liabilities resulting from errors or omissions in this document or from the use ofthe information contained herein Korenix reserves the right to make changes in the product design without notice to its users Acknowledgments Korenix is a registered trademark of Korenix Technology Co Ltd All other trademarks or registered marks in the manual belong to their respective manufacturers Overview Korenix Table of Contents Copyright Note iii nisa ark i p ne a 2 entendu En 2 ablenne gesent 3 Chapter 1 OIL LE sissit ntanna taia 4 1 1 Applied Korenix Mod lisation 4 Chapter 2 F n tional Descripti E 5 2 1 Function Architecture EE 5 2 2 Aut run sh Update Lana entame nent 6 2 3 Example I Running a Marquee Light 7 2 4 Example IEW LAN Settings 9
10. nside one SD card the system applies autorun sh file first and then CUST file The system keeps the CUST setting if there were any conflicts between autonrun sh file and CUST file 1 1 Applied Korenix Model JetBox auto run function is applied in the following models Overview Korenix 1 JetBox 9300 Industrial Networking Computer SW v1 3 or later version 2 JetBox 9310 Industrial PoE Networking Computer SW v1 3 or later version 3 All JetBox 95xx models A notice 3 After the JetBox 9300 9310 SW version1 5 the system will transfer the autorun sh file format to UNIX automatically before executing it Chapter 2 Functional Description 2 1 Function Architecture Following is the architecture for the auto run function JetBox system boots up JetBox Ul running A BB EN pa r IN autorun sh stored in the SD card F lh 1 Use Linux shell command E pb NI zem e SSA 2 Executable content or applications 1 Tre e 3 The setting can t be controlled in SD Web UI or CLI CUST file Customized by Korenix noticett stored in the SD card The configuration will go 1 Encrypted content back to previous setting if 2 Each SD card has its own CUST you reboot the system file and CANNOT be interchanged without the SD card inside with other 9300 Series JetBox the JetBox when written by Korenix Picture 1 Function architecture of auto run in the JetBox After the JetBox 9300 9310 boots up the system runs the
11. oftware provided by Korenix The major function of the Modbus Gateway enables serial Modbus RTU or Modbus ASCII devices to communicate with Modbus TCP devices You can use autorun sh to initiate the Modbus gateway too The example content of autorun sh for Modbus gateway cd mnt card modbusgw parity even amp cd The parameters of Modbus gateway are as follows modbusgw port lt port gt protocol rtu ascii baud lt baud gt parity none even l odd bits 7 I 8 stop 1 I 2 timeout lt t gt srate lt t gt tcp lt port gt or modbusgw f lt file_name gt port the name of the serial port Ex ttyS1 ttyS2 protocol RTU or ASCII The default is rtu baud Baud rate The default is 9600 Up to 460800 parity odd even none The default is none bits Data length RTU is 8 bits ASCII is 7 bits stop Stop bit The default is 1 timeout Response timeout The default is 5 seconds tcp Tcp port The default is 502 srate Scan rate The default is 200ms f the Modbus gateway configuration file The default file name is modbusgw conf And the default Modbus gateway setting is as follows modbusgw Korenix Applications Supported through Auto Run Function port ttyS1 protocol rtu baud 115200 parity even bits 8 stop 1 timeout 5 srate 200 tcp 502 Chapter 4 Appendix 4 1 Pictures 8 Notices Index Pictures Picture 1 Function architecture of auto
12. t wireless quality of the link signal strength and noise level This information is updated each time a new packet is received so each address of the list adds some overhead in the driver Korenix Appendix Linux commands Description Note that this functionality works only for nodes part of the current wireless cell you cannot monitor Access Points you are not associated with you can use Scanning for that and nodes in other cells In Managed mode in most case packets are relayed by the Access Point in this case you will get the signal strength of the Access Point For those reasons this functionality is mostly useful in Ad Hoc and Master mode iwpriv Iwpriv is the companion tool to iwconfig Iwpriv deals with parameters and setting specific to each driver as opposed to iwconfig which deals with generic ones Without any argument iwpriv list the available private commands available on each interface and the parameters that they require Using this information the user may apply those interface specific commands on the specified interface In theory the documentation of each device driver should indicate how to use those interface specific commands and their effect Above Linux command descriptions refer to the website http linux die net man You can surf in the Internet for more information 4 3 Customer Service a Contact Us Korenix Technologies Co Ltd Business service sales korenix com

Download Pdf Manuals

image

Related Search

Related Contents

DeLOCK USB2.0 microscope „Pen Scope“  Graef MS 62  MCH-6 SILENT - Coltri Compressors Maldives  octobre 2009 - Site officiel La Bouëxière  熱 中 症 対 策 用 品 ・ 節 電 対 策 用 品 熱 中 症 対 策 用 品 ・ 節 電 対  Mini Desktop PC (Thin Client)  MERIVAARA France  Fujitsu LIFEBOOK 531  De l`art optico-cinétique à l`art « ambiantal » – Vers une  Domaine(s) fonctionnel(s) Emploi(s) –type Localisation  

Copyright © All rights reserved.
Failed to retrieve file