Re: [LHA-misc] Line parsing routine
Status: Beta
Brought to you by:
ncherry
From: Neil C. <nc...@ho...> - 2000-11-30 01:20:59
|
Paul Fox wrote: Pardon the delayed response, I'm bouncing as usual. :-) > > I wonder can we drop the addr= and value= ? If they're always in the > > same position we can drop them. But if the addr= can be replaced with > > something else then we'll need them (is this too short sighted?). Also > > while it _can_ be typed by a user, i don't see this command set as > being something anyone would _want_ to type. given that there will > probably always be some sort of UI in front of this, then requiring > the addr= and value= keywords is probably the right thing to do. the > ambiguity you'll eliminate if you someday, say, decide to add "name=...", > will make it worth it. Actually the Agent (daemon) is not meant to be interfaced by the end user. They're supposed to interface to the server, the Agent is supposed to handle the communication between the servers and the device (many to one). The reason for the ASCII interface and the commands are so the programmer has an easier time of debugging. Having structured commands (and int a certain order) should be an added burden to the programmer. > > we've planed for. Also can we have more than 1 value? Say we d/l some > > code to the Ocelot, we can first send the size of the file (make > > reserving memory easier) then the actual file, which can we a stream > > of 8 bit characters (no null or <CR> to worry about or escape). > > this is a good idea. but don't require sending the size of the file > first. or at least make it device-specific. it's hard to do > on-the-fly compression if you need to know the final size up front. Why would we need to do on the fly compression? Please don't take this as a negative comment. I do not see a reason for it, it could be stored commpressed (which in my opinion would be better). -- Linux Home Automation Neil Cherry nc...@ho... http://members.home.net/ncherry (Text only) http://meltingpot.fortunecity.com/lightsey/52 (Graphics) http://linuxha.sourceforge.net/ (SourceForge) |