New FREE Control4 Driver Available (JSON)

  Thread Rating:
  • 3 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
Blackfiveo Offline
Junior Member
Posts: 7
Joined: Jun 2016
Reputation: 0
Post: #181
(2017-02-21 21:41)RetardedGoat Wrote:  
(2017-02-20 23:00)Blackfiveo Wrote:  
(2016-08-09 19:30)RetardedGoat Wrote:  No a separate thread, I'm afraid. Just earlier in this one.

http://forum.kodi.tv/showthread.php?tid=...pid2232098

I wrote this Event Server version because the JSON one had a few minor limits(like you noticed with the On Screen Display). I posted it in this thread because even though it's an 80% rewrite, it is based on the JSON one BrandonJ wrote.

BrandonJ was great in that he posted his source code on GitHub. I'd do the same except I don't know how. And I'm too phenomenally lazy to figure it out. But if anyone expresses interest, I can post it here and/or figure out GitHub.


Thanks so much for the driver, been trying to get it with my matricom box and no luck. Is there a way to know that it has succesfully established connection from ComposerPro. I put in the MAC Address with no spaces or colons but it doesnt seem to connect


Code:
XBMC: ReceivedFromProxy: ON
Got ON Command:
XBMC: OnConnectionStatusChanged[6003 (9)]: ONLINE
XBMC: OnConnectionStatusChanged[6003 (9)]: OFFLINE
XBMC: OnConnectionStatusChanged[6003 (9)]: ONLINE
XBMC: ReceivedFromProxy: GET_ADV_SCENES
XBMC: ReceivedFromProxy: GET_ADV_SCENES
[string "Lua Code"]:91: attempt to concatenate local 'strData' (a nil value) (ReceivedFromProxy)
[string "Lua Code"]:91: attempt to concatenate local 'strData' (a nil value) (ReceivedFromProxy)
XBMC: ReceivedFromProxy: GET_ADV_SCENES
[string "Lua Code"]:91: attempt to concatenate local 'strData' (a nil value) (ReceivedFromProxy)
XBMC: ReceivedFromProxy: GET_ADV_SCENES
[string "Lua Code"]:91: attempt to concatenate local 'strData' (a nil value) (ReceivedFromProxy)
On Timer Expired
On Timer Expired
Unrecognized TimerID
Sending Wake on LAN magic packet
00000000  FF FF FF FF FF FF C4 4E  AC 10 1C FD C4 4E AC 10  .......N.....N..
00000010  1C FD C4 4E AC 10 1C FD  C4 4E AC 10 1C FD C4 4E  ...N.....N.....N
00000020  AC 10 1C FD C4 4E AC 10  1C FD C4 4E AC 10 1C FD  .....N.....N....
00000030  C4 4E AC 10 1C FD C4 4E  AC 10 1C FD C4 4E AC 10  .N.....N.....N..
00000040  1C FD C4 4E AC 10 1C FD  C4 4E AC 10 1C FD C4 4E  ...N.....N.....N
00000050  AC 10 1C FD C4 4E AC 10  1C FD C4 4E AC 10 1C FD  .....N.....N....
00000060  C4 4E AC 10 1C FD                                 .N....
XBMC: ReceivedFromProxy: ENTER
Sending EventServer packet: enter
XBMC: ReceivedFromProxy: ENTER
Sending EventServer packet: enter
XBMC: ReceivedFromProxy: ENTER

Did you specify the IP address in the Connections section of Composer?

Open Composer.
Click on Connections(Just below System Design on the bottom left)
Click the Network tab.
Select 'IP Network'
Your kodi device should be in the list on the right. Right click it and select 'Identity'.
Enter the IP address of your Kodi device.

Hopefully this gets things going for you. Let me know if it doesn't work.

That was it! works like a boss!! thank you very very much!
find quote
Blackfiveo Offline
Junior Member
Posts: 7
Joined: Jun 2016
Reputation: 0
Post: #182
Was trying to convert this over to a c4z to change the icon but there not having anyluck maybe my <capabilities> tag is in the wrong area, do you have any experience with that?
find quote
kataiba Offline
Member
Posts: 73
Joined: Oct 2012
Reputation: 0
Location: London
Post: #183
I cant manage to setup a hotkey on the coloured keys. The default one 't' in the driver works but anything else i try to input (for example 'h') doesn't stick in the driver and isn't sent by Lua.

XBMC: ReceivedFromProxy: PROGRAM_A
Sending EventServer packet: t
XBMC: ReceivedFromProxy: PROGRAM_A
Sending EventServer packet: t
XBMC: ReceivedFromProxy: PROGRAM_D
XBMC: ReceivedFromProxy: PROGRAM_D
XBMC: ReceivedFromProxy: PROGRAM_D
XBMC: ReceivedFromProxy: PROGRAM_D

I set 'h' on program D keymap in the properties but it seems it's not doing anything.
Thanks
find quote
Blackfiveo Offline
Junior Member
Posts: 7
Joined: Jun 2016
Reputation: 0
Post: #184
(2017-02-24 19:41)Blackfiveo Wrote:  Was trying to convert this over to a c4z to change the icon but there not having anyluck maybe my <capabilities> tag is in the wrong area, do you have any experience with that?

I figured it out, had some silly typos in it
find quote
Blackfiveo Offline
Junior Member
Posts: 7
Joined: Jun 2016
Reputation: 0
Post: #185
Anyone try this on Krypton?!
find quote
kataiba Offline
Member
Posts: 73
Joined: Oct 2012
Reputation: 0
Location: London
Post: #186
(2017-04-07 03:29)Blackfiveo Wrote:  Anyone try this on Krypton?!

yes i can confirm it's working fine both 17.0 17.1 android and libreelec
(This post was last modified: 2017-04-07 21:51 by kataiba.)
find quote
Blackfiveo Offline
Junior Member
Posts: 7
Joined: Jun 2016
Reputation: 0
Post: #187
Anyone here with Control4 using an AppleTV box with Kodi side-loaded? Using the AppleTV driver once in Kodi the "select" button doesnt seem to work. Just curious if anyone else is trying to accomplish Kodi through AppleTV with a Control4 remote
find quote
mindedc Offline
Junior Member
Posts: 6
Joined: Jun 2014
Reputation: 0
Post: #188
I just installed this driver and I noticed it wouldn't power off the kodi unit on room off even though the shutdown property was configured to do so. I did some debugging and what appears to be happening is that the connection is getting severed before OnConnectionStatusChanged function is called. This creates a condition where idBinding = 6004 and strStatus = OFFLINE which is not accounted for. Therefore the RPC call is never sent to power the unit off. I tried a few workarounds and got it working in my local copy but in not what I would call a clean way. It looks like C4 can shut the network connection down if you don't call C4:NetPortOptions with the KEEP_ALIVE parameter. I don't know if it would be cleaner to hold the connection open or add a case such that if the connection is down it can re-open one before sending the shutdown command.

I experienced this with multiple intel NUCs running Kodi. It seems like the condition would occur after they were on for a while. I did validate with the switch infrastructure that there was no packet loss.


Code:
function OnConnectionStatusChanged(idBinding, nPort, strStatus)
        dbg("XBMC: OnConnectionStatusChanged[" .. idBinding .. " (" .. nPort .. ")]: " .. strStatus)

        if (idBinding == 6003) then
                if (strStatus == "ONLINE") then
                        idWakeOnLan = C4:AddTimer(Properties["Power On Delay-Seconds"], "SECONDS", false)
                end
        elseif(idBinding == 6004) then
                if (strStatus == "ONLINE") then
                        dbg("TCP Connected.  Sending Shutdown Command.")
                        JsonRPCSend(XBMC_SHUTDOWN_ACTIONS[Properties['Room Off Command']])
                end
        end
end
find quote
Post Reply