Microchip PIC: Difference between revisions

From Bashlinux
Jump to navigationJump to search
Content deleted Content added
Manpaz (talk | contribs)
No edit summary
Manpaz (talk | contribs)
No edit summary
Line 1: Line 1:
== Cautions ==
== Cautions ==
=== Config ===
'''Config'''<br>
# NEVER disable the PIC's /MCLR (Reset) pin function
* NEVER disable the PIC's <code>/MCLR</code> (Reset) pin function
# NEVER program a PIC 'in circuit' with ANY other connections to the target board
* NEVER program a PIC "in circuit" with ANY other connections to the target board


'''Circuit Design'''<br>
The config options must have always `MCLRE_ON` and a 10K pull-up resistor to Vdd.
* ALWAYS set <code>MCLRE_ON</code> in the config options and have <code>MCLR</code> pin with a 10K pull-up resistor to Vdd.


=== Initialization ===
'''Initialization'''<br>
# ALWAYS set the input pins and clear the output pins, excepting UART TX/RX.
* ALWAYS set the input pins and clear the output pins, excepting UART TX/RX.
i.e. SDO should have TRISX bit cleared, SDI should have TRISX bit set.
i.e. SDO should have TRISX bit cleared, SDI should have TRISX bit set.

Revision as of 22:34, 8 June 2015

Cautions

Config

  • NEVER disable the PIC's /MCLR (Reset) pin function
  • NEVER program a PIC "in circuit" with ANY other connections to the target board

Circuit Design

  • ALWAYS set MCLRE_ON in the config options and have MCLR pin with a 10K pull-up resistor to Vdd.

Initialization

  • ALWAYS set the input pins and clear the output pins, excepting UART TX/RX.
i.e. SDO should have TRISX bit cleared, SDI should have TRISX bit set.