LPC mini kit analog comparator howto ?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPC mini kit analog comparator howto ?

853 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by gertk on Sun Jul 28 03:55:07 MST 2013
I am trying to get the analog comparator to work on the mini kit/demo board but so far it just refuses to react on my analog input signal (I2 pin 5)

The positive input is connected to the ladder, the negative to analog in on pin 5 (which is connected to a potmeter connected between ground and Vdd). I am simply testing the output bit in the control register but it reads always as zero.
Labels (1)
0 Kudos
9 Replies

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by gertk on Wed Aug 14 02:30:44 MST 2013
Nice to see it is officially acknowledged.

So we can expect some correct working samples 'real soon now'  ?



0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Wouter on Wed Aug 14 01:57:29 MST 2013
Update:
DIP 8 devices with rev. 2A are affected by this issue; indeed the analog comparator in not working on these parts.
The next device revision 4C (DIP 8 package) will have a functional comparator.

We are currently working on updating the documentation, an official errata will be published soon.
0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Wouter on Mon Aug 12 09:37:04 MST 2013
Hi Gert, CaoHua,

Sorry for my late response, this thread somehow had fallen out of my scope...
I did a quick porting of the LPC812 analog comparator example from LPCOpen to the 8-pin LPC810, and indeed experienced problems with the comparator.
I need some more time to look into this, but will get back to you ASAP.

Regards,
Wouter
0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by gertk on Mon Aug 12 09:33:34 MST 2013
Thanks for confirming the problem.
Trying to find a replacement LPC810 DIP8 ...
0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by caohua0902@126.com on Fri Aug 09 06:28:41 MST 2013
Hi,Wouter:

I done the same test as Gertk's. The comparator also can't work on my own board whose MCU is LPC810M021.

Then I downloaded the sample code bundle for http://www.lpcware.com/node/11538/256, it worked on LPC812M101FDH20, but didn't on LPC810M021.

I checked the registers on LPC810M021 and LPC812M101 when it's running via Keil MDK. The content in LPC812M101's registers had changed, but that in LPC810M101 hadn't never changed. Reading it back gives always 0 ,just as Gertk's description.

Please checked it ,thanks.

Regards,

Yours, CaoHua.
0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by gertk on Fri Aug 09 01:41:44 MST 2013
Just heard that the early LPC810 had a fault in the comparator part... I think I have been bitten by that. :-(
Wasted hours..
0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by gertk on Tue Aug 06 13:54:09 MST 2013
Seems my analog comparator registers are non existent...

If I check PDRUNCFG it gives me 0x6d70 which should mean the comparator part is powered.

Writing (anything) in the CTRL register and reading it back gives always 0, same for the LAD register, whatever is written. Even set up my own direct pointers to the registers with the same result, always zero.

Is my LPC defective ?
0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by gertk on Tue Aug 06 03:51:50 MST 2013
Still can not get it to work..
Both the LPC_CMP->CTRL and LPC_CMP->LAD register are stuck at zero (even after writing the appropriate bits for selecting the VP and VM inputs. Or are they write only ?

Also I think I found a typo in the manual (both PDF and online):

ACMP_I2 I PIO0_0/ACMP_I2/CLKIN Comparator input 2. Disable the CLKIN function in the PINSASSIGN1BIT0 register. PINENABLE0 SWM PINENABLE0 addressOffset = 0x1C0

Should this not be PIO0_1/ACMP_I2/CLKIN ??

http://docs.lpcware.com/lpc800um/RegisterMaps/acmp/r-Pindescription.html
0 Kudos

729 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by Wouter on Mon Jul 29 01:43:12 MST 2013
Hi Gert,

Our sample code bundle has a comparator example:
http://www.lpcware.com/node/11538/256

You can use this as a reference.

Regards,
Wouter
0 Kudos