[SOLVED] mini GPIO Topic is solved

433Mhz opensource Receiver & Transmitter.

Moderators: leecollings, Stuntteam

Post Reply
Neutrino
Posts: 21
Joined: Sunday 08 May 2016 19:00
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: France
Contact:

[SOLVED] mini GPIO

Post by Neutrino »

Hi !
Since the last stable release, i'm unable to use GPIO on Rapsberry.
How can we use the RFLink miniGPIO in domoticz ?
Last edited by Neutrino on Friday 04 November 2016 17:26, edited 1 time in total.
deennoo
Posts: 784
Joined: Wednesday 10 December 2014 13:06
Target OS: Linux
Domoticz version: beta
Location: Bordeaux France
Contact:

Re: mini GPIO

Post by deennoo »

Best source is here : http://www.nemcon.nl/blog2/faq

As i'm your friend :

Q: What GPIO pins can I use and how do I use them?

A: The following pins are available:
Pin 26, 27, 28, 29 are input pins.
RFlink will report the status of these pins as if you are using a RF switch device.
When you short any of these 4 pins to ground a message of a state change is reported.
When you undo the short a new status message is send.
For example:
20;1A;GPIOset;ID=0;SWITCH=0;CMD=ON;
20;1B;GPIOset;ID=0;SWITCH=0;CMD=OFF;
You can use this for example for a wired doorbell switch.

Pin 30, 31, 32, 33 are output pins.
The following manual commands are used to control the pin status. 10;GPIOset;30;0;ON; 10;GPIOset;30;0;OFF;
10;GPIOset;31;0;ON; 10;GPIOset;31;0;OFF;
10;GPIOset;32;0;ON; 10;GPIOset;32;0;OFF;
10;GPIOset;33;0;ON; 10;GPIOset;33;0;OFF;
Setting a PIN to ON will put 5 volts on the pin. You can use this to drive a relais or so.

Using rflink create device tab.
Domoticz stable 3.5877 for real & Domoticz beta for test
Rfxtrxe / RFLink / Milight / Yeelight / Tasmota / MQTT / BLE / Zigate
http://domo-attitude.fr
Neutrino
Posts: 21
Joined: Sunday 08 May 2016 19:00
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: France
Contact:

Re: mini GPIO

Post by Neutrino »

deennoo wrote: Using rflink create device tab.
Thank you Deennoo, but I already seen this FAQ :mrgreen:
But your last sentence will very help me !
To add the GPIO 26 (input)

Code: Select all

20;1A;GPIOset;ID=0;SWITCH=0;CMD=ON;
It creates a On/Off switch in device => OK :D


But

Code: Select all

10;GPIOset;31;0;ON;
do nothing. :(
just a line in log.

Code: Select all

2016-11-02 20:20:28.012 User: initiated a RFLink Device Create command: 10;GPIOset;31;0;ON;
deennoo
Posts: 784
Joined: Wednesday 10 December 2014 13:06
Target OS: Linux
Domoticz version: beta
Location: Bordeaux France
Contact:

Re: mini GPIO

Post by deennoo »

Have you enable discover new device (as your an older user i'm sure yes but...)
Domoticz stable 3.5877 for real & Domoticz beta for test
Rfxtrxe / RFLink / Milight / Yeelight / Tasmota / MQTT / BLE / Zigate
http://domo-attitude.fr
Neutrino
Posts: 21
Joined: Sunday 08 May 2016 19:00
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: France
Contact:

Re: mini GPIO

Post by Neutrino »

As an older user, yes :D
Actually, it's always enable since the 1-wire hardware need this every reboot.

Code: Select all

2016-11-02 21:29:45.865 User: initiated a RFLink Device Create command: 20;1C;GPIOset;ID=0;SWITCH=0;CMD=ON;
2016-11-02 21:29:45.956 (RFLink) Light/Switch (MiniGPIO 26)
2016-11-02 21:29:57.276 User: initiated a RFLink Device Create command: 20;1A;GPIOset;ID=0;SWITCH=0;CMD=ON;
2016-11-02 21:29:57.351 (RFLink) Light/Switch (MiniGPIO 26)
2 commands via Hardware tabs => Same result, only one switch :|
And when I short to the ground the pins (26-27-28-29), nothing appends.
Neutrino
Posts: 21
Joined: Sunday 08 May 2016 19:00
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: France
Contact:

Re: mini GPIO

Post by Neutrino »

Thanks to the Stuntteam to have solved my problem.
1st, you need to enable the GPIO.
In the "Create RFLink Devices" popup, enter the command :

Code: Select all

10;setgpio=on
With "Accept new Hardware Devices" enabled, just short to ground the pins 26 27 28 and 29, the devices will be create in devices tab.

To create an output device, in the same popup, entrer the following command :

Code: Select all

20;01;GPIOset;ID=30;SWITCH=0;CMD=ON;
Congratulations, you can control the pin 30 ! :mrgreen:
Do the same with 31 32 and 33 :)
User avatar
Stuntteam
Posts: 399
Joined: Wednesday 06 May 2015 16:39
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: [SOLVED] mini GPIO

Post by Stuntteam »

You can also enable gpio within rflink loader after flashing the Arduino..
-=# RFLink Gateway Development Team #=-
Introduction: http://www.nemcon.nl/blog2/
Generic RFLink Support forum: http://www.esp8266.nu/forum/viewforum.php?f=8
adampr1
Posts: 2
Joined: Thursday 17 November 2016 9:46
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Germany
Contact:

Re: [SOLVED] mini GPIO

Post by adampr1 »

Hi, I've RFlink 44.8 and configured like in this post. All inputs works ok , but from all four outputs only one (GPIO30) is switched OK.
Even if Domoticz send command:

User: Admin initiated a switch command (223/GPIO_31/On)
RFLink Sending: 10;GPIOset;000031;0;ON
(RFLink) Light/Switch (GPIO_31)

that will turn on GPIO30 (if was previous Off)
Any from GPIO 30..33 switch on/off command switch only GPIO30.

Any sugestion ?
Domoticz Beta release on OrangePI PC,
Domoticz Beta release on BananaPI,
2x RFLink 45.4 (test version),
ESPEasy (different configurations),
MySensors (different configurations),
2x MiLight RGBW (over RFLink)
and others things :)
User avatar
Stuntteam
Posts: 399
Joined: Wednesday 06 May 2015 16:39
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: [SOLVED] mini GPIO

Post by Stuntteam »

PM send..
-=# RFLink Gateway Development Team #=-
Introduction: http://www.nemcon.nl/blog2/
Generic RFLink Support forum: http://www.esp8266.nu/forum/viewforum.php?f=8
adampr1
Posts: 2
Joined: Thursday 17 November 2016 9:46
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: Germany
Contact:

Re: [SOLVED] mini GPIO

Post by adampr1 »

working like a charm with test version RFLink v45.4. Thank You.
Domoticz Beta release on OrangePI PC,
Domoticz Beta release on BananaPI,
2x RFLink 45.4 (test version),
ESPEasy (different configurations),
MySensors (different configurations),
2x MiLight RGBW (over RFLink)
and others things :)
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest