Pic12f1840 ADC problem

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 4.
To post in this forum you must have a registered copy of Flowcode 4 or higher. To sign up for this forum topic please use the "Online Resources" link in the Flowcode Help Menu.

Moderator: Benj

Post Reply
Soren
Posts: 12
Joined: Tue Jun 09, 2009 4:17 pm
Has thanked: 1 time
Been thanked: 3 times
Contact:

Pic12f1840 ADC problem

Post by Soren »

Hi

Pic12f1840 give me a random value when i use the read as int, when i use the read as byte everything work perfect.
I have a LM35 temperatur sensor connectet to adc2 an i want to use the read as int because it´s give me a better resolution.
When i look in the C code i can see it´s the adc_23 there is been used,is this the right one?
someone having the same problem?

Soren

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: Pic12f1840 ADC problem

Post by Benj »

Hello Soren,

Flowcode v4 or v5?

Soren
Posts: 12
Joined: Tue Jun 09, 2009 4:17 pm
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: Pic12f1840 ADC problem

Post by Soren »

Hello Ben

sorry i forgot that. V4.5

Soren

Kenrix2
Flowcode v5 User
Posts: 211
Joined: Tue Feb 19, 2013 9:51 pm
Has thanked: 72 times
Been thanked: 177 times
Contact:

Re: Pic12f1840 ADC problem

Post by Kenrix2 »

This post might answer your question:

http://www.matrixmultimedia.com/mmforum ... ror#p27866

Note that there is also an update for PIC_ADC_26.c

Soren
Posts: 12
Joined: Tue Jun 09, 2009 4:17 pm
Has thanked: 1 time
Been thanked: 3 times
Contact:

Re: Pic12f1840 ADC problem

Post by Soren »

Thanks Kenrix2.

This works great.

Soren.

Post Reply