PDA

View Full Version : Sending/Receiving longer commands by TCP/IP



Mabiel
January 15th, 2007, 04:59 PM
I have a problem with processing the 'completeir' acknowledge command received from the GC-100.
When I send an ir command with an ID of one or two digits then there's no problem.
The GC-100 will return 'completeir,5:3,15' and Netremote can process it by lua code:
function Generic.Receive(plugin_instance,message)
if (string.sub(message,0,10) == 'completeir') then
if (string.sub(message,16,17) == '15') then send next IR command.
end;
end;
end.

In this way I can create macro's in LUA.
But I want to use more ID's so I tried for example sendir,5:3,105,......
The GC-100 will return 'completeir,5:3,105' but netremote is not responding to that. It seems to me that the buffer in netremote is to small to buffer this longer command.

There is also a problem with sending longer commands to the GC-100. I have to split it in 2 lines of LUA, otherwise the command is ignored by the GC-100. Is it possible to make the buffer bigger for sending and receiving commands? It will be great help to me.

Ben S
January 18th, 2007, 08:07 AM
I hate to make you change this, but are you familiar with GIP? It appears the NR design guide doesn't cover this, but the Girder guide does. It's a much nicer way of handling Generic IP and is more lua centric, and most likely doesn't have these limitations that you've found.