Searching \ for '[EE] Send browser requests out COMM port?' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/ios.htm?key=port
Search entire site for: 'Send browser requests out COMM port?'.

Exact match. Not showing close matches.
PICList Thread
'[EE] Send browser requests out COMM port?'
2008\01\09@120949 by Harold Hallikainen

face
flavicon
face
I'm working on a PIC application where I've made a SIMPLE web server that
interfaces to an 802.11 radio that is listening on port 80. A web browser
opens a connection to port 80, sends a request, and my PIC code responds
appropriately.

I'm interested in doing the same thing over a COMM port (FT245RQ on the
PIC side, and virtual comm port on the PC side). I'd like to put something
like this:

http://localhost:1234

in the URL field of the browser and have the GET request go through the
virtual comm port, through the FT245RQ to my PIC.

Our Windows guy suggests using SLIP, but this looks much more complex than
needed. Why encapsulate the data in TCP/IP packets for the short ride over
the USB cable, just to take them apart again.

Does any Windows application exist that would redirect an IP port on
localhost to a comm port?


THANKS!

Harold




--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\09@121850 by Steven Howes

flavicon
face
> Our Windows guy suggests using SLIP, but this looks much more  
> complex than
> needed. Why encapsulate the data in TCP/IP packets for the short  
> ride over
> the USB cable, just to take them apart again.

Have you actually read about the encapsulation.. i think its only a  
byte or two. Its as good as you are going to get!

2008\01\09@130124 by Charles Craft

picon face
Googled "tcp/ip rs232 proxy"

http://www.taltech.com/products/tcpcom.html



-----Original Message-----
{Quote hidden}

>-

2008\01\09@131617 by Matthew Mucker

flavicon
face
Use the Direct Cable Connection built into Windows.

Control Panel
Network Connections
Add New Connection Wizard
Advanced Connection
Connect Directly To Another Computer

You can create a PPP or a SLIP connection.

It's built into Windows; probably less work to implement SLIP than to find
another solution.


{Original Message removed}

2008\01\09@132009 by Harold Hallikainen

face
flavicon
face

>> Our Windows guy suggests using SLIP, but this looks much more
>> complex than
>> needed. Why encapsulate the data in TCP/IP packets for the short
>> ride over
>> the USB cable, just to take them apart again.
>
> Have you actually read about the encapsulation.. i think its only a
> byte or two. Its as good as you are going to get!

The SLIP encapsulation doesn't look too bad, but, as I understand it, it
encapsulates TCP/IP packets, not my raw ascii. So, I need a TCP/IP stack,
then encapsulate to SLIP, all just to get ascii from here to there....

I HAVE found these products that might be useful... I was wondering if
anyone had actually used anything like this, or would like to talk me out
of it!

THANKS!

Harold



--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\09@134132 by Harold Hallikainen

face
flavicon
face
I just found net2com on sourceforge. I'll give it a try.

THANKS!

Harold



> Googled "tcp/ip rs232 proxy"
>
> http://www.taltech.com/products/tcpcom.html
>
>
>
> {Original Message removed}

2008\01\09@134441 by William \Chops\ Westfield

face picon face

On Jan 9, 2008, at 9:09 AM, Harold Hallikainen wrote:

> Our Windows guy suggests using SLIP, but this looks much more  
> complex than
> needed. Why encapsulate the data in TCP/IP packets for the short  
> ride over
> the USB cable, just to take them apart again.

So you just want to run HTTP over serial, with no TCP or IP involved  
at all?  I don't know of anything that does that, although I've  
contemplated similar things for SMTP.  In the general case it won't  
work since there's no multiplexing capability on the serial line.

BillW

2008\01\09@135752 by Mark Rages

face picon face
On 1/9/08, Harold Hallikainen <haroldspamKILLspamhallikainen.org> wrote:
{Quote hidden}

Such a program would be a dozen lines of Python.  Don't pay money for it.

Regards,
Mark
markrages@gmail
--
Mark Rages, Engineer
Midwest Telecine LLC
.....markragesKILLspamspam.....midwesttelecine.com

2008\01\09@140514 by M. Adam Davis

face picon face
Should be nearly trivial to make with Visual Basic Express (free).

Add the MSCOMM control and theTCP/IP control.

Set up the com port and open it.
Set up the TCP/IP port for listening.

On connection, tunnel the data.

On disconnection reset the TCP/IP listening port and wait again.

I'm not in a position to create it right now for you, but it seems a
general enough need that I might do so later this week and put it on
my website.

In fact, dredging up very old website material, it would be the
marriage of these two programs:

Gateway:
www.ubasics.com/adam/computers/index.shtml
http://www.ubasics.com/adam/computers/source/gwsource.zip

Simple serial port:
www.ubasics.com/adam/electronics/ha/software/software.shtml
http://www.ubasics.com/adam/electronics/ha/software/bcsource.zip

Of course it could probably just as easily be made in any of the other
visual studio express products for free, not to mention a variety of
other languages (python, PHP, Java, etc).

-Adam

On 1/9/08, Harold Hallikainen <EraseMEharoldspam_OUTspamTakeThisOuThallikainen.org> wrote:
{Quote hidden}

> -

2008\01\09@145927 by Harold Hallikainen

face
flavicon
face

>
> On Jan 9, 2008, at 9:09 AM, Harold Hallikainen wrote:
>
>> Our Windows guy suggests using SLIP, but this looks much more
>> complex than
>> needed. Why encapsulate the data in TCP/IP packets for the short
>> ride over
>> the USB cable, just to take them apart again.
>
> So you just want to run HTTP over serial, with no TCP or IP involved
> at all?  I don't know of anything that does that, although I've
> contemplated similar things for SMTP.  In the general case it won't
> work since there's no multiplexing capability on the serial line.
>
> BillW

I'm only talking to one device on that com port, so I don't see where
multiplexing would be required. The browser sends a GET request that the
PIC gets and responds to.

THANKS!

Harold

--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\09@154745 by Matthew Mucker

flavicon
face
Typically, a browser will send multiple overlapped GET requests for
resources (pictures) on the same page.

{Original Message removed}

2008\01\09@160326 by Harold Hallikainen

face
flavicon
face

> Typically, a browser will send multiple overlapped GET requests for
> resources (pictures) on the same page.
>

Good point! I guess the browser sends each request out a different port
and the server responds back to that port, allowing the browser to sort
stuff out. I'm just sending a single html page in response to a GET
request. I pass the HTML as a string into this:

void SendWebPage(char *string){
// Send HTTP headers, then send string.
fprintf(pradio,"HTTP/1.0 200 OK\r\nContent-type:
text/html\r\nContent-Length: %d\r\n\r\n",strlen(string)); // send header
fprintf(pradio,"%s",string);   // send page
fflush(pradio);    // flush the buffer
}


If the browser keeps the connection alive, does it just keep several
alive, then reuse them after the server responds?

It LOOKS like my approach will work as long as an HTML page does not
"call" another as it is rendered.

THANKS for the ideas!

Harold


--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\09@162514 by Mark Rages

face picon face
On Jan 9, 2008 3:02 PM, Harold Hallikainen <haroldspamspam_OUThallikainen.org> wrote:
{Quote hidden}

Whatever code you use to translate the TCP port into serial port will
have to deal with this.  By refusing connections while the port is
busy, for example.

--
Mark Rages, Engineer
Midwest Telecine LLC
@spam@markragesKILLspamspammidwesttelecine.com

2008\01\09@163317 by peter green

flavicon
face

> So you just want to run HTTP over serial, with no TCP or IP involved  
> at all?  I don't know of anything that does that, although I've  
> contemplated similar things for SMTP.  In the general case it won't  
> work since there's no multiplexing capability on the serial line.
>  

So you will either have to roll your own multiplexing or have the PC
side software queue requests. Neither is particularlly hard and both are
much simpler both from the point of view of code on the pic and from the
point of view of setup by the user than running full slip or ppp down
the line.


2008\01\09@164138 by M. Adam Davis

face picon face
Browsers know how to deal with servers that only accept one connection
from a single client at a time.  Refuse any connections you don't want
to make.

There may be something in the HTTP protocol for this as well.  I'm
only aware of the keep-alive setting at the moment (it's nice when
writing a data logger that sends data to a webpage (php) which then
stores it in a database - no need to reconnect the session every few
seconds)

-Adam

On 1/9/08, Matthew Mucker <KILLspammatthewKILLspamspammucker.net> wrote:
> Typically, a browser will send multiple overlapped GET requests for
> resources (pictures) on the same page.
>
> {Original Message removed}

2008\01\09@182317 by Harold Hallikainen

face
flavicon
face
I've done a proof of concept test of this with SRedirect from Eternity
Software. Since I know NOTHING about programming for Windows, it'd be
WONDERFUL if someone could create an exe that could be run from the
command line. Something like:

redirect 2 4040

to redirect com2 to port 4040. It would just listen to the port, pass any
data in both directions when a connection is made, and go back to
listening when the connection is dropped.

THANKS!

Harold



--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\09@222240 by Harold Hallikainen

face
flavicon
face
Following up on this... My application needs to update a screen of data
about once a second. Right now, I'm using the http refresh meta tag. This
works, but looks pretty bad, since the entire page is rewritten each
second. I suspect there's some javascript method of updating the table
without redrawing the page. But, I know almost nothing about javascript.
Is what I'm proposing possible? If so, how?

THANKS!

Harold


--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\09@222825 by M. Adam Davis

face picon face
Poking around arduino site, found this:
http://www.arduino.cc/playground/Interfacing/SerialNet

Looks like one of those ought to do for you.

-Adam

On Jan 9, 2008 6:22 PM, Harold Hallikainen <RemoveMEharoldTakeThisOuTspamhallikainen.org> wrote:
{Quote hidden}

> -

2008\01\10@003805 by Nate Duehr

face
flavicon
face

On Jan 9, 2008, at 11:43 AM, William Chops Westfield wrote:

> So you just want to run HTTP over serial, with no TCP or IP involved
> at all?  I don't know of anything that does that, although I've
> contemplated similar things for SMTP.  In the general case it won't
> work since there's no multiplexing capability on the serial line.

Those with no memory of the past are doomed to repeat it?  :-)

http://en.wikipedia.org/wiki/UUCP

http://www.kew.com/kendra/uupc/  - Some Googled windows version, or  
Cygwin works.

Even Microsoft distributed UUCP as part of their Windows NT Server  
Resource Kit CD, many moons ago.

Seems right for the job.  Why not UUCP instead of all the unnecessary  
overhead of HTTP?

--
Nate Duehr
spamBeGonenatespamBeGonespamnatetech.com



2008\01\10@055835 by Gerhard Fiedler

picon face
Harold Hallikainen wrote:

> Following up on this... My application needs to update a screen of data
> about once a second. Right now, I'm using the http refresh meta tag. This
> works, but looks pretty bad, since the entire page is rewritten each
> second. I suspect there's some javascript method of updating the table
> without redrawing the page. But, I know almost nothing about javascript.
> Is what I'm proposing possible? If so, how?

It is possible. Basically, the original page contains a JavaScript timer
that fires in intervals. From there, you have different possibilities.

One is to use frames (which may have individual URLs) and the JavaScript
just tells the frame(s) to refresh itself.

Another is a bit more complex but more targeted. The JavaScript runs a GET
request to the server and receives the data, reads the contents, extracts
what is needed. Then it simply replaces the data of the elements on the
page with the received data; every element is accessible through the DOM
(document object model).

I'm sure you can dig up code snippets that do exactly that on the many
sites for web programming.

Gerhard

2008\01\10@062051 by Dario Greggio

face picon face
Harold Hallikainen wrote:

> Following up on this... My application needs to update a screen of data
> about once a second. Right now, I'm using the http refresh meta tag. This
> works, but looks pretty bad, since the entire page is rewritten each
> second. I suspect there's some javascript method of updating the table
> without redrawing the page. But, I know almost nothing about javascript.

Yeah, AJAX is almost the State-Of-The-Art today - essentially,
JavaScript made smart.

LAtest Microchip TCPIP Stack does make use of that, you can take a look.

--
Ciao, Dario

2008\01\10@082000 by Harold Hallikainen

face
flavicon
face

{Quote hidden}

Thanks for the comments! My goal here is to use a browser interface (that
I'm already doing for an 802.11 radio module) for a local USB connection.
That way I could put http://localhost:1234 or some other port number into
the "address bar" of a browser and talk to the device. Could I do that
with UUCP? The browser itself is generating the http requests and
interpreting them, I believe, so it doesn't SEEM UUCP gets around that.
HTTP looks pretty simple (and I have it working).

THANKS!

Harold



--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\10@152234 by Chris Loper

flavicon
face
> ... My application needs to update a screen of data about once a second. Right now, I'm using the http refresh meta tag.

AJAX sounds complex, but is almost trivial to implement. See:
  http://www.w3schools.com/ajax/default.asp
(w3schools has good tutorials on most everything involved in WEB programming.)






2008\01\14@173113 by Harold Hallikainen

face
flavicon
face
M. Adam Davis wrote:
> Should be nearly trivial to make with Visual Basic Express (free).
>
> Add the MSCOMM control and theTCP/IP control.
>
> Set up the com port and open it.
> Set up the TCP/IP port for listening.
>
> On connection, tunnel the data.
>
> On disconnection reset the TCP/IP listening port and wait again.
>
> I'm not in a position to create it right now for you, but it seems a
> general enough need that I might do so later this week and put it on
> my website.
>

Any chance you had time to put something like this together?

Harold


--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\16@074332 by Alex Le Dain

flavicon
face
Harold Hallikainen-2 wrote:
> >
> > I've done a proof of concept test of this with SRedirect from Eternity
> > Software. Since I know NOTHING about programming for Windows, it'd be
> > WONDERFUL if someone could create an exe that could be run from the
> > command line. Something like:
> >
> > redirect 2 4040
> >
> > to redirect com2 to port 4040. It would just listen to the port,
pass any
> > data in both directions when a connection is made, and go back to
> > listening when the connection is dropped.
> >

Hi Harold,

I am the author of SRedirect. Does SRedirect do the job for you or can
you tell me a bit more about how SRedirect fails to listen to your
browser connection requests or falis to pass the data correctly?

cheers, Alex.

2008\01\16@100010 by M. Adam Davis

face picon face
I don't know Harold's application, but if it's a product to be sold to
others then even if you gave him a discount it eats into profits to a
degree that will be unacceptable for most products.

Harold,

I haven't had time to look at it.  Perhaps tonight, but I can make no promises.

-Adam

On 1/16/08, Alex Le Dain <TakeThisOuTaledainEraseMEspamspam_OUTeternitysoftware.com> wrote:
{Quote hidden}

> -

2008\01\16@105840 by Harold Hallikainen

face
flavicon
face

> I don't know Harold's application, but if it's a product to be sold to
> others then even if you gave him a discount it eats into profits to a
> degree that will be unacceptable for most products.
>
> Harold,
>
> I haven't had time to look at it.  Perhaps tonight, but I can make no
> promises.
>
> -Adam

Thanks! Another application I've been using for testing is Ponticulus . It
shuts down after the browser loads the page, but I've, for now, stuck it
in a loop in a batch file. That seems to work ok, but occasionally the
browser says "the site is too busy." That happens if I click a link while
the page is reloading (right now I'm using the refresh meta tag). I have
not seen that happen with sRedirect. Maybe the browser does that when
Ponticulus is restarting.

Yes, this is for a product, and cost is a major concern. At this point,
I'm just experimenting with user interfaces. There is an 802.11 radio
module, and USB. I thought a simple web interface could be shared between
the two. It DOES appear to be working, though it is not as pretty as a
custom Windows interface. I'll have to see what the higher ups think. I
like the web interface because it's universal. If someone has a laptop
with an 802.11 radio, no software is needed. It just works (though they
have to set up the networking, which will generally be ad hoc). With the
usb interface, they can just plug it in and type "localhost:4040" in the
browser url bar (right now I'm using port 4040), and up it comes!

Thanks to all for the comments!

Harold




--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\17@011555 by andrew

picon face
Harold Hallikainen wrote:
{Quote hidden}

does Sredird help/give options?
"RFC 2217 compliant Telnet serial port redirector
Sredird is a serial port redirector that is compliant with the RFC 2217
"Telnet Com Port Control Option" protocol. This protocol lets you share a
serial port through the network."
<http://freshmeat.net/projects/sredird/>
<http://www.penguin-soft.com/penguin/man/8/sredird.html>


Andrew Burchill


2008\01\17@111525 by Harold Hallikainen

face
flavicon
face

> does Sredird help/give options?
> "RFC 2217 compliant Telnet serial port redirector
> Sredird is a serial port redirector that is compliant with the RFC 2217
> "Telnet Com Port Control Option" protocol. This protocol lets you share a
> serial port through the network."
> <http://freshmeat.net/projects/sredird/>
> <http://www.penguin-soft.com/penguin/man/8/sredird.html>
>
>
> Andrew Burchill

Looks good, but most of our clients are running Windows and Sredird runs
under Linux.

THANKS!

Harold



--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\17@171929 by Jared Sanson

flavicon
face



>> does Sredird help/give options?
>> "RFC 2217 compliant Telnet serial port redirector
>> Sredird is a serial port redirector that is compliant with the RFC
2217
>> "Telnet Com Port Control Option" protocol. This protocol lets you
share a
>> serial port through the network."
>> <http://freshmeat.net/projects/sredird/>
>> <www.penguin-soft.com/penguin/man/8/sredird.html>
>>
>>
>> Andrew Burchill

>Looks good, but most of our clients are running Windows and Sredird
runs
>under Linux.

How about a quick google of
www.google.co.nz/search?hl=en&q=windows+%22Telnet+Com+Port%22&btn
G=Google+Search&meta=
(Windows "Telnet Com Port")
optionally you can add free or freeware to the keywords
and -shareware -buy as well to make sure it's free!



--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

2008\01\17@181653 by Alex Le Dain

flavicon
face


Harold Hallikainen-2 wrote:
>
> I've done a proof of concept test of this with SRedirect from Eternity
> Software. Since I know NOTHING about programming for Windows, it'd be
> WONDERFUL if someone could create an exe that could be run from the
> command line. Something like:
>
> redirect 2 4040
>
> to redirect com2 to port 4040. It would just listen to the port, pass any
> data in both directions when a connection is made, and go back to
> listening when the connection is dropped.
>

Hi Harold,

I am the author of SRedirect. I am glad SRedirect does the job for you and
it is a low cost solution :)

cheers, Alex.
http://www.eternitysoftware.com
--
View this message in context: www.nabble.com/Send-browser-requests-out-COMM-port--tp14717073p14878815.html
Sent from the PIC - [EE] mailing list archive at Nabble.com.

2008\01\17@185404 by Dr Skip

picon face
I found this while rummaging around the net. Sounds just like what you wanted:

http://www.billproduction.com/


-Skip

2008\01\18@185400 by Alex Le Dain

flavicon
face
"M. Adam Davis" wrote:

> I don't know Harold's application, but if it's a product to be sold to
> others then even if you gave him a discount it eats into profits to a
> degree that will be unacceptable for most products.

Perhaps. But developing even a simple app like SRedirect takes time and
money to make it robust (exception handling, testing etc). I think it
will depend on the final unit cost of the product plus the "angle" at
which that product is trying to enter the market. If the product is
trying to beat everyone on price then yes, adding a small amount to the
total cost may be prohibitive.

OTOH if the product is beating the others on functionality, a small (and
we're talking < $10 here) per unit may not be an issue, it can be added
to the price.

Lastly, developing something "in-house" or spending 30 hours searching
the net for a "free" solution costs money too :) If an engineer costs
$50 to run, 30 x $50 = $1500, so we could have bought at least 150
copies of the product!

<shamelss plug>Lastly, SRedirect is really cheap because it's really
simple software :)</shameless plug>

cheers, Alex.

2008\01\18@190339 by Harold Hallikainen

face
flavicon
face

{Quote hidden}

Thanks Alex! I'll keep this in mind as the product gets closer to
completion. I like the browser through serial port (I'm using an FTDI USB
chip, so it's actually browser to USB) approach to user interface, but
we'll see how the rest of the people here like it.

Harold

--
FCC Rules Updated Daily at http://www.hallikainen.com - Advertising
opportunities available!

More... (looser matching)
- Last day of these posts
- In 2008 , 2009 only
- Today
- New search...