PDA

View Full Version : Problem with DM when using IP address not Hostname



rpalmer68
January 13th, 2007, 12:28 AM
I've been struggling with a problem for a couple of days now where DM was working on my NR (.86) laptop but not on my PPC (.86) or development machine.

Today I noticed that the PPC and development machine had the girder plugin hostname set to the IP address (192.168.1.11) while my laptop had the hostname set as htpc1.

I changed the development PC to the hostname (htpc1) and then my DM calls worked correctly.

Here is the log for when the DM call DOES NOT work (when IP address is used)


00000144 28.05922508 [2472] 17:00:22.951] Lua (Unknown)] Error running lua chunk
00000145 28.05922508 [2472] ...rogram Files\Promixis\NetRemote/luascript/DMCore.lua:120: attempt to concatenate global `host' (a nil value)
00000146 28.06425095 [2472] 17:00:22.951] Lua (Unknown)] DM.SetValue("htpc1\\Meridian500\\568", "Mute","On" )
00000147 33.74827957 [2472] DM: Devices updated
00000148 33.75020218 [2472]
00000149 33.75037384 [2472] DM: Got a DM host htpc1

The Lua concole logs DM: No DMHost!

Is there a way to sort this so I can use "htpc1" in my DM calls but have the IP address set for the girder plugin?

At the moment I have to use the IP address on the PPC as for some reason it can't resolve the htpc1 hostname, and I don't know how to get it to resolve the hostname.

Cheers
Richard

mhwlng
January 13th, 2007, 03:47 AM
this problem was also reported at the end of this thread

http://www.promixis.com/forums/showthread.php?t=15702

the problem you are seeing with the ip address also happens if you switch between lower/upper case...

Marcel

Promixis
January 13th, 2007, 08:21 AM
Marcel,

What do we need to change/fix here?

mhwlng
January 13th, 2007, 08:25 AM
As mentioned in the other thread, you need to fix GetInstance in NR :

local girder = NetRemote.GetPlugin('Girder')
DM.Instance = girder:GetInstance(host)

so that host is case independent and works for both name and ip addresses..

The error is caused by a non existent global host variable in :
DM.Log(6, "Couldn't find instance for "..host)

Marcel

rpalmer68
January 15th, 2007, 02:36 PM
Is there a work around for this problem until it's fixed or is the fix close?

My PPC is basically useless now as most of my system controls have now been converted to use the DM.

Thanks
Richard

rpalmer68
January 16th, 2007, 09:57 PM
While a fix is being worked on, I found this description on how to create a hosts. file on a Windows mobile device so it can use the hostname instead of the IP address.

http://www.amset.info/pocketpc/hosts.asp

I have run it on WM5 and it works fine!

Richard