91精品综合久久久久久五月天_国产精品一区电影_中文字幕欧美日韩一区二区_亚洲一区二区三区精品动漫

DS80C410-based embedded CAN bus Dining Hall System

CAN bus (Controller Area Network Bus) is an effective support for distributed control of the serial communication network. Communication bus than the general more reliable, real-time and flexibility. CAN multi-master approach to work, the network took a node can be its own initiative at any time other nodes on the network to send information, but regardless of master and slave, and flexible communication without station node address information. CAN bus has been widely used in industrial control, residential security, environmental monitoring and many other areas.

2. System Structure

Real-time communication Dining Hall characteristics of the communication system is suitable for use CAN bus. Its short frame structure is very suitable system for anti-jamming capability and the ability to demand higher real-time communication, communication is very small single occasion; flexible networking features to fully address the large Dining Hall system, multiple dining outlets and more dispersed problems.

CAN bus Dining Hall on the system network structure shown in Figure 1. Use bus-type access method, consists mainly of three layers: server, repeaters and terminals. Which include the work server and backup server, the server, both servers work in the business at the same time, mutual backup, to ensure system reliability. Repeaters can extend the communication distance, increasing the number of terminals, transform communication rate, and can play the role of filtering and isolation. Terminal window is mainly used machine sales, but also report the loss machine, solution hang card / recharge machine.

DS80C410 embedded CAN bus based system design Dining Hall

Figure 1 Network structure diagram Dining Hall

DS80C410-based embedded CAN bus Dining Hall System

Figure 2 windows machine hardware block diagram

3. Window machine hardware design

Windows machine is directly dealing with the Canteen and the main reception equipment users. Figure 2 shows the hardware block diagram of the window plane. Dallas CAN controller with embedded microcontroller DS80C410 high-speed network as a Windows machine's microprocessor, the windows machine and the keyboard is responsible for monitoring. MMM non-contact IC (Mifare) Card read / write module. The module is under the control of the microprocessor, to complete a non-contact on the card read / write and other operations. Window machine communication tasks DS80C410 CAN controller embedded under the control of the CPU's, CAN controller via CAN bus transceiver PCA82C250 to receive the data on the bus for the CPU to read, also can be sent to the CPU data sent CAN bus. Embedded CAN controller through the DS80C410 chip P5.1 (C0RX-CAN receiver) and P5.0 (C0TX-CAN send) pin respectively transceiver RXD (receive data output) and TXD (transmit data input) pin is connected . Window machine hardware also includes a 4 × 4 keyboard (10 number keys, 6 function keys), before and after the 10-bit digital display (display exactly the same), 32KB of EEPROM (for storing consumer records), Watchdog, etc. part of the circuit.


4. Windows Software Design

4.1 Main program design

Windows machine with the Internet and offline operation types. Windows machine running the default work is divided into networking, and only in the event of network failure or other reason can not be networked to run only when the network through the switch is set to run off. Figure 3 for Windows machines running the main program flow chart. Window machine is initialized, the first treatment for the keyboard, LED display processing, and to determine whether the recovery of consumer records. Then check whether the read card, read the card, call the appropriate subroutine networked or offline, for business operations.

DS80C410-based embedded CAN bus Dining Hall System

Figure 3, the main program flow chart window machine

4.1.1 CAN Initialization

Window machine initialization, including initialization of the CAN module. When the system hardware reset, the first shield CAN interrupt, and then in the DS80C410's SFR (Special Function Register) in the C0C (CAN Control Register) of the CRST (reset) bit to 0, the CAN controller cleared the reset state, Meanwhile SWINT (software initialization) bits to be set to 1, which prohibits the CAN bus, so that it allows the program to the CAN module control registers and extended frame mask register (C0EGM0 ~ C0EGM3) to write, and set the communication wave special rate, window machine ID, window machine number, CAN state, CAN port enabled, CAN time and other parameters, initialize the CAN module. CAN interrupt the final restoration. After initialization, to clear SWINT bit, to restore the activities of CAN bus.

4.2 subroutine Design

4.2.1 Workflow

In the networking case, when the windows machine by MMM access card number, the card number will be sent to the server, the server upon receipt of card number, card number in the database to find the corresponding user and return the balance to the windows machine. Windows machine shows the user receives the balance of business operation is completed once and the window unit will users always spending sent to the server Fu Wuqi spending Hou received the corresponding database record of Geng Xin Jin Xing, Bing Jiang Yi received spending the Queren frame ( ACK) back to the windows machine. If the windows machine to read the card number (SNR) sent to the server during the frame loss, that is, the window server machine does not receive the balance of the frame, then the window machine waiting for a retransmission time frame not received the balance of the server , it will resend the previous card number. Most re-issued three times, when the re-issued three times still could not receive server response frame, the display the appropriate message. If the checkout after the windows machine to the server's user spending frame loss, that is, spending the server does not receive frames, the corresponding records can not be updated, re-issued the same way to the user spending. Figure 4 for the networked subroutine flow chart.

Figure 4 networked subroutine flowchart

Offline case, the window machine is used in accounting methods, will be off net state spending under the user's card number and all records stored in the window

I machine EEPROM, networking and other systems resume operation after the server to recover from the windows machine stored data, updates the server database. As the offline case windows machine and the server can not communicate in real time, so the program is relatively simple, no longer gives a flow chart.

DS80C410-based embedded CAN bus Dining Hall System

Figure 5 send subroutine

DS80C410-based embedded CAN bus Dining Hall System

Figure 6 Receiver subroutine

4.2.2 to send and receive frames

DS80C410 CAN module provides the message center 15, as a send or receive data memory. Frame to send and receive messages through the center 15 to achieve, you can select one or more message center to send or receive frames. This 15 message center to send or receive data packets in order of priority are arranged in the center reverse. Message Center 1-14 can be set to receive or send data, message center 15 can receive data. Message center control register (C0M1C ~ C0M15C) SFR is located in the. Center of each packet has a format register (C0MyF), 4 個 arbitration registers and 8 bytes (C0MyD0 ~ C0MyD7) data area. Arbitration register value can be set in the initialization can also be set in the sending process, and its value can be received automatically as the data changes. In addition, the message center 15 C015M0 ~ C015M3 register, you can also perform additional filtering.
When the network is to send a window state machine, the first center on the use of the initialization packet, the packet to be sent into message center, message center arbitration register value as the identifier of the frame sent. Figure 5 to use the message center to send data through a flowchart, which MSRDY (message center ready), DTUP (data update), MTRQ (CPU sends a request) and so is the message center of a bit of control register C0M1C bit.

When the window unit is receiving state, CAN controller Genju mask register and receive reports for the Center of the value of arbitration registers the ID of the received frame identifier to judge, to determine whether the received message center, and only when the received frame identifier arbitration register value equal to the time frame Caibei receiver; In addition, CAN module mask register and the media are the media arbitration register can receive data frames 0 and 1 additional two-byte checksum. Figure 6 is to use the message center 2, the procedure to receive data flow diagram. One MSRDY, DTUP, MTRQ other bits are message center 2 control register C0M2C bit.

5. Conclusion

DS80C410 is a network with Ethernet and CAN microcontrollers. Include a 10/100 Ethernet MAC, three full-duplex hardware serial port, 8-way 8-bit ports, an optional CAN2.0B ,1-Wire ® master controller and 64 I / O pins and used to store user applications and the network stack of 64K bytes of internal SRAM. Embedded CAN module supports standard (11 bit) and extended (29 bit) identifier and the common mask, the media byte filtering, DeviceNet ™, SDS and high-level CAN protocols, automatic baud rate mode and SIESTA low-power mode. DS80C410-based embedded system CAN bus Dining Hall, not only have good stability, security and reliability, and real-time response capability, network maintenance easy, user friendly interface, software, upgrades and migration are easily and cheaply.

This innovation: DS80C410 integration higher, 16MB continuous storage space, can simultaneously monitor and keyboard on the windows. Up to 75MHz system clock frequency, so that only a single cycle instruction 54ns. Embedded CAN module, so that the window machine hardware configuration is simpler to save hardware resources. CAN module message center 15 to increase communication efficiency. CAN module on the operation and expansion of the MCU external program / data memory operation is the same, software is not complicated.

Declined comment

91精品综合久久久久久五月天_国产精品一区电影_中文字幕欧美日韩一区二区_亚洲一区二区三区精品动漫
久热精品视频在线| 久久久无码中文字幕久...| 国产在线高清精品| 久久久久久久999| 亚洲 国产 日韩 综合一区| 蜜桃网站成人| 色老头一区二区三区| 日本人妻伦在线中文字幕| 91av一区二区三区| 午夜啪啪免费视频| 777久久精品一区二区三区无码| 亚洲永久一区二区三区在线| 不卡一区二区三区视频| 中文字幕日本最新乱码视频| 国产精品中文字幕在线| 国产99在线|中文| 国产一级不卡视频| 国产av国片精品| 国产精品一区免费观看| 欧美 日本 亚洲| 国产精品久久久久秋霞鲁丝| 国产精品自拍偷拍视频| 欧美一级中文字幕| 久久电影一区二区| 欧美日韩天天操| 国产精品久久久久久久久久新婚| 狠狠色伊人亚洲综合网站色| 国产精品久久视频| 国产日韩精品在线播放| 欧美日韩爱爱视频| 97人人模人人爽人人喊38tv| 亚洲a在线观看| 久久波多野结衣| 欧美影院久久久| 国产精品传媒毛片三区| 精品日韩欧美| 亚洲三级一区| 色偷偷av亚洲男人的天堂| 女同一区二区| 欧美精品999| 久久久免费观看视频| 欧美视频第一区| 欧美日韩福利电影| 亚洲a成v人在线观看| 久久综合九色综合88i| 国产视频九色蝌蚪| 欧美亚洲视频在线看网址| 亚洲不卡中文字幕无码| 亚洲欧洲三级| 久久精品国产亚洲7777| 精品日产一区2区三区黄免费 | 日韩中文字幕精品| 俄罗斯精品一区二区| 国产精品99导航| 亚洲熟妇无码一区二区三区导航| 九色综合日本| 国产麻豆电影在线观看| 日本精品一区二区三区高清 久久| 久久久精品影院| 99久久自偷自偷国产精品不卡 | 国产精品视频午夜| 好吊色欧美一区二区三区视频| 一区二区三区精品国产| 久久国产精品免费观看| 国产一级不卡视频| 视频一区二区在线| 久久成人亚洲精品| 久久久久久久久亚洲| 国产欧美日韩精品丝袜高跟鞋| 一区二区免费在线观看| 国产精品无码一区二区在线| 豆国产97在线| 欧美激情 国产精品| 午夜精品一区二区在线观看| 国产精品视频免费观看| 97精品国产97久久久久久| 黄网站欧美内射| 日本十八禁视频无遮挡| 国产精品高潮呻吟久久av野狼| 久久久欧美一区二区| 国产综合 伊人色| 热草久综合在线| 亚洲一二三区精品| 国产精品传媒毛片三区| 久久久久久久激情视频| 国产精欧美一区二区三区| 国产精品永久入口久久久| 欧美日韩一区二区三区在线观看免 | 青青在线视频免费观看| 亚洲一区尤物| 久久综合国产精品台湾中文娱乐网| 日韩一区二区三区国产| 91精品国产91久久久久久久久| 国产在线视频欧美一区二区三区| 日韩免费毛片视频| 亚洲人成无码www久久久| 欧美日韩aaaa| 国产精品国产对白熟妇| 久久久精品2019中文字幕神马| 久久久国产精华液999999| 国产视频精品网| 国产制服91一区二区三区制服| 黄色大片在线免费看| 人体内射精一区二区三区| 日本一区视频在线观看免费| 懂色av粉嫩av蜜臀av| 亚洲一区免费看| 欧美激情乱人伦一区| 色综合久久久久久中文网| 精品久久久久久一区| 精品蜜桃传媒| 国产99久久久欧美黑人| 久久久久久国产| 精品国产综合| 国产99久久精品一区二区 | 成人一级生活片| 精品一区二区国产| 麻豆一区区三区四区产品精品蜜桃 | 国产精品久久中文| 久久久国产精品亚洲一区| 日韩在线视频一区| 日韩视频一区在线| 国产成人精品在线视频| 国产精品色悠悠| 国产精品免费视频xxxx| 国产精品国产对白熟妇| 蜜臀久久99精品久久久久久宅男| 麻豆一区二区在线观看| 国产精品久久久久久一区二区| 国产精品久久国产| 国产精品欧美风情| 国产精品成人久久电影| 色综合视频一区中文字幕| 精品国产一区二区三区四区vr| 精品国产乱码久久久久久108| 久久的精品视频| 在线观看日本一区| 亚洲高清在线观看一区| 日本精品视频网站| 欧美国产视频在线观看| 国产一级片91| 91精品啪在线观看麻豆免费| 久久久亚洲欧洲日产国码aⅴ| 久久久久久美女| 国产精品久久久精品| 欧美激情xxxxx| 色999日韩自偷自拍美女| 欧美在线激情网| 国产麻豆一区二区三区在线观看| av电影一区二区三区| 久久久99爱| 国产精品久久网| 亚洲二区三区四区| 欧美日韩免费观看一区| 国产免费黄视频| 国产福利成人在线| 国产精品电影网| 午夜精品视频网站| 欧美日本韩国国产| 福利视频久久| 日韩在线视频网| 欧美xxxx14xxxxx性爽| 视频一区二区视频| 欧美最大成人综合网| 国产美女精品视频免费观看| 97碰在线观看| 国产精品久久7| 亚洲高清乱码| 国产精品日韩一区二区免费视频| 九九久久精品一区| 热99精品只有里视频精品| 久久亚洲综合网| 亚洲欧美久久久久一区二区三区| 国产成人综合av| 国产成人精品999| 国产精品久久久久久久天堂| 少妇人妻无码专区视频| 国产欧美日韩丝袜精品一区| 九色综合婷婷综合| 精品国产乱码久久久久久蜜柚| 日本精品久久久久影院| 国产美女精品视频免费观看| 日韩在线免费高清视频| 在线观看成人av| 女女同性女同一区二区三区按摩| 2019日韩中文字幕mv| 国产精品久久久999| 青青视频在线播放| 91精品国产自产91精品| 美女精品久久久| 91精品啪aⅴ在线观看国产| 欧美日韩福利在线观看| 国产麻花豆剧传媒精品mv在线 | 131美女爱做视频| 尤物av无码色av无码| 免费高清在线观看免费| 国产精品九九九| 国产日韩一区二区在线观看| 精品免费久久久久久久 | 欧美激情精品久久久久久大尺度|