tea6415c.h 959 B

123456789101112131415161718192021222324252627282930313233343536373839
  1. #ifndef __INCLUDED_TEA6415C__
  2. #define __INCLUDED_TEA6415C__
  3. /* possible i2c-addresses */
  4. #define I2C_TEA6415C_1 0x03
  5. #define I2C_TEA6415C_2 0x43
  6. /* the tea6415c's design is quite brain-dead. although there are
  7. 8 inputs and 6 outputs, these aren't enumerated in any way. because
  8. I don't want to say "connect input pin 20 to output pin 17", I define
  9. a "virtual" pin-order. */
  10. /* input pins */
  11. #define TEA6415C_OUTPUT1 18
  12. #define TEA6415C_OUTPUT2 14
  13. #define TEA6415C_OUTPUT3 16
  14. #define TEA6415C_OUTPUT4 17
  15. #define TEA6415C_OUTPUT5 13
  16. #define TEA6415C_OUTPUT6 15
  17. /* output pins */
  18. #define TEA6415C_INPUT1 5
  19. #define TEA6415C_INPUT2 8
  20. #define TEA6415C_INPUT3 3
  21. #define TEA6415C_INPUT4 20
  22. #define TEA6415C_INPUT5 6
  23. #define TEA6415C_INPUT6 10
  24. #define TEA6415C_INPUT7 1
  25. #define TEA6415C_INPUT8 11
  26. struct tea6415c_multiplex
  27. {
  28. int in; /* input-pin */
  29. int out; /* output-pin */
  30. };
  31. #define TEA6415C_SWITCH _IOW('v',1,struct tea6415c_multiplex)
  32. #endif