现在的位置: 首页 > 综合 > 正文

RTEMS 网络增补

2014年09月27日 ⁄ 综合 ⁄ 共 2350字 ⁄ 字号 评论关闭
文章目录

RTEMS 网络增补

networking.RTEMS网络增补.双语.V20131224.pdf
RTEMS 的networking文档的原创翻译。

目录

前言 11
1  网络任务结构和数据流 13
2  网络驱动 17
2.1  简介 17
2.2  了解网络设备 17
2.3  了解网络调度约定 19
2.4  网络驱动的Makefile 20
2.5  编写驱动程序连接函数 21
2.6  编写驱动程序启动函数 24
2.7  编写驱动程序初始化函数 24
2.8  编写驱动程序发送任务 25
2.9  编写驱动程序接收任务 25
2.10  编写驱动程序中断处理程序 26
2.11 编写驱动程序IOCTL函数 26
2.12  编写驱动程序统计打印函数 27
3  在RTEMS应用程序中使用网络 29
3.1  Makefile修改 29
3.1.1  包含必需的管理器 29
3.1.2  增加堆的大小 29
3.2  系统配置 29
3.3  初始化 30
3.3.1  额外的包含文件 30
3.3.2  网络配置 30
3.3.3  网络设备配置 37
3.3.4  网络初始化 40
3.4  应用程序编程接口 40
3.4.1  网络统计信息 41
3.4.2  接入接口 42
3.4.3  套接字选项 43
3.4.4  增加IP别名 46
3.4.5  增加默认路由 47
3.4.6  使用NTP时间同步 55
4  测试驱动程序 57
4.1  初步设置 57
4.2  调试输出 58
4.3  监视器命令 59
4.4  驱动程序基本操作 62
4.5  BOOTP/DHCP操作 63
4.6  压力测试 64
4.6.1  大数据包 64
4.6.2  资源耗尽 64
4.6.3  电缆故障 65
4.6.4  吞吐量 66
5  网络服务器 69
5.1  RTEMS FTP守护进程 69
5.1.1  配置参数 69
5.1.2  初始化FTPD(启动守护进程) 70
5.1.3  使用钩子 70
6  DEC 21140驱动 73
6.1  DEC 21240驱动介绍 73
6.2  文档修订历史 73
6.3  DEC21140 PCI板概论 74
6.4  RTEMS驱动程序软件架构 77
6.4.1  初始化阶段 77
6.4.2  内存缓冲区 78
6.4.3  接收器线程 79
6.4.4  发送器线程 80
6.5  遇到的问题 80
6.6  ChorusOs DEC驱动 81
6.7  Netboot DEC驱动 81
6.8  使用DEC芯片的以太网卡列表 82
命令和变量索引 85
概念索引 87

1  Network Task Structure and Data Flow
1  网络任务结构和数据流

A schematic diagram of the tasks and message mbuf queues in a simple RTEMS networking application is shown in the following figure:
一个简单的RTEMS网络应用程序中的任务和消息mbuf队列的示意图如下图所示:

The transmit task for each network interface is normally blocked waiting for a packet to arrive in the transmit queue. Once a packet arrives, the transmit task may block waiting for an event from the transmit interrupt handler. The transmit interrupt  handler
sends an RTEMS event to the transmit task to indicate that transmit hardware resources have become available.
每个网络接口的发送任务通常被阻塞,以等待数据包到达发送队列。一旦数据包到达,发送任务可以阻塞,以等待来自发送中断处理程序的事件。发送中断处理程序发送RTEMS事件到发送任务,以表示发送硬件资源已变成可用的。

The receive task for each network interface is normally blocked waiting for an event from the receive interrupt handler. When this event is received the receive task reads the packet and forwards it to the network stack for subsequent processing by the network
task.
每个网络接口的接收任务通常被阻塞,以等待来自接收中断处理程序的事件。当收到此事件时,接收任务读取数据包并将它转发到网络栈,随后由网络栈处理。

The network task processes incoming packets and takes care of timed operations such as handling TCP timeouts and aging and removing routing table entries.
网络任务处理传入的数据包,并处理定时操作,如处理TCP超时、老化和移除路由表项。

The ‘Network code’ contains routines which may run in the context of the user application tasks, the interface receive task or the network task. A network semaphore ensures that the data structures manipulated by the network code remain consistent.
“网络代码”包含可以在用户应用程序任务、接口接收任务或网络任务的上下文中运行的例程。网络信号量确保由网络代码操纵的数据结构保持一致。

全文下载地址:http://download.csdn.net/detail/zhumaill/7019621

抱歉!评论已关闭.