CN101534259A - An asynchronous communication controller and its control method - Google Patents

An asynchronous communication controller and its control method Download PDF

Info

Publication number
CN101534259A
CN101534259A CN200910136863A CN200910136863A CN101534259A CN 101534259 A CN101534259 A CN 101534259A CN 200910136863 A CN200910136863 A CN 200910136863A CN 200910136863 A CN200910136863 A CN 200910136863A CN 101534259 A CN101534259 A CN 101534259A
Authority
CN
China
Prior art keywords
data
frame
communication
memory cell
packet
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN200910136863A
Other languages
Chinese (zh)
Other versions
CN101534259B (en
Inventor
范多旺
魏宗寿
方亚非
陈光武
喻俊淇
葛立明
何涛
牛宏侠
旷文珍
魏文军
邢东峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Lanzhou Dacheng Railway Signal Co ltd
Original Assignee
DACHENG AUTOMATION ENGINEERING Co Ltd LANZHOU
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by DACHENG AUTOMATION ENGINEERING Co Ltd LANZHOU filed Critical DACHENG AUTOMATION ENGINEERING Co Ltd LANZHOU
Priority to CN2009101368630A priority Critical patent/CN101534259B/en
Publication of CN101534259A publication Critical patent/CN101534259A/en
Application granted granted Critical
Publication of CN101534259B publication Critical patent/CN101534259B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention principally relates to an asynchronous communication controller and its control method, particularly to a communication controller using a data frame form to perform information communication because various application environments can be configured, and its data transmission and communication control method. A kind of asynchronous communication controller, uses configurable data storage unit, is a rapid asynchronous communication of multi-frame data packets supporting single frame data pack and adapt for various communication modes, which has main features that it includes a data packet storage unit (2) communicated to a CPU (1), a control unit (3) is respectively communicated with the data packet storage unit (2), a sending unit (4), and a receiving unit (5), and the sending unit (4) is communicated to a receiving unit (5) through a communication physical channel (6). The invention has advantage that: compared with the existing technology, the invention solves the problems of the existing communication controller and control method thereof, such as single communication corresponding mode, single adapting to the application environment, and incapability of no dynamic change.

Description

Asynchronous communication controller and control method thereof
Technical field:
The present invention relates generally to a kind of asynchronous communication controller and control method thereof, particularly a kind of communication controler and the transfer of data and communication control method that carries out information communication with form of data frames that can be configured in response to multiple applied environment.
Background technology:
Existing communication controler and communication mode, the main problem that has following three aspects:
The one, at present the communication controler that exists is all only supported wherein a kind of of following communication mode, can not change in these communication modes dynamically.Duplex communication pattern one to one, i.e. communication only takes place between two terminals, is the communication pattern of most of communication controlers.One-to-many simplex pattern is a terminal sends identical data, an one-way communication pattern from the reception of a plurality of terminal to a plurality of terminals.Many-one simplex pattern is a plurality of terminals send data, an one-way communication pattern from this terminal reception to same terminal.One-to-many duplex communication pattern is that a terminal sends identical data and receives the different data that a plurality of terminals are sent to a plurality of terminals.
The 2nd, communications applications has the different of multiframe data and single frames data, also has the difference of packet size, and these different application demands require the nature difference to communication controler.Present communication controler can only be fixed in a certain application, must substitute with another communication controler when applied environment changes.
The 3rd, the data-handling capacity deficiency when data processing side to receiving, when occurring handling untimely situation, the existing communication controller has two kinds of processing policies.The one, follow-up data covers the data of before having received, this can cause receiving side data to lose; The 2nd, the recipient does not do to comprehend to follow-up data before the data of receiving deal with, and this recipient can occur to transmit leg does not respond or the response time is long problem.
Summary of the invention:
The objective of the invention is to avoid the deficiencies in the prior art part, a kind of asynchronous communication controller and communication control method thereof are provided, single, single to solve the communication controler and the control method communication corresponded manner that exist at present to the adaptation of using environment, the problem that can not dynamically be configured.The present invention can support the dynamic translation of duplex communication pattern one to one, one-to-many simplex pattern and many-one simplex pattern, one-to-many duplex communication pattern by configuration control unit register.
Another object of the present invention is to different application background, can finish conversion, do not need to change the communication controler that hardware just can provide support by configuration control unit register to different, the packet size of multiframe data and single frames data.
The present invention also has a purpose to be to send and receives the formation mode that adopts, with the bottleneck problem between solving processing and communicating by letter.Make the queue length dynamic adjustable by the control unit register, then can adopt the different buffer memory degree of depth, thereby avoid loss of data and improve response speed according to the difference of concrete application.
Purpose of the present invention can be by realizing by the following technical solutions: a kind of asynchronous communication controller, adopt configurable data storage cell, support the quick asynchronous communication of the multiframe packet of single frames packet, the multiple communication mode of adaptation, its main feature is the packet memory cell (2) that includes with CPU (1) UNICOM, control unit (3) respectively with packet memory cell (2), transmitting element (4), receiving element (5) UNICOM, transmitting element (4) by communication the physical channel (6) with receiving element (5) UNICOM:
Described memory cell (2) is deployment queue length, configuration data bag memory cell size, supports the quick asynchronous communication of single frames packet, multiframe packet;
Described transmitting element (4) sends the data of memory cell by data transmit circuit according to self-defined High-speed Asynchronous Secial Communication control protocol; Self-defined high-speed asynchronous serial comprises line idle state (idle, high level), start bit (startbit, low level), 16 bit data positions (data bits) and position of rest (stop bit, figure place is 1), this form be by start bit and position of rest realize 16 bit data synchronously;
Described receiving element (5) receives data by data receiver circuit, and data storing is being received memory cell;
The different control models that described control unit (3) is provided with according to register are controlled and are started memory cell (2), receiving element (5) and transmitting element (4).
Described asynchronous communication controller, described packet memory cell (2) comprise transmission memory cell (2-0) and receive memory cell (2-1); Wherein receiving memory cell is to receive data and storage data by data reception module according to communication control processor; Transmitting element is by the data of data transmission blocks according to communication control processor transmission memory cell.Described packet memory cell (2) memory space is divided into six sections, is made up of the reception memory space of 4K byte and the transmission memory space of 4K byte for every section, and memory space address is not overlapping, every section memory space correspondence sending module and receiver module separately; Described packet memory cell (2) is connected with ppu bus interface (1-1) by parallel bus, and two-way read-write realizes the not conversion of isotopic number of data; The address halfword-aligned promptly is 2 multiple according to 16 alignment requirements.
Described asynchronous communication controller, described communication controler memory cell (2) also includes queuing register group (2-2), control register group (2-3), status register group (2-4), transmitting-receiving buffer area (2-0,2-1), described transmitting-receiving buffer area (2-0,2-1) and queuing register group (2-2), control register group (2-3), status register group (2-4) memory space address are not overlapping, every section transmitting-receiving memory space correspondence sending module and receiver module separately.Queuing register group (2-2), control register group (2-3), status register group (2-4) take memory cell (2) internal storage location, are consistent with the memory access interface of receiving and dispatching buffer area (2-0,2-1).The working method of the value decision control unit (3) of these registers group configurations.Ppu can obtain the cell stores spatiality by the status register of access control unit, and transmitting element and receiving element operating state receive packet data verification state.Ppu changes the different sending modes and the passage of controller by the control register of access control unit, starts and stop transmitting element and receiving element work.
Described asynchronous communication controller, described receiving element (5) includes a plurality of receiver modules, each receiver module correspondence reception storage unit space separately; Described transmitting element (4) includes a plurality of sending modules, each sending module correspondence transmission (reception) storage unit space separately.
Described asynchronous communication controller, a plurality of sending module correspondences of a plurality of receiver modules of described receiving element (5) and described transmitting element (4), control by described control unit (3), realize that a circuit-switched data sends by a plurality of transmitting elements are parallel, or multichannel data sends in proper order by a transmitting element, or multichannel data sends by sending module separately.
Described asynchronous communication controller, described control unit (3) includes the reception control module (3-1-2) that is connected with described receiving element (5), and described reception control module (3-1-2) links to each other with reception length identification module (3-1-1), accepting state module (3-1-3), resolution data frame module (3-1-4) respectively.
Described asynchronous communication controller, described control unit (3) also includes the transmission control module (3-2-2) that is connected with described transmitting element (4), and described transmission control module (3-2-2) links to each other with transmission length identification module (3-2-1), transmit status module (3-2-3), padding data frame module (3-2-4) respectively.
The data transmission method of described asynchronous communication controller, its main feature is when sending the data of memory cell with self-defined High-speed Asynchronous Secial Communication control protocol, sending module is nested in packet in the communications data frame, comprise communication controler ID and data check sign indicating number, by the high-speed serial bus of supporting multiple level standard (LVDS, LVTTL, LVCEL), by the optical transceiver transceive data.
When sending by formation, queue length and data block size are defaulted as default value, can also to corresponding registers the realization dynamic-configuration be set according to concrete the application.On the one hand can reduce strict demand, reduce data copy replication task amount the response time by formation; If Tong Xin single frames data length is very big on the other hand, can transfers big data block and reduce queue length to adapt to the transmission of big Frame.In addition, this communication control method is by supporting the transmitting-receiving of multiframe packet to the configuration of offset register in the control register group; Setting by communication pattern can be supported one to one, the conversion between one-to-many, many-one plurality of communication schemes.
The data transmission method of described asynchronous communication controller, described communications data frame comprise frame head sign, frame pattern, data packet length, data, data check sign indicating number and postamble sign.
Send application layer the data pack buffer that will send is gone into transmit queue; The transmit leg piece that fetches data from transmit queue is carried out checking algorithm and at data block afterbody affix check information, embeds in the communication frame then to send; From receive formation, fetch data piece and carry out verification of recipient; Receive verification by removing the communication frame additional information and notifying application layer to handle, verification is unsanctioned then to be abandoned this packet and reports check errors.
The data transmission method of described asynchronous communication controller, described frame pattern include frame type sign, packet frame number, frame number.
The communications reception control method of described asynchronous communication controller, its main feature is, includes following steps:
(1) preparation: after step 101 system starts working, step 102 at first detects frame head 0x3C3C, if meet then carry out frame check (when frame is carried out verification, at first judge whether 0x3C3C, postamble 0xC3C3 whether of frame head, whether middle The data CRC16 verification is consistent with the check code in the Frame, violates wherein any one and promptly is judged to be invalid frame.); If do not detect frame head or frame check mistake, then enter step 102 and detect frame head again and carry out the frame format verification; If correct, enter step 103 and judge single frames or multiframe;
(2), carry out entering step 107 and judging interrupt mode after single frames receive to handle if single frames then enters step 105;
(3) if multiframe then enters step 104, carry out entering step 106 and judging the tail frame after multiframe receive to handle, if not the tail frame, then enter step 102 and rejudge frame head; If the tail frame then enters step 107 and judges interrupt mode;
(4) if interrupt mode enters step 108 and triggers interruption, after finishing, then enter step 102 and rejudge frame head; If not interrupt mode, then enter step 102 and rejudge frame head.
Ppu and this communication controler are mutual, and ppu can obtain the cell stores spatiality by the status register of access control unit on the one hand, and transmitting element and receiving element operating state receive packet data verification state; Ppu changes the different sending modes and the passage of controller by the control register of control unit is set, and starts and stop transmitting element and receiving element work; Ppu can be provided with the transmission packet by memory cell, also can read the packet that receives.If trigger register is set to interrupt mode in the control unit of communication controler, then when sending or receiving packet, communication controler can notify ppu to be for further processing by interrupt mode; Otherwise be polling mode, i.e. the related register of the continuous query communication controller of ppu control unit and then determine next step processing.
The communication sending control method of described asynchronous communication controller, its main feature is, includes following steps:
(1) preparation: after step 201 system started working, step 202 judged whether to start and sends; If not, then enter step 202 and rejudge whether start transmission; If then enter step 203 and fill communication frame;
(2) after step 203 filling communication frame is finished, enter step 204 and send, after transmission finishes, enter next round; Application layer is according to frame format configuration register (for example length register, frame type register etc.) padding data frame; Start when sending, sending module is finished the filling of communication frame according to the setting of register; If transmit control register is set to the formation sending mode, then when being sent completely, go Frame whether to also have in the query request Frame to need to send.
Send application layer the data-block cache that will send is gone into transmit queue; Transmit leg fetches data from transmit queue that piece is carried out checking algorithm and at data block afterbody affix check information, embeds in the communication frame then to send; From receive formation, fetch data piece and carry out verification of recipient; The removal communication frame additional information that the reception verification is passed through also notifies application layer to handle, and verification is unsanctioned then to be abandoned this packet and report check errors.Described queue length and data block size not only have default value, can also to corresponding registers the realization dynamic-configuration be set according to concrete the application.On the one hand can reduce strict demand, reduce data copy replication task amount the response time by formation; If Tong Xin single frames data length is very big on the other hand, can transfers big data block and reduce queue length to adapt to the transmission of big Frame.In addition, this communication control method can be supported the transmitting-receiving of multiframe packet by the setting of offset register; Can support the conversion between plurality of communication schemes such as " one to one ", " one-to-many ", " many-one " by the setting of communication pattern register.
The invention has the beneficial effects as follows: compared with the prior art, the communication controler and the control method communication corresponded manner that the invention solves present existence are single, single to the adaptation of using environment, the problem that can not dynamically change.Can support the transmitting-receiving of multiframe packet by the setting of offset register; Can support the conversion between plurality of communication schemes such as " one to one ", " one-to-many ", " many-one " by the setting of communication pattern register; Can adjust the ppu response time requirement by adjusting queue depth and data block size, also can adapt to the transmission of big Frame.
Description of drawings:
Fig. 1 is a communication controler general structure schematic diagram.
Fig. 2 is a communication controler internal structure schematic diagram.
Fig. 3 is the communications data frame schematic diagram.
Fig. 4 receives control flow chart for communication controler.
Fig. 5 sends control flow chart for communication controler.
Embodiment:
Below in conjunction with accompanying drawing, one of most preferred embodiment shown in the present is elaborated.Below illustrated be embodiments of the invention, but the invention is not restricted to the following description.
See Fig. 1, a kind of asynchronous communication controller, adopt configurable data storage cell, support the quick asynchronous communication of the multiframe packet of single frames packet, the multiple communication mode of adaptation, its main feature is the packet memory cell 2 that includes with CPU1 UNICOM, control unit 3 respectively with packet memory cell 2, transmitting element 4, receiving element 5 UNICOMs, transmitting element 4 is by communication physical channel 6 and receiving element 5 UNICOMs:
Described memory cell 2 configurable queue lengths, configuration data bag memory cell size are supported the quick asynchronous communication of single frames packet, multiframe packet;
Described transmitting element 4 sends the data of memory cell by data transmit circuit according to self-defined High-speed Asynchronous Secial Communication control protocol; Self-defined high-speed asynchronous serial comprises line idle state (idle, high level), start bit (startbit, low level), 16 bit data positions (data bits) and position of rest (stop bit, figure place is 1), this form be by start bit and position of rest realize 16 bit data synchronously;
Described receiving element 5 receives data by data receiver circuit, and data storing is being received memory cell;
The different control models that described control unit 3 is provided with according to register are controlled and are started memory cell 2, receiving element 5 and transmitting element 4.
Outer CPU 1 refers to use communication controler to carry out the communication controler ppu of data transmit-receive, between it and the communication controler memory cell 2 bus interface is arranged, and comprises data/address bus, address bus and control bus.Comprise the data transmit-receive buffer area in the memory cell 2, also comprise the set of registers of control unit 3 and the formation groups of configuration registers of self simultaneously.Outer CPU 1 and control unit 3 all can be read and write these registers, to reach the purpose that is provided with and controls.Control unit 3 is controlled the transmission of transmitting element 4 and the reception of receiving element 5 according to the register value that outer CPU 1 is provided with.What in the present embodiment, adopted communication physical channel 6 is that optical transceiving device and transmitting element 4,5 of receiving elements adopt high-speed serial communication.Cooperate " many-one ", " one-to-many " communication mode, transmitting element 4 and receiving element 5 can corresponding a plurality of optical transceiving devices, have a plurality of optical transceiving devices to be connected with communication controler in the physical channel 6 of promptly communicating by letter.
See Fig. 2, a kind of asynchronous communication controller, described packet memory cell 2 comprises transmission memory cell 2-0 and receives memory cell 2-1; Wherein receiving memory cell is to receive data and storage data by data reception module according to communication control processor; Transmitting element is by the data of data transmission blocks according to communication control processor transmission memory cell.Described packet memory cell 2 memory spaces are divided into six sections, are made up of the reception memory space of 4K byte and the transmission memory space of 4K byte for every section, and memory space address is not overlapping, every section memory space correspondence sending module and receiver module separately; Described packet memory cell 2 is connected with ppu bus interface 1-1 by parallel bus, and two-way read-write realizes the not conversion of isotopic number of data; The address halfword-aligned promptly is 2 multiple according to 16 alignment requirements.
Described asynchronous communication controller, described communication controler memory cell 2 have queuing register group 2-2, control register group 2-3, status register group 2-4, transmitting-receiving buffer area 2-0,2-1, are set up in parallel.Described transmitting-receiving buffer area 2-0,2-1 and queuing register group 2-2, control register group 2-3, status register group 2-4 memory space address are not overlapping, every section transmitting-receiving memory space correspondence sending module and receiver module separately.Queuing register group 2-2, control register group 2-3, status register group 2-4 take memory cell 2 internal storage locations, are consistent with the memory access interface of receiving and dispatching buffer area 2-0,2-1.The working method of the value decision control unit 3 of these registers group configurations.Ppu can obtain the cell stores spatiality by the status register of access control unit, and transmitting element and receiving element operating state receive packet data verification state.Ppu changes the different sending modes and the passage of controller by the control register of access control unit, starts and stop transmitting element and receiving element work.
The transmitting-receiving buffer area 2-0 of memory cell 2,2-1 corresponding memory space are divided into multistage, form by the reception memory space of 4K byte and the transmission memory space of 4K byte for every section, memory space address is not overlapping, every section memory space correspondence sending module and receiver module separately.Memory cell is connected with ppu by parallel bus, and two-way read-write realizes the not conversion of isotopic number of data.The space layout of every intersegmental part depends on the setting of queuing register group.
The transmit leg application layer is gone into transmit queue to the data-block cache that will send; Transmit leg fetches data from transmit queue that piece is carried out checking algorithm and at data block afterbody affix check information, embeds then in the communication frame and be sent to communication physical channel 6 by high speed serialization.
Receiving element receives serial data stream and decode stored to the corresponding formation of memory cell from communication physical channel 6; From receive formation, fetch data piece and carry out verification of recipient; Reception verification unanimity, to remove the communication frame additional information and also notify application layer to handle, verification is inconsistent then to be abandoned this packet and reports check errors.If the multiframe mode data packet just notifies application side to handle after then the tail frame receives in packet; Receive the frame in the new data packets when not receiving the tail frame as yet, control unit can report that data take place to be covered.
Described receiving element 5 includes a plurality of receiver modules, each receiver module correspondence reception storage unit space separately; Described transmitting element 4 includes a plurality of sending modules, each sending module correspondence transmission storage unit space separately.
A plurality of sending module correspondences of a plurality of receiver modules of described receiving element 5 and described transmitting element 4, control by described control unit 3, realize that a circuit-switched data sends by a plurality of transmitting elements are parallel, or multichannel data sends in proper order by a transmitting element, or multichannel data sends by sending module separately.
Described control unit 3 includes the reception control module 3-1-2 that is connected with described receiving element 5, and described reception control module 3-1-2 links to each other with reception length identification module 3-1-1, accepting state module 3-1-3, resolution data frame module 3-1-4 respectively.
Described control unit 3 also includes the transmission control module 3-2-2 that is connected with described transmitting element 4, and described transmission control module 3-2-2 links to each other with transmission length identification module 3-2-1, transmit status module 3-2-3, padding data frame module 3-2-4 respectively.
See Fig. 3, a kind of data transmission method of asynchronous communication controller, when sending the data of memory cell with self-defined High-speed Asynchronous Secial Communication control protocol, sending module is nested in packet in the communications data frame, comprise communication controler ID and data check sign indicating number, by the high-speed serial bus of supporting multiple level standard LVDS or LVTTL or LVCEL, by the optical transceiver transceive data.
When sending by formation, queue length and data block size are defaulted as default value, can also to corresponding registers the realization dynamic-configuration be set according to concrete the application.On the one hand can reduce strict demand, reduce data copy replication task amount the response time by formation; If Tong Xin single frames data length is very big on the other hand, can transfers big data block and reduce queue length to adapt to the transmission of big Frame.In specific design, memory cell capacity R fixes certainly, and the pass between data block size D and the queue length L is: R=D*L.In addition, this communication control method is by supporting the transmitting-receiving of multiframe packet to the configuration of offset register in the control register group; Setting by communication pattern can be supported one to one, the conversion between one-to-many, many-one plurality of communication schemes.
The data transmission method of described asynchronous communication controller, described communications data frame comprise frame head sign, frame pattern, data packet length, data, data check sign indicating number and postamble sign.
Send application layer the data pack buffer that will send is gone into transmit queue; The transmit leg piece that fetches data from transmit queue is carried out checking algorithm and at data block afterbody affix check information, embeds in the communication frame then to send; From receive formation, fetch data piece and carry out verification of recipient; Receive verification by removing the communication frame additional information and notifying application layer to handle, verification is unsanctioned then to be abandoned this packet and reports check errors.
The data transmission method of described asynchronous communication controller, described frame pattern include frame type sign, packet frame number, frame number.
See Fig. 4, a kind of communications reception control method of asynchronous communication controller includes following steps:
(1) preparation: after step 101 system starts working, step 102 at first detects frame head 0x3C3C, if meet then carry out frame check (when frame is carried out verification, at first judge whether 0x3C3C, postamble 0xC3C3 whether of frame head, whether middle The data CRC16 verification is consistent with the check code in the Frame, violates wherein any one and promptly is judged to be invalid frame.); If do not detect frame head or frame check mistake, then enter step 102 and detect frame head again and carry out the frame format verification; If correct, enter step 103 and judge single frames or multiframe;
(2), carry out entering step 107 and judging interrupt mode after single frames receive to handle if single frames then enters step 105;
(3) if multiframe then enters step 104, carry out entering step 106 and judging the tail frame after multiframe receive to handle, if not the tail frame, then enter step 102 and rejudge frame head; If the tail frame then enters step 107 and judges interrupt mode;
(4) if interrupt mode enters step 108 and triggers interruption, after finishing, then enter step 102 and rejudge frame head; If not interrupt mode, then enter step 102 and rejudge frame head.
Ppu and this communication controler are mutual, and ppu can obtain the cell stores spatiality by the status register of access control unit on the one hand, and transmitting element and receiving element operating state receive packet data verification state; Ppu changes the different sending modes and the passage of controller by the control register of control unit is set, and starts and stop transmitting element and receiving element work; Ppu can be provided with the transmission packet by memory cell, also can read the packet that receives.If trigger register is set to interrupt mode in the control unit of communication controler, then when sending or receiving packet, communication controler can notify ppu to be for further processing by interrupt mode; Otherwise be polling mode, i.e. the related register of the continuous query communication controller of ppu control unit and then determine next step processing.
See Fig. 5, a kind of communication sending control method of asynchronous communication controller includes following steps:
(1) preparation: after step 201 system started working, step 202 judged whether to start and sends; If not, then enter step 202 and rejudge whether start transmission; If then enter step 203 and fill communication frame;
(2) after step 203 filling communication frame is finished, enter step 204 and send, after transmission finishes, enter next round; The transmit leg application layer is according to frame format configuration register (for example length register, frame type register etc.) padding data frame; Start when sending, sending module is finished the filling of communication frame according to the setting of register; If transmit control register is set to the formation sending mode, then when being sent completely, go Frame whether to also have in the query request Frame to need to send.
Send application layer the data-block cache that will send is gone into transmit queue; Transmit leg fetches data from transmit queue that piece is carried out checking algorithm and at data block afterbody affix check information, embeds in the communication frame then to send; From receive formation, fetch data piece and carry out verification of recipient; The removal communication frame additional information that the reception verification is passed through also notifies application layer to handle, and verification is unsanctioned then to be abandoned this packet and report check errors.Described queue length and data block size not only have default value, can also to corresponding registers the realization dynamic-configuration be set according to concrete the application.On the one hand can reduce strict demand, reduce data copy replication task amount the response time by formation; If Tong Xin single frames data length is very big on the other hand, can transfers big data block and reduce queue length to adapt to the transmission of big Frame.In addition, this communication control method can be supported the transmitting-receiving of multiframe packet by the setting of offset register; Can support the conversion between plurality of communication schemes such as " one to one ", " one-to-many ", " many-one " by the setting of communication pattern register.

Claims (12)

1. asynchronous communication controller, adopt configurable data storage cell, support the quick asynchronous communication of the multiframe packet of single frames packet, the multiple communication mode of adaptation, it is characterized in that including packet memory cell (2) with CPU (1) UNICOM, control unit (3) respectively with packet memory cell (2), transmitting element (4), receiving element (5) UNICOM, transmitting element (4) by communication the physical channel (6) with receiving element (5) UNICOM:
Described memory cell (2) is deployment queue length, configuration data bag memory cell size, supports the quick asynchronous communication of single frames packet, multiframe packet;
Described transmitting element (4) sends the data of memory cell by data transmit circuit according to self-defined High-speed Asynchronous Secial Communication control protocol;
Described receiving element (5) receives data by data receiver circuit, and data storing is being received memory cell (2-1); The different control models that described control unit (3) is provided with according to register are controlled and are started memory cell (2), receiving element (5) and transmitting element (4).
2. asynchronous communication controller as claimed in claim 1 is characterized in that: described packet memory cell (2) comprises transmission memory cell (2-0) and receives memory cell (2-1); Described packet memory cell (2) memory space is divided into six sections, is made up of the reception memory space of 4K byte and the transmission memory space of 4K byte for every section, and memory space address is not overlapping, every section memory space correspondence sending module and receiver module separately; Described packet memory cell (2) is connected with ppu bus interface (1-1) by parallel bus, and two-way read-write realizes the not conversion of isotopic number of data; The address halfword-aligned promptly is 2 multiple according to 16 alignment requirements.
3. asynchronous communication controller as claimed in claim 1, it is characterized in that: described communication controler memory cell (2) also includes queuing register group (2-2), control register group (2-3), status register group (2-4), transmitting-receiving buffer area (2-0,2-1), described transmitting-receiving buffer area (2-0,2-1) and queuing register group (2-2), control register group (2-3), status register group (2-4) memory space address are not overlapping, every section transmitting-receiving memory space correspondence sending module and receiver module separately.
4. asynchronous communication controller as claimed in claim 1 is characterized in that: described receiving element (5) includes a plurality of receiver modules, each receiver module correspondence reception storage unit space separately; Described transmitting element (4) includes a plurality of sending modules, each sending module correspondence transmission storage unit space separately.
5. asynchronous communication controller as claimed in claim 1, it is characterized in that: a plurality of sending module correspondences of a plurality of receiver modules of described receiving element (5) and described transmitting element (4), control by described control unit (3), realize that a circuit-switched data sends by a plurality of transmitting elements are parallel, or multichannel data sends in proper order by a transmitting element, or multichannel data sends by sending module separately.
6. asynchronous communication controller as claimed in claim 1, it is characterized in that: described control unit (3) includes the reception control module (3-1-2) that is connected with described receiving element (5), and described reception control module (3-1-2) links to each other with reception length identification module (3-1-1), accepting state module (3-1-3), resolution data frame module (3-1-4) respectively.
7. asynchronous communication controller as claimed in claim 1, it is characterized in that: described control unit (3) also includes the transmission control module (3-2-2) that is connected with described transmitting element (4), and described transmission control module (3-2-2) links to each other with transmission length identification module (3-2-1), transmit status module (3-2-3), padding data frame module (3-2-4) respectively.
8. as the data transmission method of the described asynchronous communication controller of claim 1 to 7, it is characterized in that: when sending the data of memory cell with self-defined High-speed Asynchronous Secial Communication control protocol, sending module is nested in packet in the communications data frame, by the high-speed serial bus of supporting multiple level standard, by the optical transceiver transceive data.
9. the data transmission method of asynchronous communication controller as claimed in claim 8 is characterized in that: described communications data frame comprises frame head sign, frame pattern, data packet length, data, data check sign indicating number and postamble sign.
10. the data transmission method of asynchronous communication controller as claimed in claim 8, it is characterized in that: described frame pattern includes frame type sign, packet frame number, frame number.
11. the communications reception control method as the described asynchronous communication controller of claim 1 to 7 is characterized in that, includes following steps:
(1) preparation: after step 101 system started working, step 102 at first detected frame head 0x3C3C, if meet then carry out frame check; If do not detect frame head or frame check mistake, then enter step 102 and detect frame head again and carry out the frame format verification; If correct, enter step 103 and judge single frames or multiframe;
(2), carry out entering step 107 and judging interrupt mode after single frames receive to handle if single frames then enters step 105;
(3) if multiframe then enters step 104, carry out entering step 106 and judging the tail frame after multiframe receive to handle, if not the tail frame, then enter step 102 and rejudge frame head; If the tail frame then enters step 107 and judges interrupt mode;
(4) if interrupt mode enters step 108 and triggers interruption, after finishing, then enter step 102 and rejudge frame head; If not interrupt mode, then enter step 102 and rejudge frame head.
12. the communication sending control method as the described asynchronous communication controller of claim 1 to 7 is characterized in that, includes following steps:
(1) preparation: after step 201 system started working, step 202 judged whether to start and sends; If not, then enter step 202 and rejudge whether start transmission; If then enter step 203 and fill communication frame;
(2) after step 203 filling communication frame is finished, enter step 204 and send, after transmission finishes, enter next round; Application layer is according to the frame format configuration register, the padding data frame; Start when sending, sending module is finished the filling of communication frame according to the setting of register; If transmit control register is set to the formation sending mode, then when being sent completely, go Frame whether to also have in the query request Frame to need to send.
CN2009101368630A 2009-04-15 2009-04-15 An asynchronous communication controller and its control method Active CN101534259B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2009101368630A CN101534259B (en) 2009-04-15 2009-04-15 An asynchronous communication controller and its control method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2009101368630A CN101534259B (en) 2009-04-15 2009-04-15 An asynchronous communication controller and its control method

Publications (2)

Publication Number Publication Date
CN101534259A true CN101534259A (en) 2009-09-16
CN101534259B CN101534259B (en) 2013-04-10

Family

ID=41104653

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2009101368630A Active CN101534259B (en) 2009-04-15 2009-04-15 An asynchronous communication controller and its control method

Country Status (1)

Country Link
CN (1) CN101534259B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104869543A (en) * 2014-02-26 2015-08-26 普天信息技术有限公司 Information transmission method and device for eNodeB and user equipment
CN108322298A (en) * 2018-01-05 2018-07-24 浙江大华技术股份有限公司 A kind of method, equipment and system that UART lock-outs are restored
CN109085798A (en) * 2018-08-06 2018-12-25 常州轻工职业技术学院 A kind of embedded system G code asynchronous communication mechanism, agreement and programmed method
CN111200581A (en) * 2018-11-19 2020-05-26 北京华航无线电测量研究所 Data receiving and transmitting module based on LVDS bus

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1131482C (en) * 2001-06-01 2003-12-17 北京四方同创保护与控制设备有限公司 Software interface method for datal link layer in generalized asynchronous serial communication protocol.
CN1440165A (en) * 2002-02-20 2003-09-03 贵州以太科技信息产业有限责任公司 Communication method for home control system
CN201398201Y (en) * 2009-04-15 2010-02-03 兰州大成自动化工程有限公司 Asynchronous communication controller

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104869543A (en) * 2014-02-26 2015-08-26 普天信息技术有限公司 Information transmission method and device for eNodeB and user equipment
CN104869543B (en) * 2014-02-26 2018-06-19 普天信息技术有限公司 Base station and user terminal information transmission method and device
CN108322298A (en) * 2018-01-05 2018-07-24 浙江大华技术股份有限公司 A kind of method, equipment and system that UART lock-outs are restored
CN108322298B (en) * 2018-01-05 2020-12-08 浙江大华技术股份有限公司 UART out-of-synchronization recovery method, equipment and system
CN109085798A (en) * 2018-08-06 2018-12-25 常州轻工职业技术学院 A kind of embedded system G code asynchronous communication mechanism, agreement and programmed method
CN109085798B (en) * 2018-08-06 2021-01-26 常州工业职业技术学院 Embedded system G code asynchronous communication mechanism, protocol and programming method
CN111200581A (en) * 2018-11-19 2020-05-26 北京华航无线电测量研究所 Data receiving and transmitting module based on LVDS bus

Also Published As

Publication number Publication date
CN101534259B (en) 2013-04-10

Similar Documents

Publication Publication Date Title
CN109857685B (en) MPU and FPGA extended multi-serial port implementation method
CN102138297B (en) Graphics multi-media ic and method of its operation
CN101222430B (en) High-speed multi-protocol data transmission system and method
JP2006500672A (en) Bus connection system
CN102420877B (en) Multi-mode high-speed intelligent asynchronous serial port communication module and realizing method thereof
CN102647320A (en) Integrated circuit suitable for high-speed 1553 bus protocol control
CN104767697A (en) Aviation full-duplex switched Ethernet controller and control method thereof
CN103353851A (en) Method and equipment for managing tasks
CN101394349B (en) Data transmission method and system in communication of different interface devices
CN2938595Y (en) High speed series interface device for plate communication
US8335867B1 (en) Method and apparatus for reducing host processor activity during interaction with peripheral devices
CN101534259B (en) An asynchronous communication controller and its control method
CN103999509A (en) System and method for communicating using short-header frames
CN108280041A (en) A kind of communication means and device of internal integrated circuit host
CN101146090B (en) A method and device for transmitting and receiving data based on USART bus
CN101304362B (en) Retransmission buffering apparatus and data transmission method
CN100579125C (en) Method for the PCI Ethernet media to access the controller transmission data
CN107066413A (en) A kind of method and its bus system for being used to handle multiple bus apparatus data
US7610415B2 (en) System and method for processing data streams
CN103885910B (en) The method that many equipment carry out IIC communications under holotype
CN112181887A (en) Data transmission method and device
CN101655825B (en) Device for achieving LPC-USB two-way communication by using FPGA and data conversion method of LPC-US and USB-LPC
CN201398201Y (en) Asynchronous communication controller
CN101415027B (en) Communication module based on HDLC protocol, and control method for data real time forwarding and storage
CN101814011A (en) Usb host controller and the control method that is used for usb host controller

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: An asynchronous communication controller and its control method

Effective date of registration: 20161011

Granted publication date: 20130410

Pledgee: Pudong Shanghai Development Bank Limited by Share Ltd. Lanzhou branch

Pledgor: LANZHOU DACHENG TECHNOLOGY Co.,Ltd.

Registration number: 2016620000021

PLDC Enforcement, change and cancellation of contracts on pledge of patent right or utility model
PC01 Cancellation of the registration of the contract for pledge of patent right
PC01 Cancellation of the registration of the contract for pledge of patent right

Date of cancellation: 20171023

Granted publication date: 20130410

Pledgee: Pudong Shanghai Development Bank Limited by Share Ltd. Lanzhou branch

Pledgor: LANZHOU DACHENG TECHNOLOGY Co.,Ltd.

Registration number: 2016620000021

PE01 Entry into force of the registration of the contract for pledge of patent right
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: An asynchronous communication controller and its control method

Effective date of registration: 20171024

Granted publication date: 20130410

Pledgee: Pudong Shanghai Development Bank Limited by Share Ltd. Lanzhou branch

Pledgor: LANZHOU DACHENG TECHNOLOGY Co.,Ltd.

Registration number: 2017620000026

PC01 Cancellation of the registration of the contract for pledge of patent right
PC01 Cancellation of the registration of the contract for pledge of patent right

Date of cancellation: 20181108

Granted publication date: 20130410

Pledgee: Pudong Shanghai Development Bank Limited by Share Ltd. Lanzhou branch

Pledgor: LANZHOU DACHENG TECHNOLOGY Co.,Ltd.

Registration number: 2017620000026

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20240606

Address after: 730300 No. 4200, west section of Zhongchuan street, Lanzhou New District, Lanzhou City, Gansu Province

Patentee after: Lanzhou Dacheng Railway Signal Co.,Ltd.

Country or region after: China

Address before: 730000 Lanzhou high tech Industrial Development Zone, Gansu Province (No. 575, zhangsutan)

Patentee before: LANZHOU DACHENG TECHNOLOGY Co.,Ltd.

Country or region before: China