PiFace on CE1
Posted: Thursday 02 June 2016 22:50
Hi all,
I'm facing the problem that spidev0.0 is taken by my display device (2.2" ILI 9340 based). I have tried to move it to spidev0.1 by modifying device-tree overlays but so far without success. The alternative is to move the PiFace to spidev0.1, this is easy but requires a source code modification which of course gets overwritten at every update. Therefore my suggestion is to make this configurable. The easiest way to do this is using the piface.conf file, for instance by adding an extra line like "device=spidev0.1", meaning that all subsequent lines apply to that device, this would even allow to have more pifaces on the RPi by using both CEs. Another option would be to have different piface.conf files for each bus/CE (e.g. piface00.conf, piface01.conf etc.). This way the config files stay compatible (apart from the name). A third way is to select the interface when adding the piface hardware in domoticz (similar to selecting a serial port), this however I don't know how to do and would require some help. My personal preference is the first option which can even be extended to i2c busses (of course using the MCP23017 instead of the MCP23S17).
Does anybody have more ideas on how this problem could be tackled or a specific preference for any of my solutions?
Thanks,
AW
I'm facing the problem that spidev0.0 is taken by my display device (2.2" ILI 9340 based). I have tried to move it to spidev0.1 by modifying device-tree overlays but so far without success. The alternative is to move the PiFace to spidev0.1, this is easy but requires a source code modification which of course gets overwritten at every update. Therefore my suggestion is to make this configurable. The easiest way to do this is using the piface.conf file, for instance by adding an extra line like "device=spidev0.1", meaning that all subsequent lines apply to that device, this would even allow to have more pifaces on the RPi by using both CEs. Another option would be to have different piface.conf files for each bus/CE (e.g. piface00.conf, piface01.conf etc.). This way the config files stay compatible (apart from the name). A third way is to select the interface when adding the piface hardware in domoticz (similar to selecting a serial port), this however I don't know how to do and would require some help. My personal preference is the first option which can even be extended to i2c busses (of course using the MCP23017 instead of the MCP23S17).
Does anybody have more ideas on how this problem could be tackled or a specific preference for any of my solutions?
Thanks,
AW