I2C write - value too big


Closed Thread
Results 1 to 20 of 20

Hybrid View

  1. #1
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,653


    Did you find this post helpful? Yes | No

    Default

    Hi, Ruicj

    Can you tell us how you get those values :

    ( 122.5 is NOT a PbP value ...)

    - Input value range ( volts ? ) / ref voltage
    - Math used ( in PbP )
    - Values you want to to output

    It's "not so clear" ...

    Alain

    PS : ANSEL doesn't match the ADCIN PORT !!! Check it !!!
    Last edited by Acetronics2; - 6th April 2008 at 12:51.
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  2. #2


    Did you find this post helpful? Yes | No

    Default

    Hello Acetronics,

    these values i get from:

    Code:
    FOR ADDR=st TO ed
         
       		adcin temp,va
     
    tempe=(va*/5000 )>>2
    
            toggle red
            toggle green
            pause   418    ' calibration to get  1200  readings  ( 2 per second ) in 10 minutes   - 
            debug " recorded value: ", dec tempe," position  ", dec ADDR, 13,10
    the debug line gave these values after the adcin conversion.
    I'm colecting the voltage directly from the variable resistor which is simulating the voltage from a LM35 ( 0,2v - 1,5V )
    I'm not using any reference value, just VDD and VSS( i know...it's lame...but i'm not looking for the best resolution for now )

    .

  3. #3
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,653


    Did you find this post helpful? Yes | No

    Default

    seen it ???

    : ANSEL doesn't match the ADCIN PORT !!! Check it !!!

    ANSEL select A1 and A2
    ADCIN select A0 ...

    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  4. #4


    Did you find this post helpful? Yes | No

    Default

    Acetronics,

    You are right !!! Thank you ( and the rest of the guys for the help )

    This was set when i was playing with several sensors

    But how can it be ?? If i have the ANSEL with a different channel, how can i get values on channel A0 ??

    This is why i didnt see it

  5. #5
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,653


    Did you find this post helpful? Yes | No

    Wink

    Capacitive coupling ... pins are side-by-side !!!
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

Similar Threads

  1. I2C Master/Slave 16F88/16F767 working code
    By DanPBP in forum Code Examples
    Replies: 2
    Last Post: - 23rd October 2012, 22:31
  2. HARDWARE I2C SAMPLE CODE question
    By Michael Wakileh in forum Code Examples
    Replies: 2
    Last Post: - 16th June 2009, 21:07
  3. Replies: 5
    Last Post: - 29th May 2008, 18:03
  4. PIC16F877 I2C programme
    By cooqo in forum mel PIC BASIC
    Replies: 3
    Last Post: - 21st April 2008, 10:02
  5. I2C Master Slave issues.
    By cpayne in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 29th March 2008, 19:33

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts