CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

PIC18F65J11 & Port A

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
mayur.k.vadukul



Joined: 07 Jul 2022
Posts: 40

View user's profile Send private message

PIC18F65J11 & Port A
PostPosted: Fri Jun 23, 2023 8:56 am     Reply with quote

I have the working code for PIC18F66K22 and I decided to change the microprocessor to PIC18F65J11 which is pin compatible.

I have changed the device setting and compiled the code which was fine but for whatever reason the Port A pins which are defined as Inputs are not being detected in the code. I have checked hardware, i.e. place scope on pin to see whether it goes High/Low but the software does not respond.

I went into the debug mode and the code comes to Pin detection but does not detect High.

Has anyone encountered the same issue? There was compiler bug associated with baud rate with PIC18F65J11, and not sure whether this is the similar thing.
_________________
MVadukul
Ttelmah



Joined: 11 Mar 2010
Posts: 19504

View user's profile Send private message

PostPosted: Fri Jun 23, 2023 9:19 am     Reply with quote

How is your ADC setup?.
This is one of the chips where on the input pins where an analog selection
overrides a digital selection. Some of the newer chips have a separate
ANSEL register for this (this one doesn't), but still if a pin is selected
as analog, it won't function for digital input. By default the ADC and
comparator wake up selecting a lot of the pins.....
mayur.k.vadukul



Joined: 07 Jul 2022
Posts: 40

View user's profile Send private message

PIC18F65J11 & Port A
PostPosted: Fri Jun 23, 2023 9:43 am     Reply with quote

@Ttelmah,

Thank you. It was A2D settings.

I would put this as inconsistency of the CCS. For the same code, it makes A2D off for 18F66K22, but not for 18F65J11. As practice, it is good to define always, but when I create project through Wizard and not select A2D, I expect it to create the necessary automatically.

Never mind. Thanks again and to make my weekend without worries. Very Happy
_________________
MVadukul
Ttelmah



Joined: 11 Mar 2010
Posts: 19504

View user's profile Send private message

PostPosted: Fri Jun 23, 2023 11:45 am     Reply with quote

Glad I got it.
Very Happy

Historically CCS turned most things off by default. They then tended to
get complaints when things were turned off rather than defaulting as
shown in the data sheets, so they have slowly tended to do less of this...
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group