public inbox for linux-i2c@vger.kernel.org
 help / color / mirror / Atom feed
From: Andreas Seidler <tetzlav-bXdiauyh1GQ7K2kJdssfr+TW4wlIGRCZ@public.gmane.org>
To: i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org
Subject: Re: MAX1236 with smbus (CS5536 ACB0)
Date: Thu, 16 Oct 2008 20:12:48 +0200	[thread overview]
Message-ID: <gd8070$f4e$1@ger.gmane.org> (raw)
In-Reply-To: <20081015101736.34e1c11e-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>

Jean Delvare schrieb:
> On Wed, 15 Oct 2008 03:01:56 +0200, Andreas Seidler wrote:
>> I can access this ADC wired to a i2c-ibm_iic (build-in IBM PPC_P405)
> 
> That's not the question. Maybe the chip was wired properly on that
> system and not on the CS5563 system.
> 
> You can also try i2cdetect -r and see if it makes a difference.

I'm afraid not.


>>> If it is wired properly, then another possibility is that the MAX1236
>>> is doing clock stretching beyond what the CS5536 supports...
>> and this is my second problem: i cant read the A/D-converted values from
>> userspace (eg. with i2cget) without spezial code or kernel module?
> 
> I'm not sure if i2cget can work with this device. The transactions used
> by the MAX1236 are raw reads and writes which aren't too
> SMBus-friendly, but it you don't care too much about performance,
> i2cget may still work depending on how you read the datasheet. I
> suggest that you give it a try on the IBM PPC system where you know the
> chip is properly wired.
> 
> i2cget 0 0x34 0x81 w
> 
> should give you the raw value of the 1st ADC channel. You'll have to
> byte-swap it because SMBus specifies that words go on the wire LSB
> first.

good to know about the byte-swap with smbus!


btw:I played around with this ADC on my i2c-ibm_iic:

root@OpenWrt:/# i2cget -y 0 0x34 0x21 w

i get this values of channel 0:

OV:	0x00f0 (11110000)
1,6V:	0xaef5 (1010111011110101)
3,2V:	0x5efb (101110111111011)

but how to get the converted 12 bit value?



Regards
Andreas


_______________________________________________
i2c mailing list
i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org
http://lists.lm-sensors.org/mailman/listinfo/i2c

  parent reply	other threads:[~2008-10-16 18:12 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-13  1:20 MAX1236 with smbus (CS5536 ACB0) Andreas Seidler
     [not found] ` <48F2A270.8060307-bXdiauyh1GQ7K2kJdssfr+TW4wlIGRCZ@public.gmane.org>
2008-10-13  7:25   ` Jean Delvare
     [not found]     ` <20081013092548.3d58a320-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2008-10-13 11:11       ` Jonathan Cameron
     [not found]         ` <48F32CE9.8000109-KWPb1pKIrIJaa/9Udqfwiw@public.gmane.org>
2008-10-15  1:13           ` Andreas Seidler
2008-10-15 11:10             ` Jonathan Cameron
     [not found]               ` <48F5CF88.2030500-KWPb1pKIrIJaa/9Udqfwiw@public.gmane.org>
2008-10-15 13:06                 ` Andreas Seidler
2008-10-15 15:14                   ` Jonathan Cameron
     [not found]                     ` <48F608E7.9040309-KWPb1pKIrIJaa/9Udqfwiw@public.gmane.org>
2008-10-15 17:23                       ` Andreas Seidler
2008-10-15  1:01       ` Andreas Seidler
2008-10-15  8:17         ` Jean Delvare
     [not found]           ` <20081015101736.34e1c11e-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2008-10-16 18:12             ` Andreas Seidler [this message]
2008-10-16 18:29               ` Marco Costa
2008-10-16 21:25             ` Jordan Crouse
2008-10-28 20:27         ` Michelle Konzack

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='gd8070$f4e$1@ger.gmane.org' \
    --to=tetzlav-bxdiauyh1gq7k2kjdssfr+tw4wligrcz@public.gmane.org \
    --cc=i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox