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

How to find if chip has PPS for pin remapping

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
nurquhar



Joined: 05 Aug 2006
Posts: 149
Location: Redditch, UK

View user's profile Send private message Visit poster's website

How to find if chip has PPS for pin remapping
PostPosted: Mon Feb 11, 2013 4:55 am     Reply with quote

I have been working on modifying the CCS ex_usb_bootloader to work from eihter the USB port or one of the HW UART's. I also have it working at the top of memory so no need care about modifiying the app when using bootloader.

Its all working nicely with the 18F27J53 but I wanted a generic way of re-mapping the UART port pins if the device supports it. I was hoping to find a GETENV("PPS") option which would tell me if the chip support this. My V4.133 manual does't mention it.

Is there another way to do it, short of writing one realy long #IF-THEN-ELSE using the device number ? Perhaps its supported in later versions of PCH Question
Ttelmah



Joined: 11 Mar 2010
Posts: 19515

View user's profile Send private message

PostPosted: Mon Feb 11, 2013 5:27 am     Reply with quote

If the chip has a PPSCON register, then it supports at least some re-mappable pins.

getenv("SFR_VALID:PPSCON")

Best Wishes
nurquhar



Joined: 05 Aug 2006
Posts: 149
Location: Redditch, UK

View user's profile Send private message Visit poster's website

PostPosted: Mon Feb 11, 2013 7:33 am     Reply with quote

Dear Ttelmah

Thanks, that works. Very Happy

Interestingly SFR_VALID is not in my CCS help file. However I did find it in the PDF manual I just download from CCS. Exclamation
Ttelmah



Joined: 11 Mar 2010
Posts: 19515

View user's profile Send private message

PostPosted: Mon Feb 11, 2013 7:49 am     Reply with quote

Yes, this has caught me in the past. The pdf is the 'latest' manual. The one with the compiler is a little older. Also remember that there are often updates to both in the 'readme' with the compiler.

Best Wishes
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