»ùÓÚstm32µÄζȿØÖÆ ÏÂÔØ±¾ÎÄ

Õª Òª

µ±Ç°¿ìËÙ³ÉÐΣ¨RP£©¼¼ÊõÁìÓò£¬»ùÓÚÅçÉä¼¼ÊõµÄ¡°ÐÂÒ»´úRP¼¼Êõ¡±ÒѾ­È¡´ú»ùÓÚ¼¤¹â¼¼ÊõµÄ¡°´«Í³µÄRP¼¼Êõ¡±³ÉΪÁËÖ÷Á÷£»¿ìËÙÖÆÔìµÄ¸ÅÄîÒѾ­Ìá³ö²¢µÃµ½Á˹㷺µØÊ¹Óá£ÈÛÈÚ³Á»ý³ÉÐÍ£¨FDM£©¾ÍÊǵ±Ç°Ê¹ÓÃ×î¹ã·ºµÄÒ»ÖÖ»ùÓÚÅçÉä¼¼ÊõµÄRP¼¼Êõ¡£

±¾ÎÄÖ÷Òª¶ÔFDMζȿØÖÆÏµÍ³½øÐÐÁËÉîÈëµÄ·ÖÎöºÍÑо¿¡£ÎÂ¶È²â¿ØÔÚʳƷÎÀÉú¡¢Ò½ÁÆ»¯¹¤µÈ¹¤ÒµÁìÓò¾ßÓй㷺µÄÓ¦Óá£Ëæ×Å´«¸ÐÆ÷¼¼Êõ¡¢Î¢µç×Ó¼¼Êõ¡¢µ¥Æ¬»ú¼¼ÊõµÄ²»¶Ï·¢Õ¹£¬ÎªÖÇÄÜÎÂ¶È²â¿ØÏµÍ³²â¿Ø¹¦ÄܵÄÍêÉÆ¡¢²â¿Ø¾«¶ÈµÄÌá¸ßºÍ¿¹¸ÉÈÅÄÜÁ¦µÄÔöÇ¿µÈÌṩÁËÌõ¼þ¡£±¾ÏµÍ³²ÉÓõÄSTM32F103C8T6µ¥Æ¬»úÊÇÒ»¸ßÐÔÄܵÄ32λ»ú£¬¾ßÓзḻµÄÓ²¼þ×ÊÔ´ºÍ·Ç³£Ç¿µÄ¿¹¸ÉÈÅÄÜÁ¦£¬ÌرðÊʺϹ¹³ÉÖÇÄÜ²â¿ØÒDZíºÍ¹¤Òµ²â¿ØÏµÍ³¡£±¾ÏµÍ³¶ÔSTM32F103C8T6µ¥Æ¬»úÓ²¼þ×ÊÔ´½øÐÐÁË¿ª·¢£¬²ÉÓÃKÐÍÈÈÃôµç×èʵÏÖ¶ÔζÈÐźŵļì²â£¬³ä·ÖÀûÓõ¥Æ¬»úµÄÓ²¼þ×ÊÔ´£¬ÒԷdz£Ð¡µÄÓ²¼þͶÈ룬ʵÏÖÁ˶ÔζÈÐźŵľ«È·¼ì²âÓë¿ØÖÆ¡£

ÎÄÖÐÊ×ÏȲûÊöÁËζȿØÖƵıØÒªÐÔ£¬Î¶ÈÊǹ¤Òµ¶ÔÏóÖеÄÖ÷Òª±»¿Ø²ÎÊýÖ®Ò»£¬ÔÚÒ±½ð¡¢»¯¹¤¡¢»úе¡¢Ê³Æ·µÈ¸÷À๤ҵÖУ¬¹ã·ºÊ¹Óø÷ÖÖ¼ÓÈȯ¡¢ºæÏä¡¢ºãÎÂÏäµÈ£¬ËüÃǾùÐè¶ÔζȽøÐпØÖÆ£¬³ÉÐÍÊÒ¼°ÅçͷζȶԳÉÐͼþ¾«¶È¶¼ÓкܴóÓ°Ï졣ȻºóÏêϸ½²½âÁËËùÉè¼ÆµÄ¿É¿Ø¹èµ÷¹¦Î¶ȿØÖÆÏµÍ³£¬ÏµÍ³²ÉÓÃSTM32F103C8T6µ¥Æ¬»ú×÷΢¿ØÖÆÆ÷¹¹½¨Êý×ÖζȿØÖÆÆ÷£¬µ÷½ÚË«Ïò¿É¿Ø¹èµÄµ¼Í¨½Ç£¬¿ØÖƵçѹ²¨ÐΣ¬ÊµÏÖ¸ºÔØÁ½¶ËÓÐЧµçѹ¿É±ä£¬ÒÔ¿ØÖƼÓÈȰôµÄ¼ÓÈȹ¦ÂÊ£¬Ê¹Î¶ȱ£³ÖÔÚÉ趨ֵ¡£ÏµÍ³Ö÷Òª°üÀ¨£ºÊý¾ÝµÄ²É¼¯£¬´¦Àí£¬Êä³ö£¬ÏµÍ³ºÍÉÏλ»úµÄͨѶ£¬ÈË»ú½»»¥²¿·Ö¡£¸Ãϵͳ³É±¾µÍ£¬¾«¶È¸ß£¬ÊµÏÖ·½±ã¡£

¸Ãϵͳ¼ÓÈÈÆ÷ζȿØÖƲÉÓÃÄ£ºýPID¿ØÖÆ¡£Ä£ºýPID¿ØÖƵIJÉÓÃÄܹ»ÔÚ¿ØÖƹý³ÌÖиù¾ÝÔ¤ÏÈÉ趨ºÃµÄ¿ØÖƹæÂɲ»Í£µØ×Ô¶¯µ÷Õû¿ØÖÆÁ¿ÒÔʹ±»¿ØÏµÍ³³¯×ÅÉ趨µÄƽºâ״̬¹ý¶É¡£

¹Ø¼ü´Ê£ºÈÛÈÚ³Á»ý³ÉÐÍ£¨FDM£©£»STM32£»Î¶ȿØÖÆ£»TCA785

I

Abstract

In the present field of Rapid Prototyping,the \technology is replacing the \RP Technology\based on laser technology as the mainstream of the Rapid Prototyping Technology.Fused Deposition Modeling(FDM) is the most popular Rapid Prototyping technology based on jetting technology.

This paper mainly does research deeply on the temperature control system of FDM system.Temperature controlling is widely to food,sanitation,medical treatment,chemistry and industry.Along with the development of sensor technology,micro-electronics technology and singlechip technolog,brainpower temperature controlling system is perfected,precision of measurement and controlling is enhanced and the ability of anti-jamming is swelled.Singlechip STM32F103C8T6 in this paper is a high-powered 32-bit chip.It has plenty of hardware resource and strong ability foranti-jamming.It is specially suitable for making brainpower measurement instrumentand industry controlling system.The hardware resource of singlechip STM32F103C8T6 is fully exploited in this paper.The tool of temperature test is thermocouple of K style.This system realizes precise measurement and controlling of temperature signal with a little hardware resource.

First,the need of temperature control is expounded.Temperature is a main controlparameter in industrial object.Various calefaction stoves,ovens and constant temperature boxes which all need control temperature are widely used in many industry such as metallurgy,chemistry,mechanism and foodstuff.Moulding room and spout temperatureawfully affect the precision of moulding pieces.Then the temperature control systemusing controllable silicon is explain in detail.This system adopts singlechip STM32F103C8T6 which acts as microcontroller.It can regulate the angle of double-direction controllable silicon and control voltage wave shape.So the virtual voltage of load can be changed and the calefaction power of calefaction stick can be controlled.Therefore the temperature canretain the enactment value.This system mainly consists of collection of data,disposal,output,communication of system and computer and communication of human and machine.This system has some advantages such as low cost,high precision andconvenience realization.

This system adopts blury PID control.The adoption of blury PID control canceaselessly autoregulates basing initialized control rule,thus the controlled system willmove to the initialized balance state.

Key words:Fused Deposition Modeling, STM32, temperature control, TCA785

II

Ŀ ¼

Õª Òª................................................................................................................................ I Abstract ................................................................................................................................ II 1 Ð÷ÂÛ ................................................................................................................................. 1 1.1 FDM¹¤ÒÕÔ­Àí¼°Ó¦Óà ................................................................................................ 1 1.2 FDM¹úÄÚÍâ»ù±¾Ñо¿¸Å¿ö ........................................................................................ 2 1.3 ¿ÎÌâÄ¿µÄ¼°ÒâÒå ......................................................................................................... 3 2 ζȿØÖÆÏµÍ³·½°¸·ÖÎö ................................................................................................. 5 2.1 ζȿØÖƵıØÒªÐÔ ..................................................................................................... 5 2.2 ζȿØÖÆÏµÍ³µÄÀíÂÛ¹¹³É ......................................................................................... 5 2.3 STM32ºÍADC ........................................................................................................... 7 2.4ζȿØÖÆÏµÍ³µÄʵÏÖ .................................................................................................. 9 3 ζȿØÖƵç·¸÷²¿·ÖµÄʵÏÖ ....................................................................................... 11 3.1ζȼì²âµç· ............................................................................................................ 11 3.2¼ÓÈȲ¿·Ö .................................................................................................................... 17 3.3¼üÅÌÏÔʾ²¿·Ö ............................................................................................................ 21 3.4Èí¼þ²¿·Ö .................................................................................................................... 21 3.5ͨѶ×ÜÏßµÄÑо¿ ........................................................................................................ 22 4 ×ܽáÓëÕ¹Íû ................................................................................................................... 24 4.1È«ÎÄ×ܽá .................................................................................................................... 24 4.2Ñо¿Õ¹Íû .................................................................................................................... 24 Ö л.............................................................................................................................. 26 ²Î¿¼ÎÄÏ×.............................................................................................................................. 27

III

1 Ð÷ÂÛ

1.1 FDM¹¤ÒÕÔ­Àí¼°Ó¦Óà 1.1.1 ÈÛË¿³Á»ý¼¼ÊõÔ­Àí

ÔçÔÚÊ®¾ÅÊÀ¼Í80Äê´úÄ©£¬ÃÀ¹úѧÕßScott Crump²©Ê¿µÚÒ»´ÎÌá³öÒ»ÖÖеÄ˼Ï룬¸Ã˼Ïë¾ÍÊÇÈÛË¿³Á»ý¼¼ÊõµÄÔ­ÐÍ¡£¸Ã˼ÏëÉáÆúÁ˼¤¹âÆ÷£¬Ìá³öÁËÀûÓÃÅçÍ·µÄ¼¼Êõ£¬Æä»ù±¾¹¤×÷Ô­ÀíÊÇ£ºÔÚ¿ØÖÆÏµÍ³×÷ÓÃÏÂÅçÍ·½øÐÐÁ½Öá°ëÔ˶¯£¬°üÀ¨X-YÁª¶¯ÒÔ¼°ZÏòÔ˶¯£¬Ñ¡È¡ÌØÊâ²ÄÁÏ¿ÉÒÔÔÚÅçÍ·Öб»¼ÓÈȽӽüÁ÷Ìå×´£»´¦ÓÚÈÛÈÚ״̬ϵIJÄÁÏÔÚÅçͷɨÃè¹ý³ÌÖб»Åç³ö£¬²¢¼±ËÙÀäÈ´ÐγÉÒ»²ã¼Ó¹¤Ã棬²ãÓë²ãÖ±½Ó²»¶ÏµÄµþ¼ÓÁ¬½ÓÔÚÒ»ÆðÖÆ×÷³ÉÒ»¸ö¿Õ¼äʵÌå¡£

ͼ1-1FDMµÄ¹¤×÷Ô­Àí

1.1.2 ÈÛË¿³Á»ý¼¼ÊõµÄÓ¦ÓÃ

FDM²ÉÓýµÎ¬ÖÆÔìÔ­Àí£¬½«Ô­±¾ºÜ¸´ÔÓµÄÈýάģÐ͸ù¾ÝÒ»¶¨µÄ²ãºñ·Ö½âΪ¶à¸ö¶þάͼÐΣ¬È»ºó²ÉÓõþ²ã°ì·¨»¹Ô­ÖÆÔì³öÈýάʵÌåÑù¼þ¡£ÓÉÓÚÕû¸ö¹ý³Ì²»ÐèҪģ¾ß£¬ËùÒÔ´óÁ¿Ó¦ÓÃÓÚ²úÆ·¿ª·¢£¬¹¦ÄܲâÊÔ£¬ÎÞÄ£ÖÆÔ죬СÅúÁ¿ÖÆÔì·½Ãæ¡£Ö÷ÒªÓ¦ÓÃÔÚÆû³µ£¬º½¿Õº½Ì죬¼ÒÓõçÆ÷£¬µç¶¯¹¤¾ß£¬ÔºÐ££¬Ä£¾ßÖÆÔì£¬Íæ¾ßÖÆÔ죬ÊÖ°æÉè¼ÆµÈÁìÓò[1-2]¡£

FDM¼¼Êõ¿ÉÔÚ²úÆ·¿ª·¢¹ý³ÌÖеÄÌṩÉè¼ÆÑéÖ¤Ó빦ÄÜÑéÖ¤£¬¼ìÑé²úÆ·¿ÉÖÆÔìÐÔ¡¢¿É×°ÅäÐÔ£¬Í¨¹ý¸÷ÖÖת»»¼¼Êõ£¬¿É½«RPÄ£ÐÍ¿ìËÙת»»³É¸÷ÖÖÄ£¾ß£¬´ó·ù¶ÈµØËõ¶Ì²úÆ·¸üл»´úµÄÖÜÆÚ¡£¿ìËÙ³ÉÐÍ»úÄÜΪ¿´Ñù¶¨»õ¡¢¹©»õѯ¼Û¡¢Êг¡Ðû´«µÈ·½Ã漰ʱÌṩ¾«È·µÄÑùÆ·£¬´ó´óÌá¸ßÆóÒµµÄÓªÏúЧÂÊ¡£ ¿ìËÙ³ÉÐͼ¼ÊõÎÊÊÀ²»µ½Ê®Ä꣬ÒÑʵÏÖÁËÏ൱´óµÄÊг¡£¬·¢Õ¹·Ç³£Ñ¸ËÙ£¬ÒѳÉΪÏÖ´ú¹¤ÒµÉè¼Æ¡¢Ä£ÐÍ¡¢Ä£¾ßºÍÁã¼þÖÆÔìÇ¿ÓÐÁ¦ÊֶΣ¬ÔÚÇṤ¡¢Æû³µÄ¦ÍгµÁìÓòµÃµ½ÁËÔ½À´Ô½¹ã·ºµÄÓ¦Ó᣼øÓÚ¿ìËÙ³ÉÐͼ¼ÊõµÄÌØÊâÐÔ£¬¿ÉÒÔÖ±½ÓÉú²úÌØÊ⸴ÔÓÁã¼þ£¬CTɨÃèÐÅÏ¢µÄʵÎﻯ£¬Òò¶ø¿ìËÙ³ÉÐͼ¼ÊõÔÚº½¿Õ¡¢º½Ìì¼°Ò½ÁÆÁìÓòÕýÖð²½ÌåÏÖ³ö¾Þ´óµÄÓÅÔ½ÐÔ¡£ 1.1.3 ÈÛË¿³Á»ý¼¼ÊõµÄ·¢Õ¹Ç÷ÊÆ

1