[Attachment(s) from John Ackermann N8UR included below]

Attached is a patch file that updates Max's terminal.py and trunking.py
in a few ways:

1. terminal.py reads the window size at startup and adjusts the curses
settings accordingly. If you set xterm or equivalent to more rows (I'm
using 38), you can handle sites with more than 20 frequencies without
crashing. This is the patch I posted a week or so ago. (Max, I think
your idea of making the main window two columns is still a good one, and
the space that frees up could be used to display other interesting info.
I don't think I'll have the time to learn how to implement that, though.)

2. terminal.py now displays an info line at the bottom of the screen
showing the keyboard commands that are available. I also added a blank
line or two to make the display look (IMHO) a bit cleaner.

3. If you set -v to 5 or higher, every frequency or talkgroup command
is output on stderr (this will generate a lot of output on a busy
system!). If you want to generate a list of every unique frequency used
by the system, this will produce it from the stderr.2 file:

grep freq: stderr.2 | cut -d" " -f3 | sort | uniq

or to get all the unique talkgroups:

greg freq: stderr.2 | cut -d" " -f5 | sort | uniq

Max, this was actually a bit less trivial than first thought. The code
is easy, but where to put it wasn't. Your suggestion about the end of
update_state() led to only one update per second, and lost many
freq/talkgroup set commands. I think I found a spot that doesn't miss
any. Lots of output, but lets you build a comprehensive tgid list.

4. The stderr output of "set trunk_cc..." was not all that useful, so
it's now set to appear only when the -v level is set to 6 or greater.
(Behavior of -v 10 includes the above but is otherwise unchanged.)

5. I cleaned up all the logging/status/debug outputs in trunking.py to
use "sys.stderr.write()" rather than "print". That will stop them from
showing up in the terminal screen. While I was at it, I also added
newlines to the end of all output and did some other cleanup.

Hope this is useful.

73,
John

__._,_.___

Attachment(s) from John Ackermann N8UR | View attachments on the web

1 of 1 File(s)


Posted by: John Ackermann N8UR <jra@febo.com>
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___