عملت برنامج فيه كى باد وشاشه وربطهم بال 877A والمفروض البرنامج انى هكتب حاجه وبعد كده هدوس ع زرار معين يقوم يطلعلى حاجه تانيه ... البرنامج كان شغال ع البروتس تمام جدا لكن اول ما عملت الدايره وحرقت البرنامج .. البيك كان بيرستر بمعنى انى مبلحقش اكتب والاقيه يخلينى اعيد من الاول وهكذا ... لما دخلت ع موقع الشركه لقيت فيه سؤالين عن نفس الموضوع ومتجاوبين من ميكرو شيب نفسها الصراحه انا فيه جزء فاهمه وجزء مش فاهمه من اجابتهم ... يعنى فى الاخر مش فاهم ايه الغلط وايه المطلوب منى اعدله بالظبط وادى السؤالين واجابتهم
Q. My PIC sometimes resets by itself.
A. Bad power? Brownouts? Put a decoupling cap as close to the power supply as possible, so when it switches it doesn’t brown itself out. 0.1uF for <8Mhz, 0.01uF for >8Mhz.
Q. After I programmed my PIC, it kept restarting itself every couple of seconds.
A. Have you got the watchdog timer bit set? The watchdog is a good way to ensure that the microprocessor does not freeze forever from a crash. When the chip is programmed, the watchdog timer bit is enabled. It cannot be turned off in software, in case a rogue program overwrites it. If the timer is not reset regularly with a CLRWDT() instruction, it will reset the micro. This will happen within 18ms to 2 seconds, depending on the prescaler selected, and on the temperature.
It is interesting to note that it is possible to make a PIC into an accurate temperature sensor using the time of the watchdog timeout to sense the temperature.
The advantage of using a watchdog timer is that the micro is protected from crashing forever due to a bad power supply or a rogue program
اسف للاطاله وارجو الافاده وشكرا.