Share

Small Device C Compiler

Tracker: Patches

5 adc functions not workinng for pic18fXX5X devices - ID: 1776197
Last Update: Comment added ( jenriquez )

I wrote a patch to make adc working on pic18fXX5X devices. I submited the
patch to the mailinglist earlier but didnt get a respond.
IMHO the ADC_CHN_XX and ADC_CFG_XX_0R shoudl go into the device header file
so the adc.h is cleaner.


kein0r ( kein0r ) - 2007-08-17 12:27

5

Closed

Accepted

Nobody/Anonymous

None

None

Public


Comments ( 4 )

Date: 2008-12-15 23:46
Sender: jenriquez

SDCC version available in Ubuntu repositories does not include the patch, I
was having problems until I updated through subversion to latest release
(r5286).
I've just tested AD conversion with a pic18f2550, it seems to work pretty
well:
http://www.youtube.com/watch?v=ryuTv0r2FkE


Date: 2008-05-01 20:39
Sender: tecodev


After nearly 9 months, I finally applied a variant of the attached patch
in SDCC r5150.

I added support for more devices and consolidated the device checks into a
single new #define for maintainability.
I am sorry that it took me so long to make ADC work for most devices, but
hopefully I found an acceptable solution at last.

Comments, success stories and error reports concerning the new ADC
approach are welcome.

Regards,
Raphael



Date: 2007-10-30 20:43
Sender: kein0r


I updated the patch to include more devices. With this patch the sdcc adc
library is extended to the following devices. pic18f2455, pic18f2550,
pic18f4455, pic18f4550, pic18f2525, pic18f2620, pic18f4525, pic18f4620
File Added: adc.diff


Date: 2007-08-17 12:28
Sender: kein0r


diff is against revision 4907
File Added: adc.h.diff


Attached File ( 1 )

Filename Description Download
adc.diff Download

Changes ( 8 )

Field Old Value Date By
close_date - 2008-05-01 20:39 tecodev
status_id Open 2008-05-01 20:39 tecodev
resolution_id None 2008-05-01 20:39 tecodev
File Deleted 241665: 2007-10-30 20:43 kein0r
File Deleted 241666: 2007-10-30 20:43 kein0r
File Added 252055: adc.diff 2007-10-30 20:43 kein0r
File Added 241666: adc.h.diff 2007-08-17 12:28 kein0r
File Added 241665: adc.diff 2007-08-17 12:27 kein0r