How to turn off PIC16F818 microcontroller on dev MCP23X17

Go To Last Post
9 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

What I am trying to achieve is to send data through SPI from ATmega328P to dev kit MCP23X17 to turn LEDs on. Notice, the ATmega328P is mounted on an external board. 

 

The problem is that when I compile the code in ATmega328P, nothing happens. I have later found out that the reason is because the development board MCP23X17 runs the code default from microcontroller PIC16F818 that is mounted on dev kit.

 

I think the solution is to disable the microcontroller PIC16F818 on the development board in order to run the code from ATmega328P. I do not know how to do this, any ideas? 

 

Document regarding MCP23X17. 

http://ww1.microchip.com/downloa...

 

In the picture, there is 4 components. 

- AVRISPMKii which is an ISP debugger, I use this to send the code from PC to the microcontroller. 

- Arduino UNO, I use this as 5V power supply. 

- Board, consist of ATmega328P and LED. 

- Development board MCP23X17. 

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Ground the mclr (vpp) line on the pic to hold it in reset mode, should keep it out of the way.  if all else fails, use hot air to remove the chip!

 

 

 

FF = PI > S.E.T

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

A couple more things you should also look at.....

 

You have NO decoupling capacitors on the breadboard....you should put a 10uf and .1uf near the Vcc pin to ground.

 

You do not have any capacitors from your crystal legs to ground.  20pf should be ok to cover most crystal frequencies.

 

I am guessing that the connection from the AVR to the MCP 23x17 is I2C based on the two resistors on the breadboard.  Those are 120 ohm resistors which are WAY to low.  They should be 2.2k - 10K

 

 

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I manage to disable PIC16F818. But still there are few more adjustments left to use external board. 

 

In this device document, in page 13. Point 5 and 6 states that there are two headers that can allow off-board connections, which is what I want to achieve. However, it does not describe which type of headers? 

Link to device document: http://ww1.microchip.com/downloa...

 

 

5. Headers - There are two headers which are connected to the MCP23X17 pins to allow off-board connections.

6. Jumpers - The jumpers are used to isolate the MCP23X17 pins so they can be connected to an off-board circuit. The jumpers are not populated, however, they are shorted by a trace on the bottom of the PCB.

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You should direct these questions in the proper Microchip forums I would think.

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You will need to cut the traces to enable the jumpers, use an Xacto knife, then to restore normal operation (ie. on board) use some plug on jumpers across the pins where you cut the traces.  Good luck, have fun!

Jim (not everyone on this forum is named jim, it just seems that way)

 

 

 

 

FF = PI > S.E.T

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi User,

 

I am facing similar problem.

Could you please explain how did you disable  PIC16F818 .

Tried to ground RST(VPP) pin on micro controller. Still doesnt work.

 

Thanks a lot.

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

See number #5 above.

John Samperi

Ampertronics Pty. Ltd.

https://www.ampertronics.com.au

* Electronic Design * Custom Products * Contract Assembly

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Thanks!

I removed PIC micro controller and it works fine. I could control SDA and clock pin as per my requirement.