Method for realizing PLC port control by C language in digital control machine tool system

A CNC machine tool and port control technology, applied in digital control, electrical program control, etc., can solve the problems of difficult writing of PLC programs and difficult understanding of PLC language, and achieve the effects of wide application range, simple and convenient processing process, stable and reliable work

Inactive Publication Date: 2010-02-17
SHANGHAI WEIHONG ELECTRONICS TECH
View PDF0 Cites 1 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

The existing PLC configures ports, but the PLC language is not easy to understand, and sometimes the PLC program is difficult to write, which requires a simple and easy-to-understand language to achieve this purpose

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Method for realizing PLC port control by C language in digital control machine tool system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0019] In order to make it easy to understand the technical means, creative features, objectives and effects achieved by the present invention, the present invention will be further explained below in conjunction with specific drawings.

[0020] See figure 1

[0021] 1. Obtain port information and port address information in the timer

[0022] To use the C language to control the port, we must first obtain the information of the port. Our timer has a high accuracy, scanning every 20 milliseconds to obtain the current port status.

[0023] How to get the port address:

[0024] 11. Addressing method of physical port:

[0025] The physical ports are divided into input ports and output ports. They are addressed in channel mode, each channel has 32 numbers, that is, each channel can accommodate 32 ports. Among them, 100 channels are divided into input ports and output ports, which means that the system can accommodate 3200 physical input ports and 3200 physical output ports. The port addre...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

The invention relates to a method for realizing PLC port control by C language in a digital control machine tool system, which comprises the following steps: 1. scanning a port by a timer to obtain port information; 2. processing the port information by C language to generate a C language port processing program; 3. calling a C language port to process a generated library file; 4. scanning by thetimer to obtain a port state; and 5. giving back the port information to a drive. The method can control the port of a digital control machine tool by the C language, effectively substitutes the control of a PLC on the port, solves the problems of difficult understanding and writing of a PLC language and has simple and convenient processing process, stable and reliable working and wide applicationrange.

Description

Technical field [0001] The invention relates to the field of numerical control machine tool systems, in particular to the technical field of numerical control machine tool system port control, and specifically refers to a method for completing PLC control of ports in a numerical control machine tool system using C language. Background technique [0002] Manufacturing is the basic industry of the national economy. The level of manufacturing is an important indicator of the degree of industrial development in a country. The level of CNC machine tools is related to the level of national manufacturing. [0003] In the existing technology, we will use the numerical control system to perform corresponding cutting or welding. When using a machine tool to perform high-pressure water jet cutting operations, or other cutting and engraving, it is sometimes necessary to open certain ports for output, such as water cutting. The water valve, high pressure, sand valve, etc. also need to close the...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
IPC IPC(8): G05B19/18
Inventor 牟凤林齐伟郑之开
Owner SHANGHAI WEIHONG ELECTRONICS TECH
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products