DMX Colorpicker - how to use?

Hello all,
I’m a total beginner with Openhab and I’m trying to control a simple RGB-Spot.

The spot is connected trough a DMX-Interface and OLA. The spot is configured fpr Univers 0, Channel 1,2,3,4.
I can control the spot through OLA DMX console, but when I try to control it through Openhab it shows some weird behaviour.

I started with the openhab docu on http://openhabdoc.readthedocs.org/de/latest/

I added enabled DMX in configurations and added a line in the item file:
Color rgb_spot “RGB 10” (gOG) {dmx=“CHANNEL[1,2,3,4:100]”}

Strange thing: It only sends channel 1,2 and 3 - I can see updates in DMX monitor.
When I increase value for channel 4 through DMX Console the spot gets brighter.
I then can turn the spot off in Openhab (channel 4) - but can’t turn it on again!!!

Yesterday I tried several different settings in the items file
e.g. {dmx=“CHANNEL[1/4:1000]”}
{dmx=“CHANNEL[1:1000]”}
{dmx=“CHANNEL[1,2,3:1000]”}

Somehow the system suddenly decided to send two values per channel (Red was on channel 1 and 2, Green was on 3 and 4 and blue on 5 and 6).
I don’t know why, but this got reverted over night.

What am I missing?

Anybody any ideas?

Mox

Both of those configurations are identical and correct.
A color item in openHAB only contains 3 channels (Hue/Saturation/Brightness).
When its value is changed, the dmx binding will convert these to the corresponding RGB or RGBW values.

Color pickers in openHAB may behave differently depending on the UI that you are using.

You can try setting the HSB values directly from the console:

openhab send rgb_spot 50,50,50
openhab send rgb_spot 20,60,80
...

In OLA you should see the 4 channels being updated.

Try this:
Color CustomFade {dmx="CHANNEL[16/3], ON[FADE|1000:0,0,0:-1]"}

You can send the on-command and it will fade to off (0,0,0) or you can assign it a colorpicker in a sitemap

I don’t know how to use the console.

I run OpenHab together with OLA on a headless Debian Box. There is no GUI. I tried to find out how to enable the Console (it’s part of Eclipse environment?). But what do I need to install?

I had Openhab Designer running on an Windows Computer and shared files via Samba. But it’s an rather “simple” interface. I couldn’t even create new files (had to Copy&Paste and rename the README). And suddenly I was not able to save files anymore. Till I found out that OpenHab updated access rights …
A quite frustrating experience.

So I’m back to edit files with nano on command line.

Today I tried to assign DMX channel 4 to a slider so i could change brightness via a separate control. In Firefox I wasn’t able to move the slider and Internet Explorer froooze as soon as I tried to move the slider.

So still no progress.

I can’t find the right infos in the wiki. I’m not a softwaredeveloper and don’t know Java. maybe that’s why I don’t find my way through all this scattered info :frowning:

All in all - no progress on the learning curve

mox

@davy how does openhab send rgb_spot 50,50,50 work, do I type it in Putty?

The problem is that I can not get the dmx to work at all on my RPI, i tried both port 9010 and 9090:

dmx:connection=localhost:9090
#dmx:connection=192.168.1.156:9090
 

17:30:35.840 [ERROR] [.d.internal.core.DmxController:268  ] - Error opening DMX connection.
java.lang.Exception: Error connecting to localhost:9090. Make sure the olad daemon is running.
        at ola.rpc.StreamRpcChannel.connect(StreamRpcChannel.java:76) ~[ola-java-client-0.0.3.jar:na]
        at ola.OlaClient.connect(OlaClient.java:72) ~[ola-java-client-0.0.3.jar:na]
        at org.openhab.binding.dmx.ola.OlaConnection.open(OlaConnection.java:55) ~[bundlefile:na]
        at org.openhab.binding.dmx.internal.core.DmxController.getConnection(DmxController.java:266) ~[bundlefile:na]
        at org.openhab.binding.dmx.internal.core.DmxTransmitter.run(DmxTransmitter.java:62) [bundlefile:na]
        at java.util.TimerThread.mainLoop(Timer.java:555) [na:1.8.0]
        at java.util.TimerThread.run(Timer.java:505) [na:1.8.0]
Caused by: java.net.ConnectException: Connection timed out
        at java.net.PlainSocketImpl.socketConnect(Native Method) ~[na:1.8.0]
        at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345) ~[na:1.8.0]
        at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206) ~[na:1.8.0]
        at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188) ~[na:1.8.0]
        at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) ~[na:1.8.0]
        at java.net.Socket.connect(Socket.java:589) ~[na:1.8.0]
        at java.net.Socket.connect(Socket.java:538) ~[na:1.8.0]
        at java.net.Socket.<init>(Socket.java:434) ~[na:1.8.0]
        at java.net.Socket.<init>(Socket.java:211) ~[na:1.8.0]
        at ola.rpc.StreamRpcChannel.connect(StreamRpcChannel.java:70) ~[ola-java-client-0.0.3.jar:na]
        ... 6 common frames omitted
17:30:35.856 [DEBUG] [.p.rrd4j.internal.RRD4jService:113  ] - Stored 'LMB1' with state '0.125490209999999990930774629305233247578144073486328125' in rrd4j database (again)

However the ola it self works superb:

My addons looks like this:

and my item looks like:
Color LMB1 "LMB1"(Group_Light,Group_MasterBedroom) {dmx="CHANNEL[125,126,127:1000]"}

and then my sitemap:

Text label="Master Bedroom" icon="bedroom"{
			Switch item=Light_MasterBedroom icon="hue" 
			Colorpicker item=LMB1
		}

so i am pretty sure thats correct because the log says:

17:30:44.379 [DEBUG] [.p.internal.PersistenceManager:377 ] - Restored item state from '12-May-2016 17:30:35' for item 'LMB1' -> '0.1333333399999999946405893069822923280298709869384765625'

So where can the problem be?

9090 is the http port. You need to use the port of the ola daemon (default is 9010).

Verify that the port 9010 is accessible and is not blocked by a firewall.

You can enter the command in the osgi console.

Thanks @davy

how can I test the 9010 is not blocked on my rpi?

How can I start the osgi?

@davy Seems like the port is listening on my rpi: Should write as well?

 netstat -a
tcp        0      0 *:http-alt              *:*                     LISTEN
tcp        0      0 localhost:9010          *:*                     LISTEN
tcp        0      0 *:5555                  *:*                     LISTEN
tcp        0      0 *:ssh                   *:*                     LISTEN
tcp        0      0 *:8443                  *:*                     LISTEN
tcp        0      0 *:1883                  *:*                     LISTEN
tcp        0      0 raspberrypi.local:39328 f6.netatmo.net:https    ESTABLISHED
tcp        0      0 raspberrypi.local:ssh   skatun-laptop.loc:53590 ESTABLISHED
tcp        0      0 raspberrypi.local:ssh   skatun-laptop.loc:53819 ESTABLISHED
tcp       32      0 raspberrypi.local:55012 f6.netatmo.net:https    CLOSE_WAIT
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address           Foreign Address         State
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.158:34701     ESTABLISHED
tcp        0      0 raspberrypi.local:36689 f6.netatmo.net:https    ESTABLISHED
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.158:50563     ESTABLISHED
tcp       32      0 raspberrypi.local:38401 f6.netatmo.net:https    CLOSE_WAIT
tcp       32      0 raspberrypi.local:37183 f6.netatmo.net:https    CLOSE_WAIT
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.158:58471     ESTABLISHED
tcp        0      0 raspberrypi.local:44175 li464-188.members:https ESTABLISHED
tcp        0    256 raspberrypi.local:ssh   skatun-laptop.loc:53646 ESTABLISHED
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.67:46955      ESTABLISHED
tcp        0      0 raspberrypi.local:36409 f1.netatmo.net:https    ESTABLISHED
tcp        0      0 raspberrypi.local:44292 f1.netatmo.net:https    ESTABLISHED
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.67:48677      ESTABLISHED
tcp        0      0 *:8001                  *:*                     LISTEN
tcp        0      0 *:9090                  *:*                     LISTEN
tcp        0      0 *:http-alt              *:*                     LISTEN
tcp        0      0 raspberrypi.local:35831 f5.netatmo.net:https    TIME_WAIT
tcp        0      0 localhost:9010          *:*                     LISTEN
tcp        0      0 *:5555                  *:*                     LISTEN
tcp        0      0 *:ssh                   *:*                     LISTEN
tcp        0      0 *:8443                  *:*                     LISTEN
tcp        0      0 *:1883                  *:*                     LISTEN
udp        0      0 raspberrypi.local:52956 localhost:ntp           ESTABLISHED
udp        0      0 *:mdns                  *:*
udp        0      0 *:mdns                  *:*
udp        0      0 *:52508                 *:*
udp        0      0 *:57910                 *:*
udp        0      0 *:bootpc                *:*
udp        0      0 raspberrypi.local:ntp   *:*
udp        0      0 *:ntp                   *:*
Active UNIX domain sockets (servers and established)
Proto RefCnt Flags       Type       State         I-Node   Path
unix  2      [ ACC ]     STREAM     LISTENING     6679     /var/run/dbus/system_bus_socket
unix  2      [ ]         DGRAM                    8301     /var/run/thd.socket
unix  2      [ ACC ]     STREAM     LISTENING     7536     /var/run/avahi-daemon/socket
unix  9      [ ]         DGRAM                    8320     /dev/log
unix  2      [ ACC ]     SEQPACKET  LISTENING     5004     /run/udev/control
unix  2      [ ]         STREAM     CONNECTED     159394
unix  2      [ ]         DGRAM                    1635
unix  3      [ ]         STREAM     CONNECTED     145483
unix  3      [ ]         STREAM     CONNECTED     1630
unix  2      [ ]         DGRAM                    8353
unix  3      [ ]         DGRAM                    1244
unix  2      [ ]         DGRAM                    7758
unix  2      [ ]         DGRAM                    145479
unix  2      [ ]         STREAM     CONNECTED     159385
unix  3      [ ]         STREAM     CONNECTED     7514
unix  2      [ ]         DGRAM                    7530
unix  3      [ ]         STREAM     CONNECTED     7533
unix  3      [ ]         STREAM     CONNECTED     7538
unix  2      [ ]         DGRAM                    7571
unix  3      [ ]         STREAM     CONNECTED     7676     /var/run/dbus/system_bus_socket
unix  3      [ ]         DGRAM                    1243
unix  3      [ ]         STREAM     CONNECTED     145482
unix  3      [ ]         STREAM     CONNECTED     7515
unix  2      [ ]         DGRAM          tcp        0      0 raspberrypi.local:39328 f6.netatmo.net:https    TIME_WAIT
tcp        0      0 raspberrypi.local:53622 f1.netatmo.net:https    ESTABLISHED
tcp        0      0 raspberrypi.local:44185 li464-188.members:https TIME_WAIT
tcp        0      0 raspberrypi.local:ssh   skatun-laptop.loc:53590 ESTABLISHED
tcp        0      0 raspberrypi.local:ssh   skatun-laptop.loc:53819 ESTABLISHED
tcp        0      0 raspberrypi.local:44186 li464-188.members:https ESTABLISHED
tcp       32      0 raspberrypi.local:55012 f6.netatmo.net:https    CLOSE_WAIT
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.158:34701     ESTABLISHED
tcp        0      0 raspberrypi.local:36689 f6.netatmo.net:https    TIME_WAIT
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.158:50563     ESTABLISHED
tcp       32      0 raspberrypi.local:38401 f6.netatmo.net:https    CLOSE_WAIT
tcp       32      0 raspberrypi.local:37183 f6.netatmo.net:https    CLOSE_WAIT
tcp        0      0 raspberrypi.local:39292 f2.netatmo.net:https    ESTABLISHED
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.158:58471     ESTABLISHED
tcp        0   1328 raspberrypi.local:ssh   skatun-laptop.loc:53646 ESTABLISHED
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.67:46955      ESTABLISHED
tcp        0      0 raspberrypi.local:36409 f1.netatmo.net:https    TIME_WAIT
tcp        0      0 raspberrypi.local:44573 f2.netatmo.net:https    ESTABLISHED
tcp        0     70 raspberrypi.local:44187 li464-188.members:https FIN_WAIT1
tcp        0      0 raspberrypi.lo:http-alt 192.168.1.67:48677      ESTABLISHED
tcp        0      0 raspberrypi.local:49764 f1.netatmo.net:https    TIME_WAIT
udp        0      0 raspberrypi.local:52956 localhost:ntp           ESTABLISHED
udp        0      0 *:mdns                  *:*
udp        0      0 *:mdns                  *:*
udp        0      0 *:52508                 *:*
udp        0      0 *:57910                 *:*
udp        0      0 *:bootpc                *:*
udp        0      0 raspberrypi.local:ntp   *:*
udp        0      0 *:ntp                   *:*
Active UNIX domain sockets (servers and established)
Proto RefCnt Flags       Type       State         I-Node   Path
unix  2      [ ACC ]     STREAM     LISTENING     6679     /var/run/dbus/system_bus_socket
unix  2      [ ]         DGRAM                    8301     /var/run/thd.socket
unix  2      [ ACC ]     STREAM     LISTENING     7536     /var/run/avahi-daemon/socket
unix  9      [ ]         DGRAM                    8320     /dev/log
unix  2      [ ACC ]     SEQPACKET  LISTENING     5004     /run/udev/control
unix  2      [ ]         STREAM     CONNECTED     159394
unix  2      [ ]         DGRAM                    1635
unix  3      [ ]         STREAM     CONNECTED     145483
unix  3      [ ]         STREAM     CONNECTED     1630
unix  2      [ ]         DGRAM                    8353
unix  3      [ ]         DGRAM                    1244
unix  2      [ ]         DGRAM                    7758
unix  2      [ ]         DGRAM                    145479
unix  2      [ ]         STREAM     CONNECTED     159385
unix  3      [ ]         STREAM     CONNECTED     7514
unix  2      [ ]         DGRAM                    7530
unix  3      [ ]         STREAM     CONNECTED     7533
unix  3      [ ]         STREAM     CONNECTED     7538
unix  2      [ ]         DGRAM                    7571
unix  3      [ ]         STREAM     CONNECTED     7676     /var/run/dbus/system_bus_socket
unix  3      [ ]         DGRAM                    1243
unix  3      [ ]         STREAM     CONNECTED     145482
unix  3      [ ]         STREAM     CONNECTED     7515
unix  2      [ ]         DGRAM                    6678
unix  3      [ ]         STREAM     CONNECTED     7532
unix  3      [ ]         STREAM     CONNECTED     7539     /var/run/dbus/system_bus_socket

Seems like there is no firewall installed on the rpi, so the issue must be somewhere else…

I got rid of the errors, but it still does not work. In my addons folder i had 1.7 jar of ola and the artnet aswell as the dmx jar. Deleting everything except of ola and dmx got rid of the errors. So my question now is where the error is.Should I use artnet and not ola? How did you @davy got it to work. Can you show me ur addon folder and your ola settings? Thanks

Why would you have both ola and artnet bundles installed? The [wiki] (https://github.com/openhab/openhab/wiki/DMX-Binding) clearly states:

To use the DMX binding, install the CORE bundle and ONE device interface bundle

I don’t use OLA anymore myself. I use the artnet bundle and an artnet device.
You could also use artnet and configure OLA as an artnet node.
Or you can use the OLA bundle with OLA and no artnet.

Yeah, so my question did you use ola or did you use ola as an artnet node, because I can not get ola to work from Oh, only from the ola html page.

I have used OLA directly from openHAB previously, but not with the latest version of OLA.
If you configure OLA as an artnet node, that should work without issues.

Hello Mox,

Have you got this working in the meantime?
I have the same problem with an RGBW LED strip.
The 4th channel gets always value 0 when i change something in the colorpicker.
I can’t find a solution for it.