Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - SimonB

Pages: [1]
1
General Discussion / Re: UDP Events
« on: February 21, 2014, 12:02:30 PM »
Hi James

Thanks for the help so far.  I've had some fun over the last week or so teaching myself some basic Python & modifying the script you wrote.  [As an aside, key driver for this is that the UDP packets that I'm receiving are the interpretations of the IR code that my network connected receiver is picking up... & due to the natural variability of IR, I've had to (with a bit of advice from the manufacturer of the IR receiver unit) write some code to allow for this variability & map back to what should be a consistent read of the IR pulses.]

Anyway... on to my question.  The Python script is now returning the UDP packets reliably as payload {1} in a text format such as "ABCDCDCDBCDCDC" (representation of the IR code).  What I ideally want to do now is the equivalent of an Excel vlookup - I want to match the payload returned to obtain the Global Cache command to send out over the network, & be able to do this for a bunch of possible valid different payload values.  Ideally a logical statement along the lines - If (data field1 from any row in my table) matches (payload from Python script) then (return data field 2 from the same row in the table).  I then want to be able to use (data field 2) as the value to send out to my GC iTach unit.

I had thought I could achieve this vlookup type functionality using Maps in the LCB - but having played around a bit I don't think they work in this way.  Can I in fact use the Map/LCB functionality to do what I want - or do I need to get to grips with more Python coding (including importing values from table) to achieve my goal?

All good fun & interesting.

Simon

2
General Discussion / Re: UDP Events
« on: February 13, 2014, 02:22:21 PM »
Wow.  Thank you very much James... this is going to open up a whole bunch of interesting possibilities.  VC really is super-powerful & adaptable - can't quite believe that something I came across as 'that'll be cool to control my kit by voice' has the ability to also act as the glue between IR & serial control... & if I work things out carefully, I suspect can act as a query-able state server for my sources that are operated across multiple rooms (I'm thinking about writing to & reading from tables).

Kudos also for your support & turnaround today - exemplary.

Simon

3
General Discussion / Re: UDP Events
« on: February 13, 2014, 10:31:56 AM »
Hi jitterjames

No - I don't have any (real) control over the UDP packets sent.  They are the representation (using the IR receiver manufacturer's algorithm) of the IR code received by the unit.  So for example when I send the 'blinds up' IR signal, the UDP packet showing in history window is 'K 220C 03F7 03F7.... 06F0 03FA 2000' - it's essentially a leading 'K' (for Keene) & then the hex representation of how the unit decomposes the various IR pulses that make up the signal.

Given your note below, sounds like I will struggle to use this UDP packet format however. It's a shame - for a while I thought that VC might be the secret sauce to let me put together a flexible IR->RS232 converter (something I've been trying to do for a bit!).

If you have any other thoughts on how I can use the UDP packets that VC is seeing they'd be appreciated - otherwise potentially back to the drawing board...

Thks
Simon

4
General Discussion / UDP Events
« on: February 13, 2014, 09:39:11 AM »
Hi

I'm getting started with VoxCommando & have a question about UDP events.  What I'm trying to achieve is as follows... I have an IR receiver unit in my system that converts received IR into data packets which it then sends over my home network to a similar unit which then converts the data back to IR & emits to control a particular source [for info, the units are KIRA units from Keene Electronics in the UK].  The receiver broadcasts the data packets via UDP port 65432.  What I would like to do is to trigger an event (sending an RS232 serial data command via a GC iTach unit) based upon a particular IR code data packet being broadcast.

I have adjusted the UDP 'Listen port' in VoxCommando to 65432 - & having done this, I am seeing Events in the VC History window whenever I send an IR command to the KIRA receiver unit.  The History window shows 2 Events for each IR command: (1) a green 'wi fi' style icon together with the relevant data packet (2) a green cog icon with the same data packet highlighted orange - & a tooltop which states 'Error: Unknown Action'.

I have separately been able to successfully send a serial RS232 command to my iTach (using a voice command).  I've also got working the executing of Actions by dragging events (e.g focused.OUTLOOK) into the command editor.

What I'm unable to do is to set Actions to trigger based upon a received UDP broadcast - when I try to drag across the green 'wi fi' style icon to the command editor from the History tab, I get an 'Invalid xml' error message box.

I'd be very grateful if someone could advise whether it is possible to do what I looking to achieve here - essentially trigger an Action based on receiving a UDP broadcast, & pass into the Logical Command Builder the content of the UDP broadcast so that it can be tested with some If-Then logic to determine a conditional Action.

Hope that makes sense...!

Simon

Pages: [1]