JUPITER ----UCLINUX TCP/IP开发板的使用

1. 国产普及型开发板的的照片,是对韩国原板的改进,功能一样。

 

开发板接线图:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 


2. 板上配置:

l         CPU –韩国ADC公司的JUPITER 50MHz 32BIT RISC

l         的所有口线从芯片四周引出,方便二次开发。

l         板上带有2LXT971APHY)组成的10/100M以太网RJ-45接口。

l         16针彩色STN LCD接口。由转接线/板接不同接口的LCD

SDRAM 16M BYTE 数据线宽32 8M BYTE 数据线宽16位,旁边有跳线选择。

l         FLASH-AT29C040/28SF040 512KBYTE EPROM 27C801  1M BYTE,可以用跳线选择。芯片旁边有说明。

l         双串口,配1个串口延长线。

l         输入5V电源,板上变为3.3V

l         板上有22-28VLCD可调电源变换器。

l         板上有启动配置跳线。初始化FLASH/EPROM的数据线宽度,缺省8位。

l         板上有5X6的键盘。

3. 如何配置板上的跳线?

SDRAM设为32位,JP132-3

ROM设为8位,JP322-3JP332-3

PLL使能,JP372-3

网口跳线

JP20,21,22都接1-2

JP23,24,25都接1-2

表示10/100M自适应

这是板上的设置。

4. 开发板的使用步骤,怎样跑UCLINUX操作系统。

PC机上使用WIN98/2000/XP系统

 

 

首先把光盘上的文件拷贝到硬盘目录下

要拷贝的目录是:Jupiter\uclinux\tftpserver,并去掉只读属性。

该目录中存放已经编译好的LINUX.BIN和RDGZ***.BIN,***代表日期。

LINUX.BIN是核心,RDGZ.BIN是RAMDISK映象(包含用户程序)。

 

 

PC的设置,使用WIN98/2000/XP,网卡TCP/IP地址设置为:192.168.10.2

首先连接好硬件。如下图,有两种方法:注意串口线连接是:开发板的COM1连接到PCCOM0


1.       用一片29C040/27C801,烧seloader.bin文件,其实板上带了一片。这就是通常我们讲的boot程序。

该文件在\Jupiter\uclinux\seloader-jupiter-030221\forJupiter\seloader\src目录

2.       JUPITERCOM1口连PCCOM0,启动超级终端(波特率:38400,流控:无)。

并把JUPITER网口0连到PC上。上电复位后应该在超级终端窗口中看到如下信息:

=====================================================================

seloader is se3208 Boot Loader

Copyright (C) 2002 ad chips.

seloader comes with ABSOLUTELY NO WARRANTY; Read the GNU GPL for details.

=====================================================================

Autoboot aborted

Type "help" to get a list of commands

seloader>

 

这时Jupiter的eth0的中间黄色LED点亮

 

3. PC上安装并运行两个服务程序dhcp1816tftpd。程序在光盘的E:\Jupiter\uclinux\win服务程序目录。

dhcp1816就是hanewin software dhcp软件

注意:WIN2000/XP的PC上启动这个dhcp软件需要先执行program->hanewin software->install DHCP boot server,

否则无法启动DHCP,WIN98上不用

     设置DHCP/bootp

运行program->hanewin software-> DHCP boot server

 

首先添加bootp用的MAC地址和ip地址:

进入Options->add static address entry: Set the Hardware address by "00:01:23:45:67:00". 这是jupiter板的却省MAC地址。

At the IP address, first three octet must be same with server IP address and last octet can be anyone. 

即在ip地址栏中添加jupiter板的ip地址:192.168.10.3,因为pc机的ip地址被设为192.168.10.2, 

ip地址应该在同一个网段中,但不能相同。

 

然后:

Option->preference->dhcp server中

选中本机的网卡的IP地址192.168.10.2。并选中use selected address only.

设置完后自动启动,在状态栏中显示:listening on port 67

注意:不要碰该软件的ftp部分

 

4.运行 tftpd

设置TFTPD:设置tftpd->configure->home directory: :Jupiter\uclinux\tftpserver,在这目录里存放了linux.bin,rdgz.bin文件用于tftp网络下载。

然后tfptd->start,在状态栏里显示:server is running

5.       软件设置完后,在超级终端中,执行:bootp命令。地一次出现时间稍长(3秒)显示:

seloader> bootp

Our Ethernet address is 0001 2345 6700.

        Sending bootp packet...

bh_opcode : 2, htype : 1, hlen : 6 tid : 1007616006, chaddr : 0:1:23:45:67:0

len => 300, client IP => A8C00000   host IP => A8C00300

bh_opcode : 2, htype : 1, hlen : 6 tid : 1007616006, chaddr : 0:1:23:45:67:0

len => 300, client IP => A8C00000   host IP => A8C00300

 

Bootp Packet received.

        Host   (server) Ethernet : 0000 B458 1526

        Host   (server) IP       : *,.((.0.2

        Client (target) Ethernet : 0001 2345 6700

        Client (target) IP       : *,.((.0.3

6. 执行tftp下载linux.bin 显示:

seloader> tftp linux.bin kernel

TFTP Start...

        Host   (server) IP       : *,.((.0.2

        Client (target) IP       : *,.((.0.3

        Loading Filename         : linux.bin

        Save Address             : 0x0C200000

 

Loading start...

        0x000A0258 (655960) bytes received.

        tftp done.

7. 执行tftp下载rdgz.bin 显示:

seloader> tftp rdgz.bin ramdisk

TFTP Start...

        Host   (server) IP       : *,.((.0.2

        Client (target) IP       : *,.((.0.3

        Loading Filename         : rdgz.bin

        Save Address             : 0x0C500000

 

Loading start...

        0x000715C9 (464329) bytes received.

        tftp done.

8. 执行boot 启动uclinux

会有一大堆信息显示:不看也可以

seloader> boot

 

Starting kernel ...

 

 

in head-se3208.S

Linux version 2.4.20-uc0 (administrator@ZENGYU-X14PHIPI) (gcc version egcs-2.91.

66 19990314 (egcs-1.1.2 release)) #1 Thu Apr 10 15:43:30 2003

Architecture: eisc-jupiter

On node 0 totalpages: 1536

zone(0): 0 pages.

zone(1): 1536 pages.

BUG: wrong zone alignment, it will crash

zone(2): 0 pages.

Kernel command line: root=/dev/ram0

Calibrating delay loop... 33.07 BogoMIPS

Memory: 6MB = 6MB total

Memory: 5256KB available (572K code, 210K data, 28K init)

Dentry cache hash table entries: 1024 (order: 1, 8192 bytes)

Inode cache hash table entries: 512 (order: 0, 4096 bytes)

Mount-cache hash table entries: 512 (order: 0, 4096 bytes)

Buffer-cache hash table entries: 1024 (order: 0, 4096 bytes)

Page-cache hash table entries: 2048 (order: 1, 8192 bytes)

POSIX conformance testing by UNIFIX

Linux NET4.0 for Linux 2.4

Based upon Swansea University Computer Society NET3.039

Initializing RT netlink socket

Starting kswapd

jupiter keypad driver initialized

dmc9512 touch screen driver initialized

jupiter_eth.c : v1.00 9/10/2002 eduarmy

Jupiter Ethernet 0 probe

Jupiter Ethernet1 failed 01 : Wrong Addr, eth1 is 1f03600

Jupiter Ethernet1 03 :  eth1 is 1f03600

jupiter_eth1.c : old v1.00 9/10/2002 eduarmy

Jupiter Ethernet1 tx_fd_initialize eth1 is 1f03600 c2c8208

Jupiter Ethernet1 rx_fd_initialize eth1 is 1f03600 c2c5208

Jupiter Ethernet 1 probe

RAMDISK driver initialized: 16 RAM disks of 8192K size 1024 blocksize

loop: loaded (max 8 devices)

NET4: Linux TCP/IP 1.0 for NET4.0

IP Protocols: ICMP, UDP, TCP

IP: routing cache hash table of 512 buckets, 4Kbytes

TCP: Hash tables configured (established 512 bind 512)

RAMDISK: Compressed image found at block 0

Freeing initrd memory: 700K

EXT2-fs warning: mounting unchecked fs, running e2fsck is recommended

VFS: Mounted root (ext2 filesystem).

Freeing init memory: 28K

Shell invoked to run file: /etc/rc

Command: hostname jupiter

Command: mount -t proc proc /proc

Command: cat /etc/motd

================================================================

Welcome to

          ____ _  _

         /  __| ||_|

    _   _| |  | | _ ____  _   _  _  _

   | | | | |  | || |  _ \| | | |\ \/ /

   | |_| | |__| || | | | | |_| |/    \

   |  ___\____|_||_|_| |_|\____|\_/\_/

   | |

   |_|                  for EISC Chips !!!!

 

For further information check:

http://www.adc.co.kr/

 

================================================================

 

Command: ifconfig eth0 192.168.10.3

Command: ifconfig eth1 up

Command: ifconfig eth1 192.168.0.3

Command: route add default gw 192.168.10.2

Command: ifconfig lo 127.0.0.1

Command: route add -net 127.0.0.0 netmask 255.0.0.0 lo

Command: #dhcpcd -p -a eth0 &

Execution Finished, Exiting

 

Sash command shell (version 1.1.1),(pgid: 14)

/>ping 192.168.10.2      注意,要把PC WIN2000/XP的杀毒软件的防火墙关掉才行,否则ping不通

....

/> ps 查看进程

  PID PORT STAT SIZE SHARED %CPU COMMAND

    1           37K     0K 53.2 init

    2            0K     0K  0.0 keventd

    3            0K     0K  0.0 ksoftirqd_CPU0

    4            0K     0K  0.0 kswapd

    5            0K     0K  0.0 bdflush

    6            0K     0K  0.0 kupdated

   14           71K     0K  4.3 /bin/sh

   15           38K     0K  2.3 /bin/inetd

   16          135K     0K  4.6 /bin/boa -c /home

/>

9. PC上的IE浏览器去访问http://192.168.10.3,这是JUPITERIP地址,显示:

 

 

 

10. telnet实验

WIN_XP或LINUX的PC上要启动telnet服务

在Jupiter板的终端中

telnet 192.168.10.2

输入账号,密码后可以登陆

 

用PC telnet Jupiter

在PC上执行:telnet 192.168.10.3,不需要密码就可以登陆。

 

 

11.eth1的实验

 

将PC的IP地址改为192.168.0.2,把网线从eth0换到eth1(eth0的灯灭,而eth1的灯亮)

在PC上ping 192.168.0.3

或在Jupiter板上ping 192.168.0.2

 

 

 

5. uclinux-eisc的支持网站

www.ebdev.com

可以下载最新编译好的linux.bin rdgz.bin文件 和多种应用程序

 

有问题请发邮件: mm@ebdev.com