Trying to drive some LEDs through I2C
Hi,
I'm prototyping an appliance type box based on the EPIA-TC board
(http://www.viaembedded.com/product/epia_tc_spec.jsp?motherboardId 1). This board supposedly has a I2C bus accessible on a connector.
I also built a small board with a few LEDs driven by a TI TPIC2810 (8-BIT LED DRIVER WITH I2C INTERFACE) which I would like to hook up to the motherboard and control from a user-space process. The whole thing will run a 2.6 linux kernel.
Could somebody please give me a few pointers to get started.
I would very much appreciate it.
Thanks,
-max
--------------------------------------
Max Ott
Co-Founder/CTO, Semandex Networks, Inc.
Research Professor, WINLAB, Rutgers University
Hi Max:
Quoted 10 lines · Maximilian Ott
I'm prototyping an appliance type box based on the EPIA-TC board
(http://www.viaembedded.com/product/epia_tc_spec.jsp?motherboardId 1). This board supposedly has a I2C bus accessible on a connector.I also built a small board with a few LEDs driven by a TI TPIC2810 (8-BIT LED DRIVER WITH I2C INTERFACE) which I would like to hook up to the motherboard and control from a user-space process. The whole thing will run a 2.6 linux kernel.
Could somebody please give me a few pointers to get started.
It sounds like you already know about I2C and probably SMBus as well.
On Linux, you'll need a bus driver for your board. Some VIA chipsets are already supported... you could grab the freshly released 2.9.0 of the lm_sensors2 package and build the userspace parts (kernel 2.6 already has the most up-to-date kernel parts). Then try 'sensors-detect'.
Assuming you have a working bus driver, the easiest way to access it for prototyping would be the i2c /dev interface. This requires the module i2c-dev (if you ran 'sensors-detect' OK, you already have it).
Take a look at i2c-dev.h in the kernel headers if you want to program in in C. For prototyping, it would be much easier to re-use the Perl bindings which can be found in sensors-detect. Or if you prefer Python, lucky you: I just now published a module for that. The announcement hasn't appeared in the mail archive yet, but you will eventually see it near the bottom of this page (which is good to browse anyway):
http://archives.andrew.net.au/lm-sensors/
Regards,
Signature · 2 lines
Mark M. Hoffman [email protected]
Thanks, I'll check it out. BTW, what 2.6 kernel should I use? Should I go for the latest?
Thanks,
-max
Quoted 55 lines
-----Original Message-----
From: Mark M. Hoffman [mailto:[email protected]]
Sent: Wednesday, December 29, 2004 12:24 AM
To: Maximilian Ott
Cc: [email protected]
Subject: Re: Trying to drive some LEDs through I2CHi Max:
Quoted 2 lines · Maximilian Ott
I'm prototyping an appliance type box based on the EPIA-TC board
(http://www.viaembedded.com/product/epia_tc_spec.jsp?motherboa
rdId 1).Quoted 4 lines
This board supposedly has a I2C bus accessible on a connector.
I also built a small board with a few LEDs driven by a TI TPIC2810 (8-BIT LED DRIVER WITH I2C INTERFACE) which I would like to
hook up to the
Quoted 1 line
motherboard and control from a user-space process. The
whole thing will run
Quoted 3 lines
a 2.6 linux kernel.
Could somebody please give me a few pointers to get started.
It sounds like you already know about I2C and probably SMBus as well.
On Linux, you'll need a bus driver for your board. Some VIA chipsets are already supported... you could grab the freshly released 2.9.0 of the
lm_sensors2package and build the userspace parts (kernel 2.6 already
has the most up-to-date kernel parts). Then try 'sensors-detect'.Assuming you have a working bus driver, the easiest way to access it for prototyping would be the i2c /dev interface. This requires the module i2c-dev (if you ran 'sensors-detect' OK, you already have it).
Take a look at
i2c-dev.hin the kernel headers if you want to program in
in C. For prototyping, it would be much easier to re-use the Perl bindings which can be found in sensors-detect. Or if you prefer Python,
lucky you: I just now published a module for that. The announcement hasn't appeared in the mail archive yet, but you will eventually see it near the bottom of this page (which is good to browse anyway):http://archives.andrew.net.au/lm-sensors/
Regards,
Signature · 2 lines
Mark M. Hoffman [email protected]
Hi Max:
Quoted 2 lines · Maximilian Ott
Thanks, I'll check it out. BTW, what 2.6 kernel should I use? Should I go for the latest?
Sure, (unless you have a specific reason not too) try Linus' 2.6.10. All I2C and sensors patches go through Greg K-H, then to the -mm kernel, and from there to Linus' tree. But the pace is pretty quick; the difference between the -mm and Linus' trees (wrt I2C/sensors) always seems small.
Quoted 40 lines
Quoted 40 lines
Hi Max:
Quoted 2 lines · Maximilian Ott
I'm prototyping an appliance type box based on the EPIA-TC board
(http://www.viaembedded.com/product/epia_tc_spec.jsp?motherboa
rdId 1).Quoted 4 lines
This board supposedly has a I2C bus accessible on a connector.
I also built a small board with a few LEDs driven by a TI TPIC2810 (8-BIT LED DRIVER WITH I2C INTERFACE) which I would like to
hook up to the
Quoted 1 line
motherboard and control from a user-space process. The
whole thing will run
Quoted 3 lines
a 2.6 linux kernel.
Could somebody please give me a few pointers to get started.
It sounds like you already know about I2C and probably SMBus as well.
On Linux, you'll need a bus driver for your board. Some VIA chipsets are already supported... you could grab the freshly released 2.9.0 of the
lm_sensors2package and build the userspace parts (kernel 2.6 already
has the most up-to-date kernel parts). Then try 'sensors-detect'.Assuming you have a working bus driver, the easiest way to access it for prototyping would be the i2c /dev interface. This requires the module i2c-dev (if you ran 'sensors-detect' OK, you already have it).
Take a look at
i2c-dev.hin the kernel headers if you want to program in
in C. For prototyping, it would be much easier to re-use the Perl bindings which can be found in sensors-detect. Or if you prefer Python,
lucky you: I just now published a module for that. The announcement hasn't appeared in the mail archive yet, but you will eventually see it near the bottom of this page (which is good to browse anyway):
Signature · 2 lines
Mark M. Hoffman [email protected]