《程序设计基础教程 - -C语言版》实验指导手册(4)

2019-04-14 22:01

Manipulator is now used as a industrial robots in use, the control objectives often appear often in industrial automation. Industrial automation technology has gradually matured, as mature a technology line has been rapid development in industrial automation as a separate subject. Manipulator application began to filter into welding, logistics, mechanical processing, and other industries. Especially at high or very low temperatures, full of poisonous gases, high radiation case, robot in similar circumstances showed great use also brings great convenience to the staff. Precisely because of this robot to get people's attention began to be a high degree of development. Labor rates, working conditions, labor intensive aspects of promoting development. Both at home and abroad to develop the PLC (programmable logic controller) is in various special circumstances and under special conditions set for mechanical devices. Now turned on the development of the microelectronics automatic control technology and the rapid development of thetrains, the success of PLC hardware software and simulation control win big and successful development, now continues to develop as a factory automation standards. Because robots are good development of the technology makes a good optimization of productive capital, and robot shows this unique advantages, such as: has good compatibility, wide availability, hardware is complete, and programming that can be mastered in a short time, so in the context of industrial PLC applications became ubiquitous. Manipulator in many developed country agriculture and industry has been applied, such as the use of mechanical harvesting large areas of farmland, repeated operations on the high-speed line that uses a robotic arm, and so on. oday, the high level of automation combined with restrictions on the manipulator development level is slightly lower than the international. The design is mainly arm welding machine by PLC Automation control. This of design let designers on in school by learn of has a must of consolidation, understand has some usually didn't opportunities awareness in world range within some leading level of knowledge has has must awareness, hope designers can in yihou of design in the can success of using in this design in the proceeds of experience 1.2 manipulator in both at home and abroad of research profile automation mechanical arm research began Yu 20th century medium-term, after years with with computer and automation technology of development, Makes mechanical arm on the Grand stage of industrial automation and shine, gradually became an industrial evaluation standards, and its importance can be seen. Now original robotic arm spent most of mass production and use on the production line, which is programmed robotic arm. As the first generation of manipulator position control systems main features, although not back several generations that can detect the external environment, but can still successfully complete like welding, painting, delivery as well as for materials simple movements. Second generation mechanicalarms are equipped with sensors and manipulators have the environment there is a certain amount of \chanical arm is to use the program as a basis. Difference is that the robot begand 果。

4.请仔细分析并执行以下程序段,并给出输入数据下的运行结果: int main(void) {

int fun1(); int fun2(); int fun3(); int fun4();

int (*function[4])(); int nA=10,nB=5,i; function[0]=fun1; function[1]=fun2; function[2]=fun3; function[3]=fun4; for (i=0;i<4;i++)

printf(“fun No.%d->%d\\n”,i+1,execute(nA,nB,function[i])); return 0; }

int execute(int nX,int nY,int *func()) {return ((*fun)(nX,nY));} int fun1(int nX,int nY) {return (nX+nY);} int fun2(int nX,int nY) {return (nX-nY);} int fun3(int nX,int nY) {return (nX*nY);} int fun4(int nX,int nY) {return (nX/nY);}

对如下main()函数,假设源程序名为list.c,则对编译连接后的list.exe程序,在DOS界面运行时输入命令行时,其执行结果是什么?为什么?

/*Second main() program*/ int main(int argc,char *argv[]) {

while (argc?1) printf(“%s\\n”,*++argv); return 0; }

实验准备:

(1) 编写所选实验题目的程序代码和流程图; (2) 检查源程序并给出其可能的运行结果说明。 实验步骤:

(1) 上机验证所选题目,并做相应测试和分析; (2) 进行实验分析;

(3) 总结指针及其程序设计、实现方法和经验; (4) 编写实验报告。 实验结果:

(1) 根据测试目标写出测试报告; (2) 测试结果分析说明;

manipulator control mode and programmable controllers introduction 2.1 Select discussion with manipulator control 2.1.1 classification of control relays and discrete electronic circuit can control old industrial equipment, but also more common. Mainly these two relatively cheap and you can meet the old-fashioned, simple (or simple) industrial equipment. So he can see them now, however these two control modes (relay and discrete electronic circuits) are these fatal flaws: (1) cannot adapt to the complex logic control, (2) only for the current project, the lack of compatibility and (3) not reforming the system with equipment improvements. Spring for the development of China's modern industrial automation technology the substantial increase in the level of industrial automation, completed the perfect relay of the computer too much. In terms of controlling the computer showed his two great advantages: (1) each of the hardware can be installed on one or more microprocessors; (2) the official designer of the software writing content control is all about. Now in several ways in the context of industrial automation can often be seen in three ways: (1) Programmable Logical Controller (referred to as IPC); (2) Distributed Control System (DCS for short), and (3) the Programmable Logical Controller (PLC for short). 2.1.2 PLC and the IPC and DCS contrast contrast 1, each of the three technologies of origins and development requirements for fast data processing makes it invented the computer. The men brought in terms of hardware there, using a high level of standardization, can use more compatibility tools, is a rich software resources, especially the need for immediacy in operational systems. So the computer can effectively control is used to control and meet its speed, on the virtual model, real-time and in computational requirements. Distributed system started with a control system for industrial automatic instrument used to control, whereas now it is successfully developed into industrial control computer used as a central collection and distribution system and transition of distributed control system in analogue handling, loop control, has begun to reflect the use of a huge advantage. Though distributed system has great advantages in loop regulation, but only as a means of continuous process control. Optimization of PLC is the corrsponding relay needs was born, its main use in the work order control, early primary is replaced relay this hulking system, focused on the switch controlling the running order of functions. Marked by the microprocessor in the early 1970 of the 20th century emerged, micro-electronics technology has developed rapidly, people soon microelectronics processing technology will be used in the Programmable Logical Controller (that isManipulator is now used as a industrial robots in use, the control objectives often appear often in industrial automation. Industrial automation technology has gradually matured, as mature a technology line has been rapid development in industrial automation as a separate subject. Manipulator application began to filter into welding, logistics, mechanical processing, and other industries. Especially at high or very low temperatures, full of poisonous gases, high radiation case, robot in similar circumstances showed great use also brings great convenience to the staff. Precisely because of this robot to get people's attention began to be a high degree of development. Labor rates, working conditions, labor intensive aspects of promoting development. Both at home and abroad to develop the PLC (programmable logic controller) is in various special circumstances and under special conditions set for mechanical devices. Now turned on the development of the microelectronics automatic control technology and the rapid development of thetrains, the success of PLC hardware software and simulation control win big and successful development, now continues to develop as a factory automation standards. Because robots are good development of the technology makes a good optimization of productive capital, and robot shows this unique advantages, such as: has good compatibility, wide availability, hardware is complete, and programming that can be mastered in a short time, so in the context of industrial PLC applications became ubiquitous. Manipulator in many developed country agriculture and industry has been applied, such as the use of mechanical harvesting large areas of farmland, repeated operations on the high-speed line that uses a robotic arm, and so on. oday, the high level of automation combined with restrictions on the manipulator development level is slightly lower than the international. The design is mainly arm welding machine by PLC Automation control. This of design let designers on in school by learn of has a must of consolidation, understand has some usually didn't opportunities awareness in world range within some leading level of knowledge has has must awareness, hope designers can in yihou of design in the can success of using in this design in the proceeds of experience 1.2 manipulator in both at home and abroad of research profile automation mechanical arm research began Yu 20th century medium-term, after years with with computer and automation technology of development, Makes mechanical arm on the Grand stage of industrial automation and shine, gradually became an industrial evaluation standards, and its importance can be seen. Now original robotic arm spent most of mass production and use on the production line, which is programmed robotic arm. As the first generation of manipulator position control systems main features, although not back several generations that can detecthe external environment, but can still successfully complete like welding, painting, delivery as well as for materials simple movements. Second generation mechanicalarms are equipped with sensors and manipulators have the environment there is a certain amount of \chanical arm is to use the program as a basis. Difference is that the robot begand(3) 测试程序代码清单。

实验九 结构体和共用体(4学时)

实验目的:

(1) 掌握C语言环境下结构体和共用体类型变量的定义和使用方法; (2) 掌握结构体类型数组的概念和使用;

(3) 掌握指向结构体变量的指针变量、尤其是链表概念; 实验内容:

1. 首先熟悉结构体类型变量的基本声明方法、结构体类型变量的内存分配原则、初始化和引用结构体变量及其成员变量的基本方法;然后掌握结构体变量的输入、输出方法。(参见教材例10-1~10-5)

2.基于结构体数组的应用实验。

(1) 有n个学生,每个学生的数据包括学好(num)、姓名(name[20])、性别(sex)、年龄(age),以及三门课程的成绩(score[3])。要求:在main()函数中输入这些学生的这些数据,然后设计一个函数count()来计算每个学生的总分和平均分,最后,打印出所有数据信息(包含原来输入的学生原始数据信息和求解出来的新信息)。

(2) 对第(1)题实验,求出其中成绩最好的人和成绩最差的人,并显示出来。(假定成绩最好和最差的人都只有一个)

(3)* 如果假定成绩最好和最差的人的个数不一定唯一,程序应该如何修改才能完成求出所有最好和最差者,以及输出它们来。

3.*链表实验。

(1) 建立一个链表,每个结点包含:职工号、工资。用malloc()函数开辟新结点,用free()函数回收不用的结点空间。要求从键盘输入5个员工的数据信息(用create_list()),然后,用函数output_list()将它们一一打印出来,用free_list()将链表中的结点空间回收。假设职工编号为1001,1005,1008,1010,1101。

注:malloc()和free()为系统函数。create_list(),output_list(),free_list()为用户自定义函数。

(2) 在(1)的基础上,新增一个函数inset_node()插入员工1006和1032的数据信息。要求新插入的员工后,员工仍然按职工号顺序排列。

(3) 在(2)的基础上,新增一个函数delete_node(),可以用来将指定员工的数据从链表中删除。

(4) 在(3)的基础上,增加回收所删除结点所占内存空间的功能。

manipulator control mode and programmable controllers introduction 2.1 Select discussion with manipulator control 2.1.1 classification of control relays and discrete electronic circuit can control old industrial equipment, but also more common. Mainly these two relatively cheap and you can meet the old-fashioned, simple (or simple) industrial equipment. So he can see them now, however these two control modes (relay and discrete electronic circuits) are these fatal flaws: (1) cannot adapt to the complex logic control, (2) only for the current project, the lack of compatibility and (3) not reforming the system with equipment improvements. Spring for the development of China's modern industrial automation technology the substantial increase in the level of industrial automation, completed the perfect relay of the computer too much. In terms of controlling the computer showed his two great advantages: (1) each of the hardware can be installed on one or more microprocessors; (2) the official designer of the software writing content control is all about. Now in several ways in the context of industrial automation can often be seen in three ways: (1) Programmable Logical Controller (referred to as IPC); (2) Distributed Control System (DCS for short), and (3) the Programmable Logical Controller (PLC for short). 2.1.2 PLC and the IPC and DCS contrast contrast 1, each of the three technologies of origins and development requirements for fast data processing makes it invented the computer. The men brought in terms of hardware there, using a high level of standardization, can use more compatibility tools, is a rich software resources, especially the need for immediacy in operational systems. So the computer can effectively control is used to control and meet its speed, on the virtual model, real-time and in computational requirements. Distributed system started with a control system for industrial automatic instrument used to control, whereas now it is successfully developed into industrial control computer used as a central collection and distribution system and transition of distributed control system in analogue handling, loop control, has begun to reflect the use of a huge advantage. Though distributed system has great advantages in loop regulation, but only as a means of continuous process control. Optimization of PLC is the corresponding relay needs was born, its main use in the work order control, early primary is replaced relay this hulking system, focused on the switch controlling the running order of functions. Marked by the microprocessor in the early 1970 of the 20th century emerged, micro-electronics technology has developed rapidly, people soon microelectronics processing technology will be used in the Programmable Logical Controller (that isManipulator is now used as a industrial robots in use, the control objectives often appear often in industrial automation. Industrial automation technology has gradually matured, as mature a technology line has been rapid development in industrial automation as a separate subject. Manipulator application began to filter into welding, logistics, mechanical processing, and other industries. Especially at high or very low temperatures, full of poisonous gases, high radiation case, robot in similar circumstances showed great use also brings great convenience to the staff. Precisely because of this robot to get people's attention began to be a high degree of development. Labor rates, working conditions, labor intensive aspects of promoting development. Both at home and abroad to develop the PLC (programmable logic controller) is in various special circumstances and under special conditions set for mechanical devices. Now turned on the development of the microelectronics automatic control technology and the rapid development of thetrains, the success of PLC hardware software and simulation control win big and successful development, now continues to develop as a factory automation standards. Because robots are good development of the technology makes a good optimization of productive capital, and robot shows this unique advantages, such as: has good compatibility, wide availability, hardware is complete, and programming that can be mastered in a short time, so in the context of industrial PLC applications became ubiquitous. Manipulator in many developed country agriculture and industry has been applied, such as the use of mechanical harvesting large areas of farmland, repeated operations on the high-speed line that uses a robotic arm, and so on. oday, the high level of automation combined with restrictions on the manipulator development level is slightly lower than the international. The design is mainly arm welding machine by PLC Automation control. This of design let designers on in school by learn of has a must of consolidation, understand has some usually didn't opportunities awareness in world range within some leading level of knowledge has has must awareness, hope designers can in yihou of design in the can success of using in this design in the proceeds of experience 1.2 manipulator in both at home and abroad of research profile automation mechanical arm research began Yu 20th century medium-term, after years with with computer and automation technology of development, Makes mechanical arm on the Grand stage of industrial automation and shine, gradually became an industrial evaluation standards, and its importance can be seen. Now original robotic arm spent most of mass production and use on the production line, which is programmed robotic arm. As the first generation of manipulator position control systems main features, although not back several generations that can detect the external environment, but can still successfully complete like welding, painting, delivery as well as for materials simple movements. Second generation mechanicalarms are equipped with sensors and manipulators have the environment there is a certain amount of \chanical arm is to use the program as a basis. Difference is that the robot begand (5)* 如何查看和测试链表中结点的内存空间地址?能否由此分析(1)、(2)、(3)中链表结点的逻辑结构? 实验准备:

(1) 复习有关结构体方面的所有知识,尤其是10-3-4节所学的动态存储分配技术;

(2) 编写所选实验题目的程序代码和流程图; (3) 检查源程序并给出其可能的运行结果说明。 实验步骤:

(1) 上机验证所选题目的程序设计结果,并做相应测试和分析; (2) 进行实验分析;

(3) 总结结构体程序设计和实现的基本方法及其经验,尤其是链表技术; (4) 编写实验报告。 实验结果:

(1) 根据测试目标写出测试报告; (2) 测试结果分析说明; (3) 测试程序代码清单。

实验十 位运算和文件操作(2学时)

实验目的:

(1) 掌握位运算的基本概念和方法,以及有关位运算的常见算法和基本应用; (2) 掌握文件和文件指针概念,以及文件的一般定义、操作方法。在此基础上了解有关文件的基本应用并熟悉相关函数。

注:重点掌握缓冲文件系统的操作和运用,在此基础上了解和熟悉文件的顺序读写和随机读写方法。 实验内容:

1. 熟悉位运算的基本操作方法。(以教材例11-1为基础)

2. 了解和熟悉位运算的基本应用。(以教材例11-2~11-6为基础) 3. 熟悉文件操作的基本步骤。(以例12-1~12-7为基础)

4. 了解文件的读、写函数的使用方法。(以例12-8~12-10为基础) 实验准备:

(1) 复习有关位运算和文件操作的基本知识;

(2) 仔细分析教材所提供的各程序实例及其可能执行结果; 实验步骤:

(1) 上机执行各实例程序,并做相应测试和分析;

manipulator control mode and programmable controllers introduction 2.1 Select discussion with manipulator control 2.1.1 classification of control relays and discrete electronic circuit can control old industrial equipment, but also more common. Mainly these two relatively cheap and you can meet the old-fashioned, simple (or simple) industrial equipment. So he can see them now, however these two control modes (relay and discrete electronic circuits) are these fatal flaws: (1) cannot adapt to the complex logic control, (2) only for the current project, the lack of compatibility and (3) not reforming the system with equipment improvements. Spring for the development of China's modern industrial automation technology the substantial increase in the level of industrial automation, completed the perfect relay of the computer too much. In terms of controlling the computer showed his two great advantages: (1) each of the hardware can be installed on one or more microprocessors; (2) the official designer of the software writing content control is all about. Now in several ways in the context of industrial automation can often be seen in three ways: (1) Programmable Logical Controller (referred to as IPC); (2) Distributed Control System (DCS for short), and (3) the Programmable Logical Controller (PLC for short). 2.1.2 PLC and the IPC and DCS contrast contrast 1, each of the three technologies of origins and development requirements for fast data processing makes it invented the computer. The men brought in terms of hardware there, using a high level of standardization, can use more compatibility tools, is a rich software resources, especially the need for immediacy in operational systems. So the computer can effectively control is used to control and meet its speed, on the virtual model, real-time and in computational requirements. Distributed system started with a control system for industrial automatic instrument used to control, whereas now it is successfully developed into industrial control computer used as a central collection and distribution system and transition of distributed control system in analogue handling, loop control, has begun to reflect the use of a huge advantage. Though distributed system has great advantages in loop regulation, but only as a means of continuous process control. Optimization of PLC is the corrsponding relay needs was born, its main use in the work order control, early primary is replaced relay this hulking system, focused on the switch controlling the running order of functions. Marked by the microprocessor in the early 1970 of the 20th century emerged, micro-electronics technology has developed rapidly, people soon microelectronics processing technology will be used in the Programmable Logical Controller (that isManipulator is now used as a industrial robots in use, the control objectives often appear often in industrial automation. Industrial automation technology has gradually matured, as mature a technology line has been rapid development in industrial automation as a separate subject. Manipulator application began to filter into welding, logistics, mechanical processing, and other industries. Especially at high or very low temperatures, full of poisonous gases, high radiation case, robot in similar circumstances showed great use also brings great convenience to the staff. Precisely because of this robot to get people's attention began to be a high degree of development. Labor rates, working conditions, labor intensive aspects of promoting development. Both at home and abroad to develop the PLC (programmable logic controller) is in various special circumstances and under special conditions set for mechanical devices. Now turned on the development of the microelectronics automatic control technology and the rapid development of thetrains, the success of PLC hardware software and simulation control win big and successful development, now continues to develop as a factory automation standards. Because robots are good development of the technology makes a good optimization of productive capital, and robot shows this unique advantages, such as: has good compatibility, wide availability, hardware is complete, and programming that can be mastered in a short time, so in the context of industrial PLC applications became ubiquitous. Manipulator in many developed country agriculture and industry has been applied, such as the use of mechanical harvesting large areas of farmland, repeated operations on the high-speed line that uses a robotic arm, and so on. oday, the high level of automation combined with restrictions on the manipulator development level is slightly lower than the international. The design is mainly arm welding machine by PLC Automation control. This of design let designers on in school by learn of has a must of consolidation, understand has some usually didn't opportunities awareness in world range within some leading level of knowledge has has must awareness, hope designers can in yihou of design in the can success of using in this design in the proceeds of experience 1.2 manipulator in both at home and abroad of research profile automation mechanical arm research began Yu 20th century medium-term, after years with with computer and automation technology of development, Makes mechanical arm on the Grand stage of industrial automation and shine, gradually became an industrial evaluation standards, and its importance can be seen. Now original robotic arm spent most of mass production and use on the production line, which is programmed robotic arm. As the first generation of manipulator position control systems main features, although not back several generations that can detecthe external environment, but can still successfully complete like welding, painting, delivery as well as for materials simple movements. Second generation mechanicalarms are equipped with sensors and manipulators have the environment there is a certain amount of \chanical arm is to use the program as a basis. Difference is that the robot begand(2) 总结基于位运算的程序设计特点及其可能的应用领域;总结文件的基本结构及其操作步骤,以及应用文件的主要问题领域。 (3) 编写实验报告。 实验结果:

(1) 根据测试目标写出测试报告; (2) 测试结果分析说明; (3) 测试程序代码清单。

补充:

1. Ken Thompson(计算机科学家、UNIX的鼻祖、C语言创始人之一)在1983年度ACM的TM奖颁奖大会上所陈述的其曾经编写过的最精练的C语言程序段。请分析该程序段的功能,并上机验证之。

char s[]={

‘\\t’, ‘0’, ‘\\n’, ‘}’, ‘;’, ‘\\n’, ‘\\n’, ‘/’, ‘*’, ‘\\n’, 0

}; /*其中,最后的0以前有213行被删除*/

int main() {

int i;

printf(“char \\ts[]={\\n”); for(i=0;s[i];i++)

printf(“\\t%d,\\n”,s[i]); printf(“%s”,s); return 0; }

2.历史上风格最差的(精巧的C)程序获得者Spencer Hines所写的程序(1987年USENIX大会上Award for Best One-Liner奖)。请分析该程序段的功能和执行结果,并上机运行验证之。

#include char **malloc();

manipulator control mode and programmable controllers introduction 2.1 Select discussion with manipulator control 2.1.1 classification of control relays and discrete electronic circuit can control old industrial equipment, but also more common. Mainly these two relatively cheap and you can meet the old-fashioned, simple (or simple) industrial equipment. So he can see them now, however these two control modes (relay and discrete electronic circuits) are these fatal flaws: (1) cannot adapt to the complex logic control, (2) only for the current project, the lack of compatibility and (3) not reforming the system with equipment improvements. Spring for the development of China's modern industrial automation technology the substantial increase in the level of industrial automation, completed the perfect relay of the computer too much. In terms of controlling the computer showed his two great advantages: (1) each of the hardware can be installed on one or more microprocessors; (2) the official designer of the software writing content control is all about. Now in several ways in the context of industrial automation can often be seen in three ways: (1) Programmable Logical Controller (referred to as IPC); (2) Distributed Control System (DCS for short), and (3) the Programmable Logical Controller (PLC for short). 2.1.2 PLC and the IPC and DCS contrast contrast 1, each of the three technologies of origins and development requirements for fast data processing makes it invented the computer. The men brought in terms of hardware there, using a high level of standardization, can use more compatibility tools, is a rich software resources, especially the need for immediacy in operational systems. So the computer can effectively control is used to control and meet its speed, on the virtual model, real-time and in computational requirements. Distributed system started with a control system for industrial automatic instrument used to control, whereas now it is successfully developed into industrial control computer used as a central collection and distribution system and transition of distributed control system in analogue handling, loop control, has begun to reflect the use of a huge advantage. Though distributed system has great advantages in loop regulation, but only as a means of continuous process control. Optimization of PLC is the corresponding relay needs was born, its main use in the work order control, early primary is replaced relay this hulking system, focused on the switch controlling the running order of functions. Marked by the microprocessor in the early 1970 of the 20th century emerged, micro-electronics technology has developed rapidly, people soon microelectronics processing technology will be used in the Programmable Logical Controller (that isManipulator is now used as a industrial robots in use, the control objectives often appear often in industrial automation. Industrial automation technology has gradually matured, as mature a technology line has been rapid development in industrial automation as a separate subject. Manipulator application began to filter into welding, logistics, mechanical processing, and other industries. Especially at high or very low temperatures, full of poisonous gases, high radiation case, robot in similar circumstances showed great use also brings great convenience to the staff. Precisely because of this robot to get people's attention began to be a high degree of development. Labor rates, working conditions, labor intensive aspects of promoting development. Both at home and abroad to develop the PLC (programmable logic controller) is in various special circumstances and under special conditions set for mechanical devices. Now turned on the development of the microelectronics automatic control technology and the rapid development of thetrains, the success of PLC hardware software and simulation control win big and successful development, now continues to develop as a factory automation standards. Because robots are good development of the technology makes a good optimization of productive capital, and robot shows this unique advantages, such as: has good compatibility, wide availability, hardware is complete, and programming that can be mastered in a short time, so in the context of industrial PLC applications became ubiquitous. Manipulator in many developed country agriculture and industry has been applied, such as the use of mechanical harvesting large areas of farmland, repeated operations on the high-speed line that uses a robotic arm, and so on. oday, the high level of automation combined with restrictions on the manipulator development level is slightly lower than the international. The design is mainly arm welding machine by PLC Automation control. This of design let designers on in school by learn of has a must of consolidation, understand has some usually didn't opportunities awareness in world range within some leading level of knowledge has has must awareness, hope designers can in yihou of design in the can success of using in this design in the proceeds of experience 1.2 manipulator in both at home and abroad of research profile automation mechanical arm research began Yu 20th century medium-term, after years with with computer and automation technology of development, Makes mechanical arm on the Grand stage of industrial automation and shine, gradually became an industrial evaluation standards, and its importance can be seen. Now original robotic arm spent most of mass production and use on the production line, which is programmed robotic arm. As the first generation of manipulator position control systems main features, although not back several generations that can detect the external environment, but can still successfully complete like welding, painting, delivery as well as for materials simple movements. Second generation mechanicalarms are equipped with sensors and manipulators have the environment there is a certain amount of \chanical arm is to use the program as a basis. Difference is that the robot begand int main(togo,toog) int togo; char *toog[]; {

char *ogto,

tgoo[80];FILE *ogot;int ootg,otog=79;

ottg=1;if(togo==ottg) goto gogo;goto goog;ggot; if (fgets(tgoo,otog,ogot)) goto gtgo;goto gott;

gtot:exit();ogtg:++oogt;goto ogoo;togg:if(ootg>0) goto oggt;goto ggot;ogog:if(!ogot) goto gogo; goto ggto;gtto:printf(“%dgoto\\’s\\n”,oogt);

goto gtot;oggt:if(!memcmp(ogto,“goto”,4)) goto otgg; goto gooo;gogo:exit(ottg);tggo:ootg=strlen(tgoo); goto tgog;oogo:--ootg;goto togg;

goo:--ogto;goto oogo;gott;fclose(ogto); goto gtto;otgg:ogto=ogto+3;

goto ogtg;tgog:ootg-=4;goto togg;gtgo:ogto=tgoo; goto tggo;ogoo:ootg-=3;goto gooo;goog:ogot=fopeb( toog[ottg],“r”);goto ogog;ggto:ogto=tgoo;goto ggot;} return 0; }

实验指导手册制定人:冯山

2008年9月

manipulator control mode and programmable controllers introduction 2.1 Select discussion with manipulator control 2.1.1 classification of control relays and discrete electronic circuit can control old industrial equipment, but also more common. Mainly these two relatively cheap and you can meet the old-fashioned, simple (or simple) industrial equipment. So he can see them now, however these two control modes (relay and discrete electronic circuits) are these fatal flaws: (1) cannot adapt to the complex logic control, (2) only for the current project, the lack of compatibility and (3) not reforming the system with equipment improvements. Spring for the development of China's modern industrial automation technology the substantial increase in the level of industrial automation, completed the perfect relay of the computer too much. In terms of controlling the computer showed his two great advantages: (1) each of the hardware can be installed on one or more microprocessors; (2) the official designer of the software writing content control is all about. Now in several ways in the context of industrial automation can often be seen in three ways: (1) Programmable Logical Controller (referred to as IPC); (2) Distributed Control System (DCS for short), and (3) the Programmable Logical Controller (PLC for short). 2.1.2 PLC and the IPC and DCS contrast contrast 1, each of the three technologies of origins and development requirements for fast data processing makes it invented the computer. The men brought in terms of hardware there, using a high level of standardization, can use more compatibility tools, is a rich software resources, especially the need for immediacy in operational systems. So the computer can effectively control is used to control and meet its speed, on the virtual model, real-time and in computational requirements. Distributed system started with a control system for industrial automatic instrument used to control, whereas now it is successfully developed into industrial control computer used as a central collection and distribution system and transition of distributed control system in analogue handling, loop control, has begun to reflect the use of a huge advantage. Though distributed system has great advantages in loop regulation, but only as a means of continuous process control. Optimization of PLC is the corrsponding relay needs was born, its main use in the work order control, early primary is replaced relay this hulking system, focused on the switch controlling the running order of functions. Marked by the microprocessor in the early 1970 of the 20th century emerged, micro-electronics technology has developed rapidly, people soon microelectronics processing technology will be used in the Programmable Logical Controller (that is


《程序设计基础教程 - -C语言版》实验指导手册(4).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:离婚房产分割律师实务策略

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: