Guest User

My overrides.cfg /Kermit

a guest
Nov 5th, 2019
136
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.30 KB | None | 0 0
  1.  
  2. # http://www.lightshowpi.org/
  3. #
  4. # SAMPLE CONFIGURATION FILE
  5. # -------------------------
  6. # This is a SAMPLE configuration file for the program. This file follows conventions
  7. # of a python config file. The variables defined below control variable aspects
  8. # of the program. To use this sample file, copy it to the config directory and rename
  9. # the file "overrides.cfg". This sample file only contains settings related to making
  10. # specific functions or hardware work that are outlined in the description below. You can
  11. # make changes to other settings by modifing the "config/defaults.cfg" file, or by adding
  12. # them directly to this file. NOTE: Full descriptions for each setting below can be found in
  13. # the "config/defaults.cfg" file.
  14. #
  15. # Author: Chris Usey ([email protected])
  16. #
  17. # ----------------------------------------------
  18. # -- Model B AND mcp23017 Sample Config File --
  19. # ----------------------------------------------
  20. # This sample config file can be used as a starting point for configuring your
  21. # RaspberryPi Model B with a mcp23017 Port Expander to add 16 additional GPIO to your project.
  22. # This sample configures the RaspberryPi to use 8 GPIO of the RaspberryPi Model B and
  23. # an additional 16 GPIO of the mcp23017 Port expander for a total of 24 channels.
  24.  
  25. # mcp23017 Chip Addressing
  26. # The following details how you might wire up a mcp23017 port expander to the raspberry Pi
  27. #
  28. # RpiPin mcp23017 PINOUT RpiPin
  29. # _______________|_________________________________|_______________
  30. # | ___ ___ |
  31. # | | () | |
  32. # | GPB0 <-> | 1 28 | <-> GPA7 |
  33. # | GPB1 <-> | 2 27 | <-> GPA6 |
  34. # | GPB2 <-> | 3 26 | <-> GPA5 |
  35. # | GPB3 <-> | 4 25 | <-> GPA4 |
  36. # | GPB4 <-> | 5 24 | <-> GPA3 |
  37. # | GPB5 <-> | 6 23 | <-> GPA2 |
  38. # | GPB6 <-> | 7 23 | <-> GPA1 |
  39. # | GPB7 <-> | 8 22 | <-> GPA0 |
  40. # 3.3v | VDD --> | 9 20 | --> INTA |
  41. # GND | VSS --> | 10 19 | --> INTB |
  42. # | NC --- | 11 18 | --> RESET | 3.3v
  43. # 5 (SCL) | SCL --> | 12 17 | <-- A2 | GND
  44. # 3 (SDA) | SDA <-> | 13 16 | <-- A1 | GND
  45. # | NC --- | 14 15 | <-- A0 | GND
  46. # | |________| |
  47. #
  48. #
  49. # PINS A0,A1,A2 determine the address assigned to the device. The diagram above sets the address i2c_address
  50. # to 0x20. To achieve a different address set the pins as follows:
  51. #
  52. # 0x20 = A0(GND) A1(GND) A2(GND)
  53. # 0x21 = A0(GND) A1(GND) A2(3.3v)
  54. # 0x22 = A0(GND) A1(3.3v) A2(GND)
  55. # 0x23 = A0(GND) A1(3.3v) A2(3.3v)
  56. # 0x24 = A0(3.3v) A1(GND) A2(GND)
  57. # 0x25 = A0(3.3v) A1(GND) A2(3.3v)
  58. # 0x26 = A0(3.3v) A1(3.3v) A2(GND)
  59. # 0x27 = A0(3.3v) A1(3.3v) A2(3.3v)
  60.  
  61.  
  62.  
  63. [hardware]
  64.  
  65. # Enable the mcp23017 port expander and set it's pin base as 65 with a chip address of 0x20
  66. # for more information on chip addressing see notes above.
  67. devices = {
  68. "mcp23017": [
  69. {
  70. "pinBase": "65",
  71. "i2cAddress": "0x20"
  72. }
  73. ]
  74. }
  75.  
  76. # GPIO Pins
  77. gpio_pins = 0,1,2,3,4,5,6,7,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80
Advertisement
Add Comment
Please, Sign In to add comment