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

Search found 21 matches
CCS Forum Index
Author Message
  Topic: Temperature Indicator, Math, Hair Loss
harlequin2

Replies: 24
Views: 33649

PostForum: General CCS C Discussion   Posted: Tue Mar 12, 2013 4:48 pm   Subject: Temperature Indicator, Math, Hair Loss
The FVR is quoted as -8 to +6 % in the data sheet - not marvellous.
I measured the temp indicator adc output as 776 at 25 deg C and the calculated value is 855, so the error is 79. Using the uncorrec ...
  Topic: Temperature Indicator, Math, Hair Loss
harlequin2

Replies: 24
Views: 33649

PostForum: General CCS C Discussion   Posted: Sat Mar 09, 2013 2:16 am   Subject: Temperature Indicator, Math, Hair Loss
Yes, I think that is really part of the problem: there are just so many variants out there it becomes quite tedious searching for just the "right one".
But hey, variety is the spice of life ...
  Topic: Temperature Indicator, Math, Hair Loss
harlequin2

Replies: 24
Views: 33649

PostForum: General CCS C Discussion   Posted: Fri Mar 08, 2013 9:16 pm   Subject: Temperature Indicator, Math, Hair Loss
Actually, I'm not "over-engineering" anything. You may note, if you read back a bit, that I am simply adapting a spare pcb with a micro and a lcd on it to a different purpose. It is/was a ma ...
  Topic: Temperature Indicator, Math, Hair Loss
harlequin2

Replies: 24
Views: 33649

PostForum: General CCS C Discussion   Posted: Fri Mar 08, 2013 2:26 pm   Subject: Temperature Indicator, Math, Hair Loss
Thank you for that detailed examination. I see from the data for the 16F1826 that the first transition does indeed occur at 1/2 LSB above Vref(-) and the final one at 1.5 LSB below Vref(+).
Taking yo ...
  Topic: Temperature Indicator, Math, Hair Loss
harlequin2

Replies: 24
Views: 33649

PostForum: General CCS C Discussion   Posted: Fri Mar 08, 2013 1:02 am   Subject: Temperature Indicator, Math, Hair Loss
Should be an edit, but here goes:
I use ref-lo as Vss and ref-hi as Vdd and the input as FVR, then ADC = ( FVR*1023)/Vdd
Is that it?
So the Vdd = ADC/FVR*1023
For a 4.5 V Vdd and a 2.048 FVR, ADC ...
  Topic: Temperature Indicator, Math, Hair Loss
harlequin2

Replies: 24
Views: 33649

PostForum: General CCS C Discussion   Posted: Thu Mar 07, 2013 9:58 pm   Subject: Temperature Indicator, Math, Hair Loss
I'm very pleased to have read through this forum, it makes me feel a little less stupid! I, also, have been reading through AN1333 and wondering why I/they bothered.
I happen to have a small board w ...
  Topic: ADC setup
harlequin2

Replies: 8
Views: 10370

PostForum: General CCS C Discussion   Posted: Thu Mar 07, 2013 7:25 pm   Subject: ADC setup
Thank you, you got me thinking, especially about the message "Undefined label" or whatever it was. It seemed to me that the compiler was not using the correct header file, so I searched for ...
  Topic: ADC setup
harlequin2

Replies: 8
Views: 10370

PostForum: General CCS C Discussion   Posted: Thu Mar 07, 2013 12:49 am   Subject: ADC setup
V 4.104
  Topic: ADC setup
harlequin2

Replies: 8
Views: 10370

PostForum: General CCS C Discussion   Posted: Thu Mar 07, 2013 12:39 am   Subject: ADC setup
Sorry, my typo, htm.
That other stuff is not in my 16F1826.h file.
Perhaps I'll try that? But why do the definitions in the .h file that I have not work?
Here is the relevant section from my .h fil ...
  Topic: ADC setup
harlequin2

Replies: 8
Views: 10370

PostForum: General CCS C Discussion   Posted: Wed Mar 06, 2013 11:43 pm   Subject: ADC setup
Yes, that is correct. I note that the PCM.htl file shows it simply as A0, but the .h file shows sA0 so that is what I used.
It compiles OK if I leave out the VSS_FVR.
  Topic: ADC setup
harlequin2

Replies: 8
Views: 10370

PostForum: General CCS C Discussion   Posted: Wed Mar 06, 2013 11:06 pm   Subject: ADC setup
I am using a 16F1826 with V4.104 PCM and it won't allow me to set up the ADC reference with setup_adc_ports(sA0|VSS_FVR);
The compiler returns the errors "Undefined Identifier VSS_FVR" but ...
  Topic: RS232 interrupt not working (Solved)
harlequin2

Replies: 17
Views: 26987

PostForum: General CCS C Discussion   Posted: Sun Jun 12, 2011 7:21 pm   Subject: RS232 interrupt not working (Solved)
The lesson to be taken from this is if the there is a valid interface to the Uart hardware pins and the RDA interrupt code is set up correctly and the RDA doesn't fire then a software UART may have be ...
  Topic: RS232 interrupt not working (Solved)
harlequin2

Replies: 17
Views: 26987

PostForum: General CCS C Discussion   Posted: Sun Jun 12, 2011 6:06 pm   Subject: RS232 interrupt not working (Solved)

I did not put the 'xmit= PIN_A4' and 'rcv=PIN_A5' statements in the code in my post !
You should NOT do it. You should use 'UART1' ONLY ! (After this I give up).

You are quite right, I didn't ...
  Topic: RS232 interrupt not working (Solved)
harlequin2

Replies: 17
Views: 26987

PostForum: General CCS C Discussion   Posted: Sun Jun 12, 2011 4:45 pm   Subject: RS232 interrupt not working (Solved)
Post your latest test program.

Here it is: Note that it sends one char when I power it up, as it should since buffer is true (usually 0xFF)

#include <12lf1822.h>
#device ADC=10
#fuses IN ...
  Topic: RS232 interrupt not working (Solved)
harlequin2

Replies: 17
Views: 26987

PostForum: General CCS C Discussion   Posted: Sun Jun 12, 2011 4:19 pm   Subject: RS232 interrupt not working (Solved)
That's right, because you're not setting the APFCON register bits to
select the alternate UART pins. The compiler won't do that for you
automatically just because you specified the alternate pins ...
 
Page 1 of 2 Goto page 1, 2  Next
All times are GMT - 6 Hours
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group