In this article I'll describe howto modify the Device – CDC – Serial Emulator from microchip for the PIC18F47J53 to support the PIC18F27J53.

The changes are very simple, regard only the leds present into the PIM board.

First of all what you need : 

  1. A board with the pic18f27j53 as mine. You can build one or…   I have some of this and if you want one please contact me
  2. MPLAB v 8.83             from Microchip 
  3. Microchip Solutions v2011-12-05 from Microchip

Install the Microchip Solutions v2011-12-05 in a proper directory, I assume that it is installed in :

C:\Microchip Solutions v2011-12-05


Do a backup of the directory 

C:\Microchip Solutions v2011-12-05\USB\Device – CDC – Serial Emulator


Move to the directory

C:\Microchip Solutions v2011-12-05\USB\Device – CDC – Serial Emulator\Firmware


rename the file 

USB Device – CDC – Serial Emulator -  C18 – PIC18F47J53 PIM.mcp

with 

USB Device – CDC – Serial Emulator -  C18 – PIC18F27J53 PIM.mcp


rename the file 

rm18f47j53_g

with 

rm18f27j53_g

Execute the folowing steps :


  • Double click on the project file  USB Device – CDC – Serial Emulator –  C18 – PIC18F27J53 PIM.mcp
  • remove the file  rm18f47j53_g.lkr from the project window and add the rm18f27j53_g.lkr file
  • Open the file rm18f27j53_g.lkr
  • replace any occurence of 18F47J53 with 18F27J53
  • Save the file and close it

Open the file HardwareProfile.h  move to the line 110 and replace 

 #elif defined(__18F47J53) 

with 

#elif defined(__18F27J53) 

Save the file and close it


Open the file main.c

move to line 1066, and add a new line and insert 

#endif

line 1057, add new line and insert 

#if 0

Comment the lines 1051, 1050, 1044, 1040, 1036,1032, and from 1017 up to 1025, 657, 

Save the file and close it


Select the device pic18f27j53  (Menu  Configure–>Select Device …)

set the proper path for the library include file and ….

build the project.. 


The file "USB Device – CDC – Serial Emulator –  C18 – PIC18F27J53 PIM.hex" will be build.

Burn the pic and enjoy yourself

Insert the key into the PC and install the driver when asked

(The inf file is in the directory   C:\Microchip Solutions v2011-12-05\USB\Device – CDC – Serial Emulator\inf)

Open a terminal an connect to the proper Virtual serial port.

that's all

We have some board already soldered at low cost on ebay goto http://www.ebay.it/sch/giovannitto/m.html?_nkw=&_armrs=1&_from=&_ipg=&_trksid=p3686

Copyright 2012 Stefano D'Andrea & Armando Volpe