Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

Post Reply
Author
Message
barrickm
Posts: 11
Joined: 26 Sep 2020 21:34

Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#1 Post by barrickm » 29 Dec 2020 18:43

Is it possible to use CODEGRIP on an MCU that is external to the EasyPIC v8 development board?

I'm trying to program a PIC18F27K42 located on a Ready for PIC board.
The Ready for PIC board has a 10 pin header for programming, assuming you cut traces and solder the supplied 10 pin header to the board.
The EasyPIC v8 has an RJ45 connector for external programming, which is apparently intended for using a Microchip programmer on an onboard PIC, assuming CODEGRIP is turned off using the DBG SEL switch.

But couldn't this RJ45 connector also be used to allow the onboard CODEGRIP module to program an external PIC, with the proper wiring arrangement?

VCC_MCU / GND / MCLR / MCU_PGC / MCU_PGD are all available on the RJ45, and if left in internal mode using the DBG SEL switch, that should be all that's required to program an external MCU, assuming no MCU is present in one of the onboard MCU sockets.

Am I missing something, even though clearly this was not an anticipated connectivity option for the EasyPIC v8 dev. bd.?

hexreader
Posts: 1785
Joined: 27 Jun 2010 12:07
Location: England

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#2 Post by hexreader » 30 Dec 2020 04:29

I just tried this out using a PIC18F27K42 and succeeded.
PIC10F320 and PIC16F15325 also tried and working.

Make sure that the DBG SEL switch is selected to "ON-BOARD"

Getting the correct connections from the RJ12 socket may be tricky - the adapters that I tried first are simply not wired to do this job.

Successful set-up was Microchip AC162069 (RJ12 to bare pins) and a solderless breadboard.

Have not managed to program a PIC32, as the only programming options are via EJTAG 2 or 4 wire

Not sure how to wire ready-for-PIC board, but think there is probably a way. Cannot prove the concept, as I used up all my ready-for-PIC's within projects.
Start every day with a smile...... (get it over with) :)

barrickm
Posts: 11
Joined: 26 Sep 2020 21:34

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#3 Post by barrickm » 30 Dec 2020 20:11

hexreader wrote:
30 Dec 2020 04:29
I just tried this out using a PIC18F27K42 and succeeded.
PIC10F320 and PIC16F15325 also tried and working.

Make sure that the DBG SEL switch is selected to "ON-BOARD"

Getting the correct connections from the RJ12 socket may be tricky - the adapters that I tried first are simply not wired to do this job.

Successful set-up was Microchip AC162069 (RJ12 to bare pins) and a solderless breadboard.

Have not managed to program a PIC32, as the only programming options are via EJTAG 2 or 4 wire

Not sure how to wire ready-for-PIC board, but think there is probably a way. Cannot prove the concept, as I used up all my ready-for-PIC's within projects.
----
Right - very helpful. The main thing I was interested in knowing, is that no damage will be done to the EasyPIC V8 board, in so doing.
The Read-For-PIC connections are very straight-forward. Appreciate the very thorough and prompt check-out / advice.
I'll be trying it myself very soon.

hexreader
Posts: 1785
Joined: 27 Jun 2010 12:07
Location: England

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#4 Post by hexreader » 10 Jan 2021 18:13

Have been using PICkit4 with EP8 much more lately (because it supports Q series PICs), and have discovered a problem with EasyPIC v8 RJ12 connector.

EasyPIC v8 has pin 1 connected to Vpp, which is different to EasyPIC 7, going by schematics.

The older EasyPIC 7 board seems to be wired correctly as a target board, since it is compatible with Microchip boards

In summary: EasyPIC v8 RJ12 is wired incorrectly. Take care...


EDIT: After more research, I am more confused than ever as to what is "correct". The only thing that I am confident of, is that EasyPIC v8 is wired differently to EasyPIC 7

EDIT 2: My investigations - if I understand correctly, show the following:

1) EasyPIC 8 schematic is correct - pin 1 Vpp. The RJ12 socket fitted is "tab at the top", but the board seems to have been designed for "tab down" socket - hence it ends up with a reversed connection.

2) EasyPIC 7 schematic is incorrect in showing pin 6 as Vpp, but also has "tab at the top" - two wrongs make a right, so end result is correct wiring.
Start every day with a smile...... (get it over with) :)

Robin_Masters
Posts: 25
Joined: 09 Jan 2020 11:38

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#5 Post by Robin_Masters » 22 Sep 2022 18:27

If my understanding is correct : You use ON-BOARD CODEGRIP to program a PIC placed on an external board ?


In fact, my problem is to program an on-board PIC with an external programmer unit (mikroProg in this case)... CODEGRIP do not recognize the PIC18FxxK83 family !

Do anybody have a solution for this problem ?

hexreader
Posts: 1785
Joined: 27 Jun 2010 12:07
Location: England

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#6 Post by hexreader » 22 Sep 2022 18:53

Yes,

Apologies - I had forgotten that this thread is the reverse of what you want, thought the connection information is still relevant.

I have succeeded with programming in both directions, usually using PICkit 4 as the external programmer in order to program "Q" series PICs on easyPIC 8

My easyPIC 8 is now broken, so I cannot prove that mikroPROG will program a PIC18F26K83 on EP 8 board.

I see no reason that it should not work.

EDIT - update - I can program PIC18F26K83 OK using mikroPROG programmer, adapter cable, and RJ12 connector on easyPIC v7a

My guess is that you have wired incorrectly.
Start every day with a smile...... (get it over with) :)

Robin_Masters
Posts: 25
Joined: 09 Jan 2020 11:38

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#7 Post by Robin_Masters » 23 Sep 2022 12:52

Thanks very much for your reply !

According to the board schematic, RJ12 to mikroProg adaptor :
RJ12/1 (to the top of the board) >> MCLR
RJ12/2 >> VCC
RJ12/3 >> GND
RJ12/4 >> PGD
RJ12/5 >> PGC
RJ12/6 (to the bottom of the board) >> not connected

on board switchs :
DBG/SEL on EXTERNAL
MCLR on RESET
PGC/PGD on PROG/DEBUG
Attachments
RJ12 adaptor.jpg
RJ12 adaptor.jpg (516.26 KiB) Viewed 1300 times

hexreader
Posts: 1785
Joined: 27 Jun 2010 12:07
Location: England

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#8 Post by hexreader » 23 Sep 2022 13:02

See other thread.

Board schematic is correct for "tab at the bottom" RJ12 socket

Sadly ME used a "tab at the top" RJ12 socket, which flips pins 1 to 6

EasyPIC8 connector is reversed to how it should be

..... unless maybe ME have solved the problem on later boards? ( I doubt it )
Start every day with a smile...... (get it over with) :)

Robin_Masters
Posts: 25
Joined: 09 Jan 2020 11:38

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#9 Post by Robin_Masters » 26 Sep 2022 09:04

Hello,


I just tested the electric continuity of the RJ12 socket on my EasyPIC v8, and I found this :

RJ12/1 (top of the board) >> can't find any connection to MCLR, in disagreement with schematic, whether the DBG SEL switch is in a position or in the other.
RJ12/2 >> VCC via D11, according to schematic
RJ12/3 >> GND, according to schematic
RJ12/4 >> PGD, according to schematic
RJ12/5 >> PGC, according to schematic
RJ12/6 (bottom of the board) >> can't find any connection, according to schematic


Is somebody able to explain how to remake the connection between RJ12/1 and MCLR ?


Sincerely,

Pascal

hexreader
Posts: 1785
Joined: 27 Jun 2010 12:07
Location: England

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#10 Post by hexreader » 26 Sep 2022 11:10

I suspect that you are confusing pin 1 on the 28 pin socket marked MCLR with the signal name "MCLR"

These are two different signals on the schematic.

Pin 1 of 28 pin socket has signal name "RE3/MCLR"

MCLR pin of RJ12 socket only goes to U3 pins 2,5 and 12

Take care if probing around U3, as it has a +14 Volt supply. Shorting 14V to other parts of the board could cause death to the board
Start every day with a smile...... (get it over with) :)

User avatar
filip
mikroElektronika team
Posts: 11874
Joined: 25 Jan 2008 09:56

Re: Can CODEGRIP on an easyPIC v8 be used on an external MCU through the RJ45 connector?

#11 Post by filip » 27 Sep 2022 15:37

Hi,

I believe I have answered you here regarding the same issue :
viewtopic.php?f=233&t=79503

Regards,
Filip.

Post Reply

Return to “CODEGRIP programmer and debugger”