Moxa UC-7408 Manual do Utilizador

Consulte online ou descarregue Manual do Utilizador para Clientes fino Moxa UC-7408. Moxa UC-7408 Manual do Utilizador

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 97
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 0
UC-7408 Users Manual
Sixth Edition, February 2009
www.moxa.com/product
© 2009 Moxa Inc. All rights reserved.
Reproduction without permission is prohibited.
Vista de página 0
1 2 3 4 5 6 ... 96 97

Resumo do Conteúdo

Página 1 - UC-7408 User’s Manual

UC-7408 User’s Manual Sixth Edition, February 2009 www.moxa.com/product © 2009 Moxa Inc. All rights reserved. Reproduction without permission is pro

Página 2

UC-7408 User’s Manual Introduction 1-5Dimensions 197 mm [7.76"]125 mm [4.92"]44 mm[1.73"] Hardware Block Diagram The following block

Página 3 - Table of Contents

UC-7408 User’s Manual Introduction 1-6LED Indicators UC-7408 has 12 LED indicators on the top panel. Refer to the following table for information ab

Página 4

UC-7408 User’s Manual Introduction 1-7Real Time Clock UC-7408’s real time clock is powered by a lithium battery. We strongly recommend that you do n

Página 5

UC-7408 User’s Manual Introduction 1-8DIN-Rail Mounting The aluminum DIN-Rail attachment plate is included in the package. If you need to reattach t

Página 6 - Introduction

UC-7408 User’s Manual Introduction 1-9You should also observe the following common wiring rules: y Use separate paths to route wiring for power and

Página 7 - Overview

UC-7408 User’s Manual Introduction 1-10Connecting to the Network Connect one end of the Ethernet cable to one of UC-7408’s 10/100M Ethernet ports (8

Página 8 - Product Features

UC-7408 User’s Manual Introduction 1-11CompactFlash UC-7408 provides one CompactFlash slot that supports CompactFlash type I/II card expansion. Curr

Página 9 - Hardware Introduction

UC-7408 User’s Manual Introduction 1-12User APUser Directory(User Configuration)Mini Root File SystemConfigurationLinux Kernel & RootHWBoot Load

Página 10 - Hardware Block Diagram

UC-7408 User’s Manual Introduction 1-13Although JFFS2 is a journaling file system, this does not preclude the loss of data. The file system will rem

Página 11 - Reset-type Buttons

22 Chapter 2 Getting Started In this chapter, we explain how to connect UC-7408, turn on the power, and then get started using the programming and

Página 12 - Placement Options

UC-7408 User’s Manual The software described in this manual is furnished under a license agreement and may be used only in accordance with the terms

Página 13 - Wiring Requirements

UC-7408 User’s Manual Getting Started 2-2Powering on UC-7408 Connect the SG wire to the Shielded Contact located in the upper left corner of the UC-

Página 14 - DC 12-48V

UC-7408 User’s Manual Getting Started 2-3Telnet Console If you know at least one of the two IP addresses and netmasks, then you can use Telnet to co

Página 15 - Connecting to the Network

UC-7408 User’s Manual Getting Started 2-4 ATTENTION Serial Console Reminder Remember to choose VT100 as the terminal type. Use cable CBL-RJ45F9-150,

Página 16 - Software Introduction

UC-7408 User’s Manual Getting Started 2-5Linux Users From a Linux machine, use the “ssh” command to access UC-7408’s Console utility via SSH. #ssh 1

Página 17

UC-7408 User’s Manual Getting Started 2-6 Dynamic IP addresses: By default, UC-7408 is configured for “static” IP addresses. To configure one or bot

Página 18 - Software Package

UC-7408 User’s Manual Getting Started 2-73. After the boot settings of the LAN interface have been modified, issue the following command to activate

Página 19 - Getting Started

UC-7408 User’s Manual Getting Started 2-8 3. Configure the Wireless LAN card’s default SSID setting profile. (Default SSID is “any”) #vi /etc/wlan/

Página 20 - Connecting UC-7408 to a PC

UC-7408 User’s Manual Getting Started 2-9IEEE802.11g The following IEEE802.11g wireless modules are supported: y ASUS—WL-107g y CNET—CWC-854 (181D

Página 21 - Telnet Console

UC-7408 User’s Manual Getting Started 2-103. Additional WLAN parameters are contained in the file RT2500STA.dat. To open the file, navigate to the R

Página 22 - UC-7408

UC-7408 User’s Manual Getting Started 2-11 NetworkType—Sets the wireless operation mode Setting Explanation Infra Infrastructure mode (uses access

Página 23 - Linux Users

Table of Contents Chapter 1 Introduction...1-1 Overvi

Página 24

UC-7408 User’s Manual Getting Started 2-12 TurboRate—Enables or disables TurboRate Setting Explanation 0 disable 1 enable BGProtection—Sets 11b/11

Página 25 - IEEE802.11b

UC-7408 User’s Manual Getting Started 2-13Test Program—Developing Hello.c In this section, we use the standard “Hello” programming example to illust

Página 26

UC-7408 User’s Manual Getting Started 2-14Checking the Flash Memory Space If the flash memory is full, you will not be able to save data to the Flas

Página 27 - IEEE802.11g

UC-7408 User’s Manual Getting Started 2-15NOTE Be sure to type the #make command from within the /tmp/example/hello directory, since UC’s tool chai

Página 28

UC-7408 User’s Manual Getting Started 2-16RS-232 LANPC 2PC 1Write data to PC1Receive LAN dataRead serial dataSend data to PC2tcps2.cSerial RxBufferL

Página 29

UC-7408 User’s Manual Getting Started 2-17 root@server11:/home/uc7400/1st_application [root@server11 1st_application]# pwd /home/uc7400/1st_applic

Página 30

UC-7408 User’s Manual Getting Started 2-18 root@server11:/home/uc7400/1st_application [root@server11 1st_application]# ftp 192.168.3.127 Connected

Página 31 - #mount /dev/cdrom /mnt/cdrom

UC-7408 User’s Manual Getting Started 2-194. The program should start running in the background. Use either the #jobs or #ps –ef command to check i

Página 32 - Compiling Hello.c

UC-7408 User’s Manual Getting Started 2-20 158 root 1532 S /sbin/getty 115200 ttyS1 162 root 3652 S /usr/sbin/sshd 163 root

Página 33 - Testing Environment

UC-7408 User’s Manual Getting Started 2-21NOTE The tcps2.c application is a simple example designed to give users a basic understanding of the conc

Página 34 - Compiling tcps2.c

Compiling tcps2.c... 2-16 Uploading tcps2-release a

Página 35

33 Chapter 3 Managing Embedded Linux This chapter includes information about version control, deployment, updates, and peripherals. The informatio

Página 36

UC-7408 User’s Manual Managing Embedded Linux 3-2System Version Information To determine the hardware capability of your UC-7408, and what kind of s

Página 37

UC-7408 User’s Manual Managing Embedded Linux 3-3Since different Flash disks have different sizes, it’s a good idea to check the size of your Flash

Página 38 - Testing Procedure Summary

UC-7408 User’s Manual Managing Embedded Linux 3-4local: UC7420-1.5.frm remote: UC7420-1.5.frm 200 Port command successful. 150 Opening data connecti

Página 39

UC-7408 User’s Manual Managing Embedded Linux 3-5Loading Factory Defaults The easiest way to load factory defaults is to update the firmware (follow

Página 40 - Managing Embedded Linux

UC-7408 User’s Manual Managing Embedded Linux 3-6Type the command “ps –ef” to list all processes currently running. 192.168.3.127 – PuTTY root@Mo

Página 41 - System Image Backup

UC-7408 User’s Manual Managing Embedded Linux 3-7Then you will find the enabled daemons after you reboot the system. 192.168.3.127 – PuTTY root@M

Página 42

UC-7408 User’s Manual Managing Embedded Linux 3-8Setting the Run-Level In this section, we outline the steps you should take to set the Linux run-le

Página 43

UC-7408 User’s Manual Managing Embedded Linux 3-9Adjusting the System Time Setting the Time Manually UC-7408 has two time settings. One is the syste

Página 44 - Loading Factory Defaults

UC-7408 User’s Manual Managing Embedded Linux 3-10NTP Client UC-7408 has a built-in NTP (Network Time Protocol) client that is used to initialize a

Página 45

Network... A-1 Process...

Página 46

UC-7408 User’s Manual Managing Embedded Linux 3-11Cron—daemon to Execute Scheduled Commands Start Cron from the directory /etc/rc.d/rc.local. It wil

Página 47 - Setting the Run-Level

44 Chapter 4 Managing Communications In this chapter, we explain how to configure UC-7408’s various communication functions. The following topics

Página 48 - Adjusting the System Time

UC-7408 User’s Manual Managing Communication 4-2Telnet / FTP In addition to supporting Telnet client/server and FTP client/server, the UC-7408 syste

Página 49 - NTP Client

UC-7408 User’s Manual Managing Communication 4-3Web Service—Apache The Apache web server’s main configuration file is /etc/apache/httpd.conf, with t

Página 50 - Connecting Peripherals

UC-7408 User’s Manual Managing Communication 4-4 To open the default CGI test script report page, type http://192.168.3.127/cgi-bin/test-cgi in you

Página 51 - Managing Communications

UC-7408 User’s Manual Managing Communication 4-5Saving a Web Page to the CF Card Since some applications will have web pages that take up a lot of m

Página 52 - Telnet / FTP

UC-7408 User’s Manual Managing Communication 4-6Step4: Open your browser and connect to the UC-7408 by typing the current LAN1 IP address in the bro

Página 53 - Web Service—Apache

UC-7408 User’s Manual Managing Communication 4-7other computers that connect to this host can connect to the Internet when it the computer does not

Página 54

UC-7408 User’s Manual Managing Communication 4-8UC-7408 supports the following sub-modules. Be sure to use the module that matches your application.

Página 55

UC-7408 User’s Manual Managing Communication 4-9 Examples: # iptables -L -n In this example, since we do not use the -t parameter, the system uses

Página 56 - IPTABLES

11 Chapter 1 Introduction Welcome to Moxa UC-7408, a data acquisition embedded computer that features 8 RS-232/422/485 serial ports, dual 10/100 M

Página 57

UC-7408 User’s Manual Managing Communication 4-10Examples: Example 1: Accept all packets from lo interface. # iptables –A INPUT –i lo –j ACCEPT Exam

Página 58

UC-7408 User’s Manual Managing Communication 4-11NAT Example The IP address of all packets leaving LAN1 are changed to 192.168.3.127 (you will need

Página 59 - Append or delete rules:

UC-7408 User’s Manual Managing Communication 4-12/sbin/iptables -F -t nat /sbin/iptables -X -t nat /sbin/iptables -Z -t nat /sbin/iptables -P INP

Página 60

UC-7408 User’s Manual Managing Communication 4-13Dial the modem, and then ... CONNECT Wait for an answer. “ “ Send a return (null text followed by t

Página 61 - Enabling NAT at Bootup

UC-7408 User’s Manual Managing Communication 4-14lo Link encap Local Loopback inet addr 127.0.0.1 Bcast 127.255.255.255 Mask 255.0.0.0 UP L

Página 62 - Dial-up Service—PPP

UC-7408 User’s Manual Managing Communication 4-15The first star (*) lets everyone login. The second star (*) lets every host connect. The pair of do

Página 63 - How to check the connection

UC-7408 User’s Manual Managing Communication 4-165. Edit the file /etc/ppp/pap-secrets and add the following: “[email protected]” * “password” *

Página 64 - * * “” *

UC-7408 User’s Manual Managing Communication 4-177. Add one of two files: /etc/ppp/options.ixp0 or /etc/ppp/options.ixp1. The choice depends on whi

Página 65

UC-7408 User’s Manual Managing Communication 4-18NOTE Click on the following links for more information about NFS: http://www.tldp.org/HOWTO/NFS-HO

Página 66

UC-7408 User’s Manual Managing Communication 4-19Example 2 /home/public 192.168.0.0/24(rw) *(ro) In this example, UC-7408 shares the directory /home

Página 67 - NFS (Network File System)

UC-7408 User’s Manual Introduction 1-2Overview UC-7408 data acquisition embedded computers are ideal for embedded applications. UC-7408 has 8 RS-232

Página 68 - /tmp *(rw,no_root_squash)

UC-7408 User’s Manual Managing Communication 4-20To send an email message, use the ‘smtpclient’ utility, which uses SMTP protocol. Type #smtpclient

Página 69

UC-7408 User’s Manual Managing Communication 4-21NOTE Click on the following links for more information about MIB II and RS-232 like group: http://

Página 70 - < mail-body-message

UC-7408 User’s Manual Managing Communication 4-222. Generate a preset shared key by typing the command: # openvpn --genkey --secret secrouter.key C

Página 71 - InternetInternet

UC-7408 User’s Manual Managing Communication 4-23 if [ “$FOUND” = “no” ]; then modprobe $mname fi } start() { ifcfg_vpn if [ ! \( -d “/dev/n

Página 72

UC-7408 User’s Manual Managing Communication 4-24 i=`expr $i + 1` if [ $i -ge $maxtap ]; then break fi done brctl delif br0 $iface b

Página 73

UC-7408 User’s Manual Managing Communication 4-25#!/bin/sh # value after “-net” is the subnet behind the remote peer route add -net 192.168.2.0 netm

Página 74

UC-7408 User’s Manual Managing Communication 4-26Setup 2: Ethernet Bridging for Private Networks on the Same Subnet 1. Set up four machines as show

Página 75

UC-7408 User’s Manual Managing Communication 4-272. Create a configuration file named “A-tun.conf” and an executable script file named “A-tun.sh”.

Página 76 - Setup 3: Routed IP

55 Chapter 5 Programmer’s Guide This chapter includes important information for programmers. The following functions are covered in this chapter:

Página 77

UC-7408 User’s Manual Programmer’s Guide 5-2Flash Memory Map Partition sizes are hard coded into the kernel binary. To change the partition sizes, y

Página 78 - Programmer’s Guide

UC-7408 User’s Manual Introduction 1-3Product Features y Intel XScale IXP422 266 MHz Processor y On-board 128 MB RAM, 32 MB Flash ROM y Eight RS-

Página 79

UC-7408 User’s Manual Programmer’s Guide 5-3Obtaining help Use the Linux man utility to obtain help on many of the utilities provided by the tool ch

Página 80 - #mxscaleb-strip –s example

UC-7408 User’s Manual Programmer’s Guide 5-4Uninstalling the Linux Tool Chain Use the command rpm –qa|grep mxscaleb to query if the Moxa tool chain

Página 81

UC-7408 User’s Manual Programmer’s Guide 5-5Debugging with GDB First compile the program must with option -ggdb. Use the following steps: 1. To deb

Página 82 - RTC (Real Time Clock)

UC-7408 User’s Manual Programmer’s Guide 5-6Buzzer The device node is located at /dev/console. UC-7408 supports Linux standard buzzer control, with

Página 83 - WDT (Watch Dog Timer)

UC-7408 User’s Manual Programmer’s Guide 5-7int swtd_enable(int fd, unsigned long time) Description Enable application sWatchDog. And you must do ac

Página 84

UC-7408 User’s Manual Programmer’s Guide 5-8int swtd_ack(int fd) Description: Acknowledge sWatchDog. When the user application enable sWatchDog. It

Página 85

UC-7408 User’s Manual Programmer’s Guide 5-9 swtd_close(fd); exit(0); } The makefile is shown below: all: mxscaleb-gcc –o xxxx xxxx.c –lmo

Página 86

UC-7408 User’s Manual Programmer’s Guide 5-10 exit(1); } The makefile is shown below: all: mxscaleb-gcc –o xxxx xxxx.c –lmoxalib UART The no

Página 87 - Example to set the baud rate

UC-7408 User’s Manual Programmer’s Guide 5-11Example to get the baud rate #include <moxadevice.h> #include <termios.h> struct termios

Página 88 - Digital I/O

UC-7408 User’s Manual Programmer’s Guide 5-12The definition for DIN and DOUT: #define DIO_HIGH 1 #define DIO_LOW 0 int set_dout_state(int dopor

Página 89 - DIN_EVENT_CLEAR

UC-7408 User’s Manual Introduction 1-4Regulatory Approvals EMC: FCC Class A, CE Class A Safety: UL, CUL, TÜV Warranty 5 years Hardware Introduction

Página 90 - Examples

UC-7408 User’s Manual Programmer’s Guide 5-13duration - Not 0 > detect the din event DIN_EVENT_HIGH_TO_LOW or DIN_EVENT_LOW_TO_HIGH with duration

Página 91

UC-7408 User’s Manual Programmer’s Guide 5-14#ifdef DEBUG #define dbg_printf(x...) printf(x) #else #define dbg_printf(x...) #endif #define MIN_DUR

Página 92

UC-7408 User’s Manual Programmer’s Guide 5-15 } else if ( i == 5 ) { // set high data printf("Please keyin the DOUT number : ");

Página 93

UC-7408 User’s Manual Programmer’s Guide 5-16#include <unistd.h> #include <pthread.h> #include <moxadevice.h> #ifdef DEBUG #defi

Página 94

UC-7408 User’s Manual Programmer’s Guide 5-17 // configure the dout frequency. When the timer timeouts, dout_control() will be called to chang

Página 95 - Make File Example

UC-7408 User’s Manual Programmer’s Guide 5-18 act.sa_flags=0; sigemptyset(&act.sa_mask); sigaction(SIGALRM,&act,NULL); } int main(int arg

Página 96 - System Commands

AA Appendix A System Commands Linux normal command utility collection File manager 1. cp copy file 2. ls list file 3. ln make

Página 97 - Moxa special utilities

UC-7408 User’s Manual System Commands A-2Process 1. kill kill process 2. ps display now running process Other 1. dmesg dump kern

Comentários a estes Manuais

Sem comentários