Hey,
I had the same problem a couple weeks ago with the new openhabian 3 release and the CC1101 module. The simplest solution I could find was to execute echo "24" > /sys/class/gpio/export
(maybe its a different pin for you) during start with a crontab. For details look at step 4.
For completeness, I wrote down all the steps I needed to get the CC1101 running with homegear und openHab 3. However, if you are using another module, you might need to make some changes in step 2 to 4, but I think the most important part is about exporting the reset pin at startup, which should be the same:
-
Install homgear via
sudo openhabian-config
. Then execute10 | Apply Improvements
14 | Fix Permissions
. -
Uncomment
#dtparam=spi=on
in/boot/config.txt
. -
Uncomment the lines in
/etc/homegear/families/homematicbidcos.conf
below########## TI CC1101 Module ##########
the following way:## The device family this interface is for [TI CC1101 Module] ## Specify an unique id here to identify this device in Homegear id = My-CC1101 ## When default is set to "true" Homegear will assign this device ## to new peers. default = true ## Options: cul, cc1100, coc, cunx, hmcfglan, hmlgw, hm-mod-rpi-pcb, homegeargateway deviceType = cc1100 device = /dev/spidev0.0 ## Default: responseDelay = 95 ## Should be "95" for CUL or COC, "100" for TI CC1101 and "60" for HM-CFG-LAN or HM-LGW responseDelay = 100 ## The interrupt pin to use. "0" for GDO0 or "2" for GDO2. ## You only need to connect one of them. Specify the GPIO ## you connected the interrupt pin to below. interruptPin = 2 ## The GPIO GDO0 or GDO2 is connected to. Specify which GDO to use above. gpio1 = 24
If you prefer to use GDO0 and pin 25, change the numbers accordingly.
-
Use
crontab -e
to open the cron task list and add the line@reboot echo "24" > /sys/class/gpio/export
(or change to the pin number you need). Safe and shutdown the system withsudo shutdown -h now
. -
Disconnect power. If you haven’t done it already, connect SPI pins of the CC1101 with the ones of the RPi. Connect
homematicbidcos.conf
the CC1011 pin GDO2(GDO0) with RPi GPIO pin 24(25). -
Reconnect power to the RPi.
I don’t know if its 100% guaranteed that the cron task will be executed before the start of homegear, but during the testing I did so far, it always worked.