ADC0832Êý×Öµçѹ±í ÏÂÔر¾ÎÄ

Íⲿ³ÌÐò´æ´¢Æ÷È¡Ö¸Áî(»òÊý¾Ý)ʱ,ÿ¸ö»úÆ÷ÖÜÆÚÁ½´ÎPSENÓÐЧ,¼´Êä³öÁ½¸öÂö³å¡£µ±·ÃÎÊÍⲿÊý¾Ý´æ´¢Æ÷ʱ,ûÓÐÁ½´ÎÓÐЧµÄPSENÐźš£

EA/VPP£ºÍⲿ·ÃÎÊÔÊÐí¡£ÓûʹCPU½ö·ÃÎÊÍⲿ³ÌÐò´æ´¢Æ÷£¨µØַΪ0000H-FFFFH£©£¬EA¶Ë±ØÐë±£³ÖµÍµçƽ(½ÓµØ)¡£ÐèҪעÒâµÄÊÇ:Èç¹û¼ÓÃÜλLB1±»±à³Ì,¸´Î»Ê±ÄÚ²¿»áËø´æEA¶Ë״̬¡£

ÈçEA¶Ë±£³Ö¸ßµçƽ(½ÓVCC¶Ë)£¬CPUÔòÖ´ÐÐÄÚ²¿³ÌÐò´æ´¢Æ÷ÖеÄÖ¸Áî¡£ Flash´æ´¢Æ÷±à³ÌÆڼ䣬¸ÃÒý½ÅÓÃÓÚÊ©¼Ó+12V±à³Ìµçѹ£¨VPP£©¡£ XTAL1£º·´ÏòÕñµ´·Å´óÆ÷µÄÊäÈë¼°ÄÚ²¿Ê±ÖÓ¹¤×÷µç·µÄÊäÈë¶Ë¡£ XTAL2£º·´ÏòÕñµ´·Å´óÆ÷Æ÷µÄÊä³ö¶Ë¡£ £¨3£©¾§ÌåÕñµ´Æ÷ÌØÐÔ£º

AT89S51ÖÐÓÐÒ»¸öÓÃÓÚ¹¹³ÉÄÚ²¿Õñµ´Æ÷µÄ¸ßÔöÒæ·´Ïà·Å´óÆ÷£¬Òý½ÅXTAL1ºÍXTAL2·Ö±ðΪ¸Ã·´Ïò·Å´óÆ÷µÄÊäÈë¶ËºÍÊä³ö¶Ë¡£Õâ¸ö·´Ïò·Å´óÆ÷Óë×÷Ϊ·´À¡Ôª¼þµÄƬÍâʯӢ¾§Ìå»òÌÕ´ÉгÕñÆ÷Ò»Æð¹¹³É×Ô¼¤Õñµ´Æ÷¡£

Íâ½ÓʯӢ¾§Ìå(»òÌÕ´ÉгÕñÆ÷)¼°µçÈÝC1¡¢C2½ÓÔÚ·Å´óÆ÷µÄ·´À¡»Ø·Öй¹³É²¢ÁªÕñµ´µç·¡£¶ÔÍâ½ÓµçÈÝC1¡¢C2ËäȻûÓÐÊ®·ÖÑϸñµÄÒªÇó,µ«µçÈÝÈÝÁ¿µÄ´óС»áÇá΢ӰÏìÕñµ´ÆµÂʵĸߵ͡¢Õñµ´Æ÷¹¤×÷µÄÎȶ¨ÐÔ¡¢ÆðÕñµÄÄÑÒ׳̶ȼ°Î¶ÈÎȶ¨ÐÔ¡£Èç¹ûʹÓÃʯӢ¾§Ìå,µçÈÝÓ¦¸ÃʹÓÃ30pF?10pF¡£

»¹¿ÉÒÔʹÓÃÍⲿʱÖÓ¡£ÕâÖÖÇé¿öÏÂ,ÍⲿʱÖÓÂö³å½ÓXTAL1¶Ë,¼´ÄÚ²¿Ê±ÖÓ·¢ÉúÆ÷µÄÊäÈë¶Ë, XTAL2Ó¦Ðü¿Õ¡£

ÓÉÓÚÍⲿʱÖÓÐźÅÊÇͨ¹ýÒ»¸ö2·ÖƵ´¥·¢Æ÷ºó×÷ΪÄÚ²¿Ê±ÖÓÐźŵÄ,ËùÒÔÍⲿʱÖÓÐźŵÄÕ¼¿Õ±ÈûÓÐÌØÊâÒªÇó,µ«×îС¸ßµçƽ³ÖÐøʱ¼äºÍ×î´óµÍµçƽ³ÖÐøʱ¼äÓ¦·ûºÏ²úÆ·¼¼ÊõÌõ¼þµÄÒªÇó¡£

2.2 AT89S52µÄÖ÷ÒªÐÔÄܲÎÊý£º

£¨1£©ÓëMCS-51²úÆ·Ö¸ÁîϵͳÍêÈ«¼æÈÝ¡£ £¨2£©8K×Ö½ÚÔÚϵͳ¿É±à³Ì£¨ISP£©FlashÉÁËÙ´æ´¢Æ÷¡£ £¨3£©1000´Î²ÁдÖÜÆÚ¡£ £¨4£©4.0¡ª5.5VµÄ¹¤×÷µçѹ·¶Î§¡£ £¨5£©È«¾²Ì¬¹¤×÷ģʽ£º0Hz--33Hz¡£ £¨6£©Èý¼¶³ÌÐò¼ÓÃÜ¡£ £¨7£©128x8×Ö½ÚµÄÄÚ²¿RAM¡£ £¨8£©32¸öË«Ïò¿É±à³ÌI/O¿ÚÏß¡£ £¨9£©2¸ö16λ¿É±à³Ì¶¨Ê±/¼ÆÊýÆ÷¡£ £¨10£©6¸öÖжÏÔ´¡£ £¨11£©È«Ë«¹¤UART´®ÐÐͨµÀ¡£ £¨12£©µÍ¹¦ºÄ¿ÕÏк͵ôµçģʽ¡£ - 9 -

£¨13£©ÖжϿɴӿÕÏÐģʽ»½ÐÑϵͳ¡£ £¨14£©¿´ÃŹ·£¨WDT£©¼°Ë«Êý¾ÝÖ¸Õë¡£ £¨15£©µôµç±êʶºÍ¿ìËÙ±à³ÌÌØÐÔ¡£ £¨16£©Áé»îµÄÔÚϵͳ±à³Ì£¨ISP-×Ö½Ú»òҳдģʽ£©¡£ 2.3 AT89S52µÄй¦ÄÜ£º

AT89S52¼æÈݱê×¼MCS-51Ö¸Áîϵͳ¼°AT89C52Òý½Å½á¹¹£¬ËüÏà¶ÔÓÚAT89C52Ôö¼ÓµÄй¦ÄÜ°üÀ¨£º £¨1£©ISPÔÚÏß±à³Ì¹¦ÄÜ£¬Õâ¸ö¹¦ÄܵÄÓÅÊÆÔÚÓÚ¸Äдµ¥Æ¬»ú´æ´¢Æ÷ÄڵijÌÐò²»ÐèÒª°ÑоƬ´Ó¹¤×÷»·¾³ÖаþÀë¡£ÊÇÒ»¸öÇ¿´óÒ×ÓõŦÄÜ¡£ £¨2£© ×î¸ß¹¤×÷ƵÂÊΪ33MHz£¬AT89C52µÄ¼«ÏÞ¹¤×÷ƵÂÊÊÇ24M£¬ËùÒÔAT89S52¾ßÓиü¸ß¹¤×÷ƵÂÊ£¬´Ó¶ø¾ßÓÐÁ˸ü¿ìµÄ¼ÆËãËٶȡ£ £¨3£©¾ßÓÐË«¹¤UART´®ÐÐͨµÀ¡£ £¨4£©ÄÚ²¿¼¯³É¿´ÃŹ·¼ÆʱÆ÷£¬²»ÔÙÐèÒªÏñAT89C52ÄÇÑùÍâ½Ó¿´ÃŹ·¼ÆʱÆ÷µ¥Ôªµç·¡£ £¨5£©Ë«Êý¾ÝָʾÆ÷¡£ £¨6£©µçÔ´¹Ø±Õ±êʶ¡£ £¨7£©È«ÐµļÓÃÜËã·¨£¬ÕâʹµÃ¶ÔÓÚAT89S52µÄ½âÃܱäΪ²»¿ÉÄÜ£¬³ÌÐòµÄ±£ÃÜÐÔ´ó´ó¼ÓÇ¿£¬ÕâÑù¾Í¿ÉÒÔÓÐЧµÄ±£»¤ÖªÊ¶²úȨ²»±»ÇÖ·¸¡£ £¨8£© ¼æÈÝÐÔ·½Ã棺ÏòÏÂÍêÈ«¼æÈÝ51È«²¿×ÖϵÁвúÆ·¡£±ÈÈç8051¡¢AT89C51µÈÔçÆÚMCS-51²úÆ· 3 ·½°¸Éè¼Æ

ʹÓÃADC0832Ä£Äâ/Êý×Öת»»Æ÷оƬÉè¼ÆÊý×Öµçѹ±íµç·¡£¸ÃÉè¼Æ·½°¸ÒÔµ¥Æ¬»úAT89S52ΪÖ÷¿ØоƬ£¬ÒÔADC0832Ä£Äâ/Êý×Öת»»Æ÷оƬΪºËÐÄת»»Ä£Äâ/Êý×ÖÁ¿µÄоƬ£¬×é³ÉÊý×Öµçѹ±íµç·¡£¸Ãµç·ÄÜ׼ȷµØ²â³öËù±»²âÓÐЧµçѹֵ¡¢¸½¼ÓËÄλÏÔʾ¹¦ÄÜ£¬¿É¾«È·µ½ÓÐЧµçѹֵΪ0.01V¡£

4 Éè¼ÆÁ÷³Ìͼ 4.1×ÜÌåÉè¼ÆÁ÷³Ìͼ

- 10 -

¿ªÊ¼¶Ë¿Ú³õʼ»¯µ÷ÓÃADת»»×Ó³ÌÐòµ÷ÓÃÏÔʾ×Ó³ÌÐò 4.2

ADת»»¹ØϵÉè¼ÆÁ÷³Ìͼ

- 11 -

¿ªÊ¼Æô¶¯Ò»´Îת»»NA/Dת»»½áÊøEOC=1£¿Y·µ»Ø

5 ÈíÓ²¼þÉè¼Æ 5.1 Ó²¼þµç·Éè

¸ÃÉè¼ÆµÄÓ²¼þµç·ÓÉÖ÷¿Ø²¿·Ö(µ¥Æ¬»úAT89S51)¡¢²É¼¯Ä£ÄâÁ¿²¿·Ö£¨A/Dת»»Ò»Â·ADC0832£©¡¢ÏÔʾ²¿·Ö£¨ËÄλ°Ë¶ÎÊýÂë¹Ü£©¡¢µçÔ´²¿·ÖÓɵçÄÔUSB£¨5V£©¹©µç4¸ö²¿·Ö×é³É¡£¸÷²¿·ÖÖ®¼äÏ໥Э×÷£¬¹¹³ÉÒ»¸öͳһµÄÓлúÕûÌ壬ʵÏÖÊý×Öµçѹ±íµÄ¹¦ÄÜ¡£¸÷²¿·ÖµÄÓ²¼þµç·Éè¼ÆÈçÏ¡£Éè¼Æ×ܵç·ͼ¼û¸½Â¼Ò»¡£

5.2 µ¥Æ¬»úAT89S52ÍâΧµç·Éè¼Æ

4.2.1¸´Î»µç·Éè¼Æ

MCS-51µÄ¸´Î»ÊäÈëÒý½ÅRSTΪMCS-51ÌṩÁ˳õʼ»¯µÄÊֶΣ¬¿ÉÒÔʹ³ÌÐò´ÓÖ¸¶¨´¦¿ªÊ¼Ö´ÐУ¬ÔÚMCS-51µÄʱÖӵ緹¤×÷ºó£¬Ö»ÒªRSTÒý½ÅÉϳöÏÖ³¬¹ýÁ½¸ö»úÆ÷ÖÜÆÚÒÔÉϵĸߵçƽʱ£¬¼´¿É²úÉú¸´Î»µÄ²Ù×÷£¬Ö»ÒªRST±£³Ö¸ßµçƽ£¬ÔòMCS-51Ñ­»·¸´Î»£¬Ö»Óе¥RETÓɸߵçƽ±ä³ÉµÍµçƽÒÔºó£¬MCS-51²Å´Ó0000H

- 12 -