[WT-support] Script for getting next call in Bandmap
Oliver Grossmann
oliver.grossmann at bretzi.de
Sat Nov 20 10:21:05 CET 2010
Hello Bob,
this script works great. But I for me the 2nd line is reading from the
radio.
What do you mean by
"You cannot write a Lua script to read a response from the radio"?
I'm new to LUA, i'm more in C and C++, but i will read the LUA manual to
get a better understanding.
I will change the script so it is working either with VFO A and VFO B.
thanks Olli
------------------------------------------------------------------------
Oliver Grossmann | DH2WQ | oliver.grossmann at bretzi.de
On 20.11.2010 02:55, Bob Wilson, N6TV wrote:
> Olli,
>
> You cannot write a Lua script to read a response from the radio. You
> can issue an "IF;" command to the K3, but you cannot read the results.
>
> Maybe the problem is that once you switch VFO B, the frequency in the
> band map changes, so Ctrl-Up is going to start from a new place.
>
> One approach that may work better than swapping VFOs is to :
>
> -- Save current VFO A frequency
> local VFOAfreq = wtRadio:GetFreq(WT_RADIO_VFOA)
>
> -- Press Ctrl-Up to move VFO A to new freq
> wtApp:SendKeyCode(294, WT_KEY_CTRL)
>
> -- Set VFO B freq to current VFO A freq
> wtRadio:SetFreqSubVfo( wtRadio:GetFreq(WT_RADIO_VFOA) )
>
> -- Restore original VFO A freq
> wtRadio:SetFreq(VFOAfreq, WT_RADIO_VFOA)
>
> -- No further keystrokes
> return -1
>
> You may have to add a wtApp:Sleep(100) to allow the radio to switch
> frequencies.
>
> On a K3 you could issue a command to do A->B directly (SWT13;).
>
> I have not tested it, please report results.
>
> 73,
> Bob, N6TV
>
> On Fri, Nov 19, 2010 at 5:18 PM, Oliver Grossmann
> <oliver.grossmann at bretzi.de <mailto:oliver.grossmann at bretzi.de>> wrote:
>
> Hello,
> I tried some stuff, but nothing seems to work. The cat command for
> the TRX works just fine for switching.
> The problem seems to be in time gap between setting TRX to 2nd VFO
> and WinTest getting confirmation of switching VFO from the radio.
>
> If I'm placing a wtApp:Sleep(n) the Programm will do nothing in
> this time, even not checking if TRX status has changed.
>
> I think i will try to get the status from the TS-850 by
> interpreting the return value of the IF command, or implement an
> delay from system time without stopping the WinTest Application.
>
> If someone has anymore hints i will be looking for this.
>
> Olli
>
> ------------------------------------------------------------------------
> Oliver Grossmann | DH2WQ | oliver.grossmann at bretzi.de
> <mailto:oliver.grossmann at bretzi.de>
>
> On 19.11.2010 20:00, Laurent HAAS - F6FVY wrote:
>> Hi
>>
>> Le 19/11/2010 19:44, Bob Wilson, N6TV a écrit :
>>
>>
>>> If I could figure out how to send up arrow and down arrow commands (key
>>> code?) from Lua
>>>
>> Try
>>
>> wtApp:SendKeyCode(294. 4) for the Ctrl-Up key
>> wtApp:SendKeyCode(296, 4) for the Ctrl-Down key
>>
>> Not deeply tested.
>>
>> 73
>>
>> Larry - F6FVY
>> _______________________________________________
>> Support mailing list
>> Support at win-test.com <mailto:Support at win-test.com>
>> http://www.f5mzn.org/cgi-bin/mailman/listinfo/support
>>
>
> _______________________________________________
> Support mailing list
> Support at win-test.com <mailto:Support at win-test.com>
> http://www.f5mzn.org/cgi-bin/mailman/listinfo/support
>
>
>
> _______________________________________________
> Support mailing list
> Support at win-test.com
> http://www.f5mzn.org/cgi-bin/mailman/listinfo/support
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.f5mzn.org/pipermail/support/attachments/20101120/55a1ace5/attachment.htm
More information about the Support
mailing list