




已阅读5页,还剩29页未读, 继续免费阅读
版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
EMC2_Getting_StartedEMC2_Getting_Started_123章DISCLAIMER- THE AUTHORS OF THIS LIBRARY ACCEPT ABSOLUTELY NO LIABILITY FOR ANY HARM OR LOSS RESULTING FROM ITS USE. IT IS _EXTREMELY_ UNWISE TO RELY ON SOFTWARE ALONE FOR SAFETY. Any machinery capable of harming persons must have provisions for completely removing power from all motors, etc, before persons enter any danger area. All machinery must be designed to comply with local and national safety codes, and the authors of this software can not, and do not, take any responsibility for such compliance.免责声明- 本文作者坚决不对任何读者因使用本文而导致的任何财产损失或者身体伤害承担任何责任。仅仅指望计算机软件或技术文件来确保和解决安全问题也是极不明智的表现。任何机器,只要它有伤人的可能,就必须制定严格的制度来管理它。比如可以规定“在人体进入危险区域之前,必须确保所有电机断电”等条款。事实上,设计任何一种机器设备都需要遵循所在国家或地区的各种不同级别的安全标准,本文的作者显然无法了解和满足如此多的标准要求,所以也就不能承担相关的责任。Mission Statement-EMC2 is an offshoot of the original NIST Enhanced Machine Controller. The new version is (primarily) a GPLd project.The major goals are:1) Make the project more friendly to new developers. This means a simpler build process, as well as other changes listed below. (DONE)2) Reduce complexity by eliminating support for platforms other than Linux on x86, with either RTAI or RTLinux for realtime. (DONE)3) Incorporate a Hardware Abstraction Layer that makes the realtime code more modular and allows pins and I/O devices to be reconfigured easily. (DONE)4) Add some of the features that were discussed at the 2003 NAMES show on EMC Monday - these include rigid tapping and single point threading, improved contouring, a built- in PLC using ClassicLadder, and others. (mostly DONE, yet new features will constantly be added)任务描述- EMC2最初是 NIST Enhanced Machine Controller 项目的一个分支,现在它是一个GPL的项目,EMC2目前致力于以下四个目标:1)使EMC2项目对新手来说更加易于使用,且易于编译与安装。2)为了减少复杂度,决定:除了X86-Linux平台以外,EMC2都不提供支持。在实时性方面,也只提供RTAI或者RTLinux的支持。3)EMC2包括了一个硬件抽象层(Hardware Abstraction Layer),HAL使得硬件相关的实时代码更加模块化,从而让外部接口(pins and I/O devices)更易于配置,这样就提高了软件的灵活性以及适应能力。4)增加了一些功能,包括刚性攻丝和单点线程、增强的轮廓功能、用ClassLadder实现的内置PLC功能(rigid tapping and single point threading、improved contouring、built-in PLC using ClassicLadder) 等等。-以上节选自源码包根目录的README文件目录第 1 章 计算机配置1.1 最小配置 The minimum system to run EMC2 and Ubuntu may vary depending on the exact usage. Stepper systems in general require faster threads to generate step pulses than servo systems. Using the Live-CD you can test the software before committing a computer. Keep in mind that the Latency Test numbers are more important than the processor speed for software step generation.More information on the Latency Test is in Section (7.2.1).Additional information is on the EMC Wiki site: /cgi-bin/emcinfo.pl?Hardware_Requirements 事实上,最小配置是什么样的并不确定,这取决于具体的应用。总的来说,分管线程切换的时间片分配系统(Stepper systems)要足够快,起码要能产生比伺服系统还要快的步进脉冲才行。要注意, CPU的速度肯定是越快越好,但不是最终决定因素,相对而言,Live-CD里面提供的Latency Test功能反而更加重要,Latency Test可以最终判断目标机器是否适合运行EMC2系统。关于Latency Test的详细信息参见(7.2.1)。要了解更多信息,您还可以去下面的网址去看看:/cgi-bin/emcinfo.pl?Hardware_RequirementsEMC2 and Ubuntu should run reasonably well on a computer with the following minimum hardware specification. These numbers are not the absolute minimum but will give reasonable performance for most stepper systems.700 MHz x86 processor (1.2 GHz x86 processor recommended).384 MB of RAM (512 MB up to 1 GB recommended).4 GB hard disk.Graphics card capable of at least 800x600 resolution, which is not using the NVidia or ATI fglrx proprietary drivers, and which is not an onboard video chipset that shares main memory with the CPU.A network or Internet connection (not strictly needed, but very useful for updates and for communicating with the EMC community).当然,这里还是给出了一个推荐的配置。虽然这不一定是最合适的,但它在大多数情况下可以获得相当不错的性能。700 MHz x86 处理器 (1.2 GHz x86 更佳).384 MB 内存 (512 MB - 1 GB 更佳).4 GB 硬盘空间.显卡分辨率最低800*600,不要使用 NVidia 或者 ATI fglrx 这样专有的驱动程序,也不要使用集成显卡,因为它们会和CPU抢内存用。有网络,能上Internet最好,这样可以方便升级,也利于及时从社区里面查找相关的技术信息。1.2 不推荐的配置1.2.1 Laptops Laptops are not generally suited to real time software step generation.Again a Latency Test run for an extended time will give you the info you need to determine suitability.1.2.2 Video Cards If your installation pops up with 800 x 600 screen resolution then most likely Ubuntu does not recognize your video card or monitor. Onboard video many times causes bad real time performance. 笔记本一般不适于运行EMC2,当然具体能不能用还是取决于Latency Test。如果系统安装后,显示器分辨率是800*600,那多半是Ubuntu没能识别你的显卡或显示器。再说一遍,集成显卡通常不适合用于EMC2这样的实时系统。第 2 章 关于EMC2.1 是什么和不是什么 EMC (the Enhanced Machine Control) is a software system for computer control of machine tools such as milling machines and lathes.EMC is free software with open source code. Current versions of EMC are entirely licensed under the GNU General Public License and Lesser GNU General Public License (GPL and LGPL)EMC provides: a graphical user interface (actually several interfaces to chose from) an interpreter for G-code (the RS-274 machine tool programming language) a realtime motion planning system with look-ahead operation of low-level machine electronics such as sensors and motor drives an easy to use breadboard layer for quickly creating a unique configuration for your machine a software PLC programmable with ladder diagrams easy installation with a Live-CDIt does not provide drawing (CAD - Computer Aided Design) or G-code generation from the drawing (CAM - Computer Automated Manufacturing) functions. It can simultaneously move up to 9 axes and supports a variety of interfaces. The control can operate true servos (analog or PWM) with the feedback loop closed by the EMC software at the computer, or open loop with step-servos or stepper motors. Motion control features include: cutter radius and length compensation, path deviation limited to a specified tolerance, lathe threading, synchronized axis motion, adaptive feedrate, operator feed override, and constant velocity control. Support for non-Cartesian motion systems is provided via custom kinematics modules. Available architectures include hexapods (Stewart platforms and similar concepts) and systems with rotary joints to provide motion such as PUMA or SCARA robots. EMC runs on Linux using real time extensions. EMC(增强机器控制)是一款用来控制机床(铣床、车床等)的计算机软件系统。EMC是一款开源的自由软件。当前版本的许可是GPL 和 LGPL。EMC特点: - 提供几种不同的用户界面供选择使用 - G代码解释器(基于RS-274机床编程语言) - 带预处理功能的实时运动规划系统 - 可直接操作底层的机床电器如传感器、电机驱动器等 - 易于使用的“面包板层”(breadboard layer),使您像使用“面包板”做电路实验一样很容易的创建适合您机器的独有配置文件 - 可用梯形图编程操作的PLC软件(指ClassicLadder) - 所有这些都集成到一张Live-CD上面,易于安装。不提供CAD和CAM功能,不能画图,也不能从图直接导出G-Code。9轴联动,支持不同接口。可以实现闭环运动控制,也可以使用开环控制。能够控制模拟或PWM接口的伺服电机。运动控制特点:刀具半径和长度补偿、路径偏差可限制在给定的误差范围内、车床车螺纹、多轴联动、自适应进给速度、手动进给覆盖(operator feed override)、恒速控制。 通过调整运动学模块的参数,可以提供对非笛卡尔运动系统的支持。EMC2支持的其他架构包括:六足系统(Stewart或类似的机器人平台)、带旋转关节的系统(通常为PUMA或SCARA机器人提供运动支持)。EMC运行在使用实时扩展模块(RTAI或者RTLinux)的Linux操作系统中。2.2 为什么是Ubuntu? Ubuntu has been chosen, because it fits perfectly into the Open Source views of EMC2: Ubuntu will always be free of charge, and there is no extra fee for the enterprise edition, we make our very best work available to everyone on the same Free terms. EMC is paired with the LTS versions of Ubuntu which provide support and security fixes from the Ubuntu team for 3 - 5 years.Ubuntu uses the very best in translations and accessibility infrastructure that the Free Software community has to offer, to make Ubuntu usable for as many people as possible. The Ubuntu community is entirely committed to the principles of free software development; we encourage people to use open source software, improve it and pass it on. 选择Ubuntu,是因为它和EMC2的开源观点最为契合。Ubuntu永远不会收费,也没有所谓的“企业版”费用。而我们也同样尽最大努力把最好的成果免费展示给每一个人。EMC2与Ubuntu配套已经3-5年了,Ubuntu一直积极提供技术支持和安全支持。Ubuntu尽最大努力致力于推广工作,做到了免费软件社区所能做到的一切,这些都使得越来越多的人使用Ubuntu。Ubuntu是遵守自由软件开发原则的典范,我们鼓励人们使用、提高、传承开源软件。第 3 章 如何获得帮助3.1 IRC IRC stands for Internet Relay Chat. It is a live connection to other EMC users. The EMC IRC channel is #emc on freenode. The simplest way to get on the IRC is to use the embedded java client onthis page /content/view/4/8/lang,en/.Some IRC etiquette:Ask specific questions. Avoid Can someone help me?, It wont run type of questions. If youre really new to all this, think a bit about your question before typing it. Make sure you give enough information so someone can solve your question. Have some patience when waiting for an answer, sometimes it takes a while to formulate an answer or everyone might be busy working or something. Set up your IRC account with your unique name so people will know who you are. If you use the java client, use the same name every time you log in. This helps people remember who you are and if you have been on before many will remember the past discussions which saves time on both ends.3.1.1 Sharing Files The most common way to share files on the IRC is to upload the file to one of the following or a similar service and paste the link:http:/pastebin.ca = for texthttp:/imagebin.ca = for pictureshttp:/filebin.ca = for files and pdfsIRC,代表“互联网接力聊天”的意思,它是一个和其它EMC用户实时连接的工具。(译者注:事实上这个工具对大部分中国读者没什么帮助,就不翻译了。)3.2 邮件列表 An Internet Mailing List is a way to put questions out for everyone on that list to see and answer at their convenience. You get better exposure to your questions on a mailing list than on the IRC but answers take longer. In a nutshell you e-mail a message to the list and either get daily digests or individual replies back depending on how you set up your account. Information about the EMC Users Mailing List at: /lists/listinfo/emc-users(和IRC差不多,也不翻译了。)3.3 EMC Wiki网站 A Wiki site is a user maintained web site that anyone can add to or edit. The user maintained EMC Wiki site contains a wealth of information and tips at:/cgi-bin/emcinfo.pl EMC Wiki网站是一个由用户维护的网站,任何人都可以添加和编辑网站的内容。下面这个网站里就有大量的技术信息(值得看一看)。 /cgi-bin/emcinfo.pl第 4 章 安装EMC24.1 正常下载Download the Live CD from: /and follow the Download link.从/网站可以找到Live CD并下载。4.2 用Wget下载如果你的网络条件不好,可以用Wget下载。(译者注:这个就不介绍了)4.3 烧录CD 如果要安装到真机,需要烧录到CD(700M容量的CD)。如果用虚拟机,可以不必烧录,虚拟机一般可以直接使用ISO文件当光驱使用。4.4 测试EMC2 With the Live CD in the CD/DVD drive shut down the computer then turn the computer back on. This will boot the computer from the Live CD. Once the computer has booted up you can try out EMC2 without installing it. You can not create custom configurations or modify most system settings like screen resolution unless you install EMC2. To try out EMC2 from the Applications/CNC menu pick EMC2. Then select a sim configuration to try out. To see if your computer is suitable for software step pulse generation run the Latency Test as outlined in Section (7.2.1) 把烧录好的CD放入光驱,关机,开机,设置BIOS从光盘启动,Ubuntu就启动了。 Live CD里面包含了Ubuntu和EMC2 的所有文件,而且有一个好处,就是可以非安装运行(类似一个应急启动盘)。当然非安装运行(以下叫“测试运行”)时不能创建用户配置文件、不能修改大部分系统设置。不过这并不影响测试工作,从而确定这台机器是否适合安装Live CD。 Ubuntu从光盘启动以后,会有两个分支(参见图1-光盘启动1.gif),此时单击“Try Ubuntu 10.04 LTS”就可进入测试运行。而另一个分支“Install Ubuntu 10.04LTS”就是把Ubuntu和EMC2真正安装到机器的硬盘上了。 图1-光盘启动1.gif 进入测试运行模式以后,Ubuntu看起来是这个样子(参见图2-光盘启动2.gif)。 图2-光盘启动2.gif 要体验一下EMC2,就在Ubuntu界面里面依次单击Applications-CNC-EMC2(参见图3-光盘启动3.gif), 图3-光盘启动3.gif会进入到选择配置的界面“EMC2 Configuration Selector”,在该界面中要选择一个模拟配置(sim 那一组的,比如选 sim-axis),再点击OK按钮(参见图4-光盘启动4.gif),图4-光盘启动4.gif 接下来如果有对话框出现就一律选YES或OK,就会出现“Axis Interface”界面(参见图5-光盘启动5.gif)。图5-光盘启动5.gif 如果你看到了这个界面,那么恭喜你,前面的工作一切顺利,你已经和EMC2握手寒暄了。怎么知道你的机器是否适合跑EMC2呢?用Latency Test吧。依次单击Applications-CNC-Latency Test就可以启动这个测试。(详细说明参见7.2.1)4.5 安装EMC2 If you like what you see, just click the Install icon on the desktop, answer a few questions (your name, timezone, password) and the install completes in a few minutes. Make sure you write down the name you used and the password. Once the install process is complete and you go on line the update manager will pop up and allow you to upgrade to the latest stable version of EMC2. 要是你对测试运行的结果满意,只要双击桌面那个唯一的图标“Install Ubuntu 10.04 LTS”就可以了,当然你也可以重新从光盘启动(参见图1 -光盘启动1.gif),在图1 那个界面单击“Install Ubuntu 10.04 LTS”按钮同样可以启动EMC2安装。安装过程中只需回答几个问题即可:语言、地理位置(时区)、键盘布局、硬盘分区、姓名用户名密码等。其中的用户名密码需要你记住,因为以后登录要用到,其他的选择默认即可。安装过程不会有什么问题。安装完毕、重新启动后,还可以用更新管理器(update manager)升级需要升级的软件。4.6 Axis Interface The AXIS interface is one of the interfaces to choose from. It can be configured to add a Virtual Control Panel to customize the interface to suit your needs. AXIS is the default user interface and is actively being developed. 第一次打开 EM2看到的界面就是“Axis Interface”,其实这个“Axis Interface” 只是EMC2的默认界面(参见图5-光盘启动5.gif),你当然还可以选择其他的界面使用。(关于界面及界面的使用此处不做介绍)4.7 更新EMC2 With the normal install the Update Manager will notify you of updates to EMC2 when you go on line and allow you to easily upgrade with no Linux knowledge needed. If you want to upgrade to 10.04 from 8.04 a clean install from the Live-CD is needed. It is OK to upgrade EMC when asked to. Warning: Do not upgrade Ubuntu to a new version (like 8.04 to 8.10) as it will prevent EMC from running. 正常安装成功以后,Update Manager会通知并帮助你更新EMC2到最新版本,即使你没有Linux知识也没关系。但是要注意,不推荐升级Ubuntu到新的版本(比如从8.04到8.10),可能会有兼容性的问题。如果一定要升级,不如选一个新版本的Live CD彻底重新安装。4.8 可能的安装问题 In rare cases you might have to reset the BIOS to default settings if during the Live CD install it can not recognize the hard drive during the boot up. 如果安装过程中找不到硬盘,可能需要从BIOS里面恢复默认的设置。 (译者注:也许有时候把硬盘接线拔下来再重新插上也会管用,这样可以解决硬件接触不良的问题。在识别硬盘的情况下,有时候也不是一帆风顺的,可能需要两到三次重新安装才能成功。这取决于你的硬件,我说的这些问题是在我2003年买的一个3000元的神舟电脑上做实验时碰到的。通常情况下你应该不会碰到这些问题。)(译者注:中文环境也是个问题,感觉EMC2中文界面有些不太好用,因此本文将一直采用英文界面进行讲解,Live CD的版本是: ubuntu-10.04-linuxcnc1-i386.iso )第 5 章 升级EMC2 (译者注:本章描述了如何从2.3.X升级到2.4.X的过程。有此需求的都是使用过2.3.X的朋友,都是高手了,可以自己看一看原版英文,就不翻译了。)第 6 章 EMC2配置过程 This section assumes you have done a standard install from the Live CD. After installation it is recommended that you connect the computer to the Internet and wait for the update manager to pop up and get the latest updates for EMC and Ubuntu before continuing. For more complex installations see the Integrators Manual. 现在你应该已经用Live CD把Ubuntu和EMC2安装到了你的计算机上。此时最好能连接到互联网Internet,然后等待update manager自动弹出来,让 update manager自动把要打的补丁给你装上,然后再继续我们的EMC2旅程。更高级或复杂的安装信息可以继续看Integrators Manual(译者注:另一本手册,比这本厚多了,有时间再翻译吧)。6.1 Latency Test The Latency Test determines how late your computer processor is in responding to a request. Some hardware can interrupt the processing which could cause missed steps when running a CNC machine. This is the first thing you need to do. Follow the instructions in section (7.2.1) to run the latency test. 延迟测试(Latency Test)可以判断你的计算机CPU对请求响应速度的快慢程度。当一台CNC机床运行时,有些硬件可能会中断CPU的运行,从而导致丢步的情况发生,所以,计算CPU的实际响应时间就尤为重要。因此第一件要做的事情就是按照7.2.1节的介绍执行延迟测试。6.2 Sherline机床6.3 Xylotex电机驱动 If you have a Sherline several predefined configurations are provided. This is on the main menuCNC/EMC then pick the Sherline configuration that matches yours and save a copy.If you have a Xylotex you can skip the following sections and go straight to the Stepper Config Wizard in Section (7). EMC has provided quick setup for the Xylotex machines. EMC2显然也有一些合作伙伴,Sherline和Xylotex应该就属于这一类的吧,所以这两家的产品自然被EMC2支持的完善一些。Sherline的机床直接有预定义的配置,只要启动EMC2时选择一下就可以直接使用了,根本无需配置。Xylotex电机驱动,虽然也要配置一下,但并不需要收集信息什么的,在配置向导stepconf里面就可以直接快速配置了。(译者注:如果不是EMC2的合作伙伴,那就只能按6.4、6.5、6.6逐步收集信息,再运行配置向导一步一步的生成配置了)6.4 机床信息 Gather the information about each axis of your machine.Drive timing is in nano seconds. If youre unsure about the timing many popular drives are included in the stepper configuration wizard. Note some newer Gecko drives have different timing than the original one. A list is also on the user maintained EMC wiki site of more drives at http: /. Axis Drive Type Step Time ns Step Space ns Direction Hold ns Direction Setup ns X Y Z 收集机床所使用的各个轴(电机或电机驱动)的信息(单位是纳秒)。这些信息应该可以由电机或电机驱动的供应商提供。在配置向导里有一些预设的类型可供选择,注意Gecko驱动是新型号的,和老型号的参数不再一样,不要搞混了。Wiki网站/里面有一些补充的品牌或类型可以参考一下。6.5 引脚信息Gather the information about the connections from your machine to the PC parallel port.Output Pin Typical Function If Different Input Pin Typical Function If Different1 E-Stop Out 10 Both Limit & Home X2 X Step 11 Both Limit & Home Y3 X Direction 12 Both Limit & Home Z4 Y Step 13 Both Limit & Home A5 Y Direction 15 Probe In6 Z Step7 Z Direction8 A Step9 A Direction14 Spindle CW16 Spindle PWM17 Amplifier EnableNote any pins not used should be set to Unused in the drop down box. These can always be changedlater by running Stepconf again. 收集机床和PC计算机并口的连接信息,确定并口各引脚的功能。注意不用的引脚要设成“Unused”。如果需要,这些设置都可以用配置向导随时修改。 6.6 机械信息 Gather information on steps and gearing. The result of this is steps per user unit which is usedfor SCALE in the .ini file.Axis Steps/Revolution Micro steps Motor Teeth Leadscrew Teeth Leadscrew PitchSteps per revolution is how many steps it takes to turn the stepper one revolution.Micro steps is how many steps the drive needs to move the stepper one step.Motor & Leadscrew Teeth is if you have some reduction between the motor and the leadscrew. If not set these to 1.Leadscrew pitch is how many turns it takes to move your table one user unit. If youre setting up in inches then it is turns per inch. If youre setting up in millimeters
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 二零二五年度出国劳务人员子女教育服务协议
- 2025年心理咨询师从业资格认证面试模拟题集及答案解析
- 2025年高级新媒体运营专家面试预测题及解析集萃
- 2025版电力工程知识产权保护合同范本
- 2025版股权置换与重组投资顾问服务合同
- 二零二五版每日合同合伙聘用创新合作协议
- 二零二五年物流行业专业人才雇佣协议
- 2025版婚生女离婚抚养权争议解决与财产权益保障执行协议
- 二零二五版不锈钢材料加工中心建设与运营合同
- 二零二五年现房交付二手房屋贷款买卖合同
- 办公室文秘岗试题带答案
- 2025年河南疾控中心考试题库
- 2025-2026学年人教精通版四年级英语上册(全册)教学设计(附目录)
- 2025年【高压电工】模拟试题及答案
- 养老护理员竞赛理论试卷答案(含答案)
- 2025年四川省能源投资集团有限责任公司人员招聘笔试备考题库及答案详解(新)
- 广东省公路服务区管理系统升级及运维项目
- 2025版《中国系统性红斑狼疮诊疗指南》解读 4
- 造林后续管理办法
- 市政施工安全培训课件
- 培训完总结做个课件
评论
0/150
提交评论