Hi everybody.
I have been putting together a PicoGUI frontend for the tuxphone program
(telephony for the TuxScreen) and got tired of debugging PicoGUI apps using
Ethereal. Of course, gdb is great on platforms that support it, but on embedded
systems gdb might not be available. So, it would be nice to be able to peek into
the packets going between client and server.

That's what Traceproxy is for. I just got it into what appears to be a usable
state. It might be useful to others debugging picogui apps, so I thought I'd
post a little intro on it. Traceproxy in its current state is a quite messy Perl
script that requires Perl, Netcat and xxd (a hex dump program). Most linux
distros already include these programs.

Assuming you have a pgserver running on your workstation at display 0, you can run:
  ./traceproxy.pl localhost 1

This will connect to the local pgserver and accept a client on display 1. Now
run a PicoGUI client:

  dialogdemo --pgserver :1

...and watch all the cute little packets fly back and forth. It helps to be a
little familiar with PicoGUI's network protocol, but it's easy to see the
general idea. Packets like 'mkwidget' and 'set' correspond to API functions. The
'wait' and 'ping' packets are used in the event loop. All request and response
headers are decoded, and a few request packets provide extra information. Info
not specifically decoded is output as a hex dump, so it's usually helpful to
have a copy of network.h and constants.h nearby.

Hope this is helpful.


--
Only you can prevent creeping featurism!

_______________________________________________
Pgui-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/pgui-devel

Reply via email to