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 support@ccsinfo.com

PIC 18s known to work

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



Joined: 02 Sep 2009
Posts: 6

View user's profile Send private message

PIC 18s known to work
PostPosted: Sat Sep 05, 2009 1:01 pm     Reply with quote

What PIC 18s are known to work with the CCS compiler? In particular, the UARTS. The 18F26J50 does not. Any in that series that do? (18F24J50, etc)
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sat Sep 05, 2009 2:24 pm     Reply with quote

In the future, please don't start a new thread for questions that are
related to your existing current thread. Just add it on to the existing
thread.

To answer your question:

1. Post your compiler version.
2. Does it have to be a J-series PIC ?
3. Does the PIC need to have 2 UARTS ?
tamagee



Joined: 02 Sep 2009
Posts: 6

View user's profile Send private message

PostPosted: Sun Sep 06, 2009 2:07 pm     Reply with quote

I have 3 serial devices, but only 1 will be initiating communication to the PIC, so 1 hardware uart would be acceptable. Internal RTC was nice but not necessary.


Compiler version 4.099.

Is there an 18 series pic that is commonly used?
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sun Sep 06, 2009 2:18 pm     Reply with quote

You could use the 18F4520. It could be considered the modern, general
purpose 18F-series PIC.
FvM



Joined: 27 Aug 2008
Posts: 2337
Location: Germany

View user's profile Send private message

PostPosted: Sun Sep 06, 2009 2:44 pm     Reply with quote

As far as I experienced, PCH built-in functions are working for all classical PIC18 chips. It's apparently a different story with new PIC18 J-series devices. However, you are not required to use built-in functions to access the UARTs. If you are using a Hitech or Microchip C18 compiler, you also have to manage the UART SFR access directly. You still can do this with CCS C.

P.S.: I don't want to justify the CCS way of implementing new chips, which seems to work like "ship first, check later".
dyeatman



Joined: 06 Sep 2003
Posts: 1924
Location: Norman, OK

View user's profile Send private message

PostPosted: Sun Sep 06, 2009 3:30 pm     Reply with quote

It is pretty easy to "write around" the internal functions with your own.

The RS232 register setup be accomplished manually without much work.

For your own putc1() routine all you have to do is loop while polling
the TRMTx register. When zero, load TXREGx with the passed byte/char.

A better way is to use bputc() as shown in STISR.C then modify STISR.c to
test TRMT and move the char directly into the TXREG rather than using
putc().

If the compiler generates garbage assembly for other routines they may
need to be bypassed as well.
_________________
Google and Forum Search are some of your best tools!!!!
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