Path: news.mathworks.com!not-for-mail
From: "Michele " <denber.nospam@mindspringNOSPAM.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: urlread passing special characters
Date: Thu, 21 Feb 2008 01:35:03 +0000 (UTC)
Organization: Michele Denber (ID: 1-A7A3B)
Lines: 36
Message-ID: <fpikg7$djj$1@fred.mathworks.com>
References: <fpi8c2$t5k$1@fred.mathworks.com> <fpi9lc$fkh$1@fred.mathworks.com>
Reply-To: "Michele " <denber.nospam@mindspringNOSPAM.com>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1203557703 13939 172.30.248.35 (21 Feb 2008 01:35:03 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Thu, 21 Feb 2008 01:35:03 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 174773
Xref: news.mathworks.com comp.soft-sys.matlab:452807


"Matthew Simoneau" <matthew@mathworks.com> wrote in message
<fpi9lc$fkh$1@fred.mathworks.com>...
> URLREAD is encoding these because the GET needs to be a
> valid URL.  Shouldn't whatever's on the other end be
> decoding these?

That's really an excellent question.  To avoid any
embarrassment to the manufacturer of the device I'm trying
to talk to, I'll refer to it simply as a "Frobniz 43" -
that's not its real name.  (Its real name is the HRGZ-01
Z-Wave Gateway by Hawking Technology).

All I can tell you is that when I send an HTTP "get device
status" command to the Frobniz using the web client provided
by Hawking, the packet comes out as
'/goform/getdevicestatus' on the wire.  When I try to
emulate that in Matlab using urlread, it comes out as
'%2Fgoform%2Fgetdevicestatus' and I get back an error
message from Matlab "Error downloading URL.".

The URL itself is valid, because I do get an appropriate
response when I do a plain urlread on the server without a
getdevicestatus request.

Considering the overall quality of the rest of their
software, its unlikely the Frobniz Corp. is going to repair
their reader, so my only other hope is to somehow coerce
Matlab into feeding the Gateway some data it would find more
palatable.

I'm sure this would be handy for other peoples' problems
too.  Is there any workaround for this?  Thanks (and thanks
again for your help on the last go-around too).