Thanx for suggestion.
I m using 1232 deive.
I tried the same code. Only in my case A3 is connected.
In my case input voltage is 1.5 V and I m getting value
as 983 it should come around 615.
amol
From: "Fend, Matthias" <mf...@harris.com>
Reply-To: mspgcc-users@lists.sourceforge.net
To: "'mspgcc-users@lists.sourceforge.net'"
<mspgcc-users@lists.sourceforge.net>
Subject: AW: AW: [Mspgcc-users] About ADC10
Date: Wed, 2 Jun 2004 05:34:53 -0400
can you try this (works fine for e.g.1132):
ADC10CTL0 = SREF_1 + ADC10SHT_1 + REF2_5V + REFON + ADC10ON;
ADC10CTL1 = INCH_1; // A1
ADC10AE = 0x02; // P2.1 ADC option select
ADC10CTL0 |= ENC + ADC10SC; // Sampling and conversion start
while (!(ADC10CTL1 & ADC10BUSY)); // ADC10BUSY?
adc = ADC10MEM;
which device do you use ?
matthias
-----Ursprüngliche Nachricht-----
Von: mspgcc-users-ad...@lists.sourceforge.net
[mailto:mspgcc-users-ad...@lists.sourceforge.net]im Auftrag von amol
shrotri
Gesendet: Mittwoch, 02. Juni 2004 10:36
An: mspgcc-users@lists.sourceforge.net
Betreff: RE: AW: [Mspgcc-users] About ADC10
Hi,
I tried with
ADC10AE = 0x08; with INCH_3
But getting the same result.
amol
>From: "Fend, Matthias" <mf...@harris.com>
>Reply-To: mspgcc-users@lists.sourceforge.net
>To: "'mspgcc-users@lists.sourceforge.net'"
><mspgcc-users@lists.sourceforge.net>
>Subject: AW: [Mspgcc-users] About ADC10
>Date: Wed, 2 Jun 2004 04:07:46 -0400
>
>hello,
>
>ADC10AE = 0x01; with INCH_1 could be a reason...
>
>try
> ADC10AE = 0x02; with INCH_1
>or
> ADC10AE = 0x01; with INCH_0
>
>best regards,
> matthias
>
>-----Ursprüngliche Nachricht-----
>Von: mspgcc-users-ad...@lists.sourceforge.net
>[mailto:mspgcc-users-ad...@lists.sourceforge.net]im Auftrag von amol
>shrotri
>Gesendet: Mittwoch, 02. Juni 2004 09:47
>An: mspgcc-users@lists.sourceforge.net
>Betreff: [Mspgcc-users] About ADC10
>
>
>Hi,
>
>
> I m trying to use ADC10. I could able to get
>ADC interrupt but the vale in ADC10MEM in ISR is
>coming wrong. I m configuring ADC as
>
>void StartADC10()
>{
>
> ADC10CTL0 = ADC10IE + ADC10ON + REFON + REF2_5V + MSC + ADC10SHT_3 +
>SREF_1;
>
> ADC10CTL0 &= ~ENC;
>
> ADC10CTL1 = CONSEQ_1 + ADC10DIV_0 + SHS_0 + INCH_1;
>
> ADC10AE = 0x01;
>
> // start the conversion
> ADC10CTL0 |= ENC;
> ADC10CTL0 |= ADC10SC;
>}
>
>So accordning to formula.
> If Input channel 1 is having 1.59V it should give me value in
>ADC10MEM as around
>650. But I m getting 980. I m not understanding the cause for the same.
If
>anybody can
>help me in this problem it will be great help.
>
>Thanx in advance.
>
>
>Regards,
>amol
>
>_________________________________________________________________
>Easiest Money Transfer to India. Send Money To 6000 Indian Towns.
>http://go.msnserver.com/IN/48198.asp Easiest Way To Send Money Home!
>
>
>
>-------------------------------------------------------
>This SF.Net email is sponsored by the new InstallShield X.
>From Windows to Linux, servers to mobile, InstallShield X is the one
>installation-authoring solution that does it all. Learn more and
>evaluate today! http://www.installshield.com/Dev2Dev/0504
>_______________________________________________
>Mspgcc-users mailing list
>Mspgcc-users@lists.sourceforge.net
>https://lists.sourceforge.net/lists/listinfo/mspgcc-users
>
>
>-------------------------------------------------------
>This SF.Net email is sponsored by the new InstallShield X.
>From Windows to Linux, servers to mobile, InstallShield X is the one
>installation-authoring solution that does it all. Learn more and
>evaluate today! http://www.installshield.com/Dev2Dev/0504
>_______________________________________________
>Mspgcc-users mailing list
>Mspgcc-users@lists.sourceforge.net
>https://lists.sourceforge.net/lists/listinfo/mspgcc-users
_________________________________________________________________
Full savings account benefits at no minimum balance!
http://go.msnserver.com/IN/49352.asp Apply now and get FREE watch!
-------------------------------------------------------
This SF.Net email is sponsored by the new InstallShield X.
From Windows to Linux, servers to mobile, InstallShield X is the one
installation-authoring solution that does it all. Learn more and
evaluate today! http://www.installshield.com/Dev2Dev/0504
_______________________________________________
Mspgcc-users mailing list
Mspgcc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mspgcc-users
-------------------------------------------------------
This SF.Net email is sponsored by the new InstallShield X.
From Windows to Linux, servers to mobile, InstallShield X is the one
installation-authoring solution that does it all. Learn more and
evaluate today! http://www.installshield.com/Dev2Dev/0504
_______________________________________________
Mspgcc-users mailing list
Mspgcc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mspgcc-users
_________________________________________________________________
Get a Citibank Home Loan now. http://go.msnserver.com/IN/49351.asp Build
with Citibank Home Loans.