dkp on device buttons to run power on macro

Support forum for extenders. If you're having trouble getting one up and running, this is the place to come.

Moderator: Moderators

trpltongue
Posts: 34
Joined: Mon Jul 19, 2004 12:39 pm
Location: Houston

dkp on device buttons to run power on macro

Post by trpltongue »

Hey all,

I have a 9910 that I'm trying out the extender on and I'm a bit confused.

I'm trying to setup the device buttons so that a single press will set all the keys for that device and a double press will run the "power on" macro and set all keys for that device.

The default extender uses global macros on each device key that look like this:

DEV_XXX; phantom1
where phantom1 is a global macro to set all keys to the current device

However, I have defined phantom1 at discrete power off in each of my device upgrades, so using phantom1 in a dkp macro simply calls discrete power off for whatever device is active. How can I get around this?

Thanks,

Russell
Capn Trips
Expert
Posts: 3989
Joined: Fri Oct 03, 2003 6:56 am

Post by Capn Trips »

Those global device-selection macros are not required. They are just installed during extender installation as a courtesy to mimic the "normal" unextended functioning of the Device buttons. You can modify, shift, or delete them as you wish.

You can define some OTHER button as your device selection macro, or define some OTHER button as your Discrete OFF so they don't conflict. You can choose anything you want, like "phantom 2", or "x-shift select", or whatever you want. (except I believe we have seen historically that xshift-Phantom 3 doesn't work properly in this extender)

Your challenge will be, of course, that DKP is not a MACRO, but is a device-specific "keymove", so what you have to do to make it accessible in all device modes (as a true macro) is as follows:

Create your Device-Selection macro as described above. For illustration, I'll use phantom 2.

For your DVD player, create a DKP as follows:
Device: DVD
Key: shift-Phantom 1 (your choice)
Single Keys: Phantom 2
Double Keys: Phantom 1, Phantom 2 (insert whatever other Dev_XXX, Discrete ON, Input select sequences you want/need in between) the two.

So now your desired DKP is assigned in the DVD Device mode to shift-Phantom 1. To make it a universal macro, create a two-step macro:
Button: DVD
Commands: DEV_DVD, shift-Phantom 1

Voila, your DVD button will always execute your DVD device selection DKP.
Beginners - Read this thread first
READ BEFORE POSTING or your post will be DELETED!


Remotes: OFA XSight Touch, AR XSight Touch
TVs: LG 65" Smart LED TV; Samsung QN850BF Series - 8K UHD Neo QLED LCD TV
RCVR: Onkyo TX-SR875; Integra DTR 40.3
DVD/VCR: Pioneer DV-400VK (multi-region DVD), Sony BDP-S350 (Blu-ray), Toshiba HD-A3 (HD-DVD), Panasonic AG-W1 (Multi-system VCR);
Laserdisc: Pioneer CLD-D704.
Amazon Firestick
tape deck: Pioneer CT 1380WR (double cassette deck)
(But I still have to get up for my beer)
trpltongue
Posts: 34
Joined: Mon Jul 19, 2004 12:39 pm
Location: Houston

Post by trpltongue »

capn,

I think I get what you're saying, with the extender there is no "device" mode, i.e. I am never in DVD mode so I cannot access any device specific keys.

I am still a bit confused though about your suggested implementation. Will a single press of dvd do "phantom2" and a double press do the turn on macro?

I was in the progress of the following:

DKP:
device: DVD
key: DVD
skp: DEV_DVD; xshift_select (sets keys to currently selected device)
dkp: turn on macro sequence; DVD

However, it seems this won't work because I'm never truly in the "DVD" device mode with the extender so pushing DVD will do nothing. Is that correct?

So I could add a global macro of:
key: DVD
commands: DEV_DVD; DVD

Then pushing DVD once would invoke the DVD skp macro, and a double press would invoke the DVD dkp macro.

I've always been fuzzy on how IR deals with using the device keys in device specific macros.

Russell
johnsfine
Site Admin
Posts: 4766
Joined: Sun Aug 10, 2003 5:00 pm
Location: Bedford, MA
Contact:

Post by johnsfine »

trpltongue wrote:I think I get what you're saying, with the extender there is no "device" mode, i.e. I am never in DVD mode so I cannot access any device specific keys.
No. That's not what he is saying.

What a "device mode" is with the extender is certainly different from what it is without, but the effect of a device mode is still part of the design. You certainly can access device specific keys.

The major point of what I think he was saying is that macros are global and the extender's own command set (DEV_DVD etc.) are global but other ways of defining keys are NOT global.

I assume you want your top level definition of the DVD key to be global, so it must be a macro.

Since you want that macro to do non global things, those things must be in a specific device mode. I assume DVD mode, so your macro on DVD should start with DEV_DVD.

The thing you want on DVD is a DKP. This all would be much simpler for you if DKP's could be global, but they can't (in this extender). So you must define a DKP specifically for and in DVD mode, and the second step of the global macro on the DVD button should be invoking that DKP.
trpltongue wrote: I am still a bit confused though about your suggested implementation. Will a single press of dvd do "phantom2" and a double press do the turn on macro?
If that is what you want, you can do it. But you need all the layers:

1) The global macro on the DVD button that does:
DEV_DVD; shift-Phantom-1

2) The local DKP on shift-Phantom-1 button in DVD mode that does X for single and Y for double (I'm not sure enough about how you're setting things up to say what X and Y should be).

3) Whatever global or DVD mode definitions are needed for any keycodes issued in X or Y.
Capn Trips
Expert
Posts: 3989
Joined: Fri Oct 03, 2003 6:56 am

Post by Capn Trips »

trpltongue wrote:capn,

I think I get what you're saying, with the extender there is no "device" mode, i.e. I am never in DVD mode so I cannot access any device specific keys.

I am still a bit confused though about your suggested implementation. Will a single press of dvd do "phantom2" and a double press do the turn on macro?
Ummm... YES.

Try doing what I spelled out for you. Your way is inefficient (extra instances of Dev-DVD) and confusing (you have BOTH a macro and a DKP function assigned to te DVD button) although it MIGHT work.

Have you read THIS?
Beginners - Read this thread first
READ BEFORE POSTING or your post will be DELETED!


Remotes: OFA XSight Touch, AR XSight Touch
TVs: LG 65" Smart LED TV; Samsung QN850BF Series - 8K UHD Neo QLED LCD TV
RCVR: Onkyo TX-SR875; Integra DTR 40.3
DVD/VCR: Pioneer DV-400VK (multi-region DVD), Sony BDP-S350 (Blu-ray), Toshiba HD-A3 (HD-DVD), Panasonic AG-W1 (Multi-system VCR);
Laserdisc: Pioneer CLD-D704.
Amazon Firestick
tape deck: Pioneer CT 1380WR (double cassette deck)
(But I still have to get up for my beer)
trpltongue
Posts: 34
Joined: Mon Jul 19, 2004 12:39 pm
Location: Houston

Post by trpltongue »

Thanks both,

Yes I have read through the extender FAQ a lot lately :) I also do understand the idea of defining a device mode and the fact that the device keys no longer put you into a particular device mode, instead the device mode must be defined via a macro on the device keys.

I was just unclear as to how the extender handles globally defined macros. The specific example here was the globally defined macro on phantom1. For example, lets assume the following:

global macro
key: phantom1
command: x,y,z

DSM
device: DVD
key:1
command: DEV_DVD; phantom1 (defined in the upgrade as power on)

Assuming you've set the key association to DVD, what happens when you push 1 on device DVD? Does it do the global macro x,y,z or does it do the device "power on" as defined in the upgrade? Along those same lines, what happens if I leave out the DEV_DVD in the command sequence?

I would be happy to read more about this but I can't find answers to these types of questions in the extender readme or in the faq's.

Russell
Capn Trips
Expert
Posts: 3989
Joined: Fri Oct 03, 2003 6:56 am

Post by Capn Trips »

OK, you're asking about the PRIORITY of function assignments when the remote is executing a command.

Short answer, the remote executes in priority order:
Learned commands,
Keymoves,
Macros,
the Basic function assigned in the Setup Code.

When you execute a button (regardless of how it's called - either by pressing the button, or by invoking it via a macro, DSM, LKP or DKP sequence), the remote searches for the following - in order:
(1) Is there a Learned signal for that button for the currently-assigned Device mode for that button? (with the extender this answer is always "NO"). If so it executes the learned command and ignores Keymoves, Macros, and Functions assigned in the Setup code; If the answer is "NO" then
(2) Is there a Keymove assigned to that button for the active Device mode? If so, that gets executed and any Macro or Functions assigned in the Setup code gets ignored.
Important note, Special protocol functions, like DSM, DKP, ToadTogs, etc. are all just fancy Keymoves, and as such will take priority over Macros.
(3) Is there a Macro assigned to the button? If so, it executes the macro; if not
(4) Is there a function assigned to the button in the active setup code? If so, that function gets executed. If not, then nothing happens.
trpltongue wrote: the device mode must be defined via a macro on the device keys.
No it doesn't. The "Device Mode" can be defined by a macro that you assign to ANY key. There is nothing at all unique or special about the Device Keys. They are just regular keys like any other key, just like the UP Arrow, number 7, REC, M3 or even the "SET" key.
trpltongue wrote:I was just unclear as to how the extender handles globally defined macros.
just like the UNextended remote as described above.
trpltongue wrote:The specific example here was the globally defined macro on phantom1. For example, lets assume the following:

global macro
key: phantom1
command: x,y,z

DSM
device: DVD
key:1
command: DEV_DVD; phantom1 (defined in the upgrade as power on)

Assuming you've set the key association to DVD, what happens when you push 1 on device DVD? Does it do the global macro x,y,z or does it do the device "power on" as defined in the upgrade? Along those same lines, what happens if I leave out the DEV_DVD in the command sequence?


As you have written it, it will execute the KEYMOVE of Discrete ON for DVD, since the KEYMOVE takes priority over the MACRO

(another nuance - although you may have "defined" DVD:Phantom 1 as DiscreteON in the "upgrade" in RM, it is really NOT part of the upgrade. It gets imported into IR as (and in fact is) a KEYMOVE, so KEYMOVE processing applies).

If you leave out the "DEV_DVD" then you have two branch scenarios.
(1) If your "Other" keyset (of which Phantom1 is a member) is currently assigned to the DVD device, then it will behave the same as above(KEYMOVE takes precedence over MACRO), but
(2) if your "Other" keyset is assigned to ANOTHER device, AND you have no keymove assigned to Phantom1 in that device mode, then the MACRO will execute.

Is that clear? :eek: :eek:
Beginners - Read this thread first
READ BEFORE POSTING or your post will be DELETED!


Remotes: OFA XSight Touch, AR XSight Touch
TVs: LG 65" Smart LED TV; Samsung QN850BF Series - 8K UHD Neo QLED LCD TV
RCVR: Onkyo TX-SR875; Integra DTR 40.3
DVD/VCR: Pioneer DV-400VK (multi-region DVD), Sony BDP-S350 (Blu-ray), Toshiba HD-A3 (HD-DVD), Panasonic AG-W1 (Multi-system VCR);
Laserdisc: Pioneer CLD-D704.
Amazon Firestick
tape deck: Pioneer CT 1380WR (double cassette deck)
(But I still have to get up for my beer)
johnsfine
Site Admin
Posts: 4766
Joined: Sun Aug 10, 2003 5:00 pm
Location: Bedford, MA
Contact:

Post by johnsfine »

Capn Trips wrote:Short answer, the remote executes in priority order:
Learned commands,
Keymoves,
Macros,
the Basic function assigned in the Setup Code.


That view seems to blur important distinctions between extender and non extender.

I expect you meant extender. But then learned keys wouldn't be in the list at all.

Capn Trips wrote: When you execute a button (regardless of how it's called - either by pressing the button, or by invoking it via a macro,
But if you didn't mean extender, then there is the important rule that macros definitions are ignored for keycodes issued in a macro.

For most extenders (including this one) "regardless of how it's called" is correct.

Regarding the main priority question here, I don't recall whether the relevent IR.exe weakness was ever fixed. It used to be that the "keymove over macro" priority rule in extenders depended on something done by IR.exe that IR.exe didn't always do. So you needed to poke it a bit to make that happen (assuming you had any such overloaded keycodes).
trpltongue
Posts: 34
Joined: Mon Jul 19, 2004 12:39 pm
Location: Houston

Post by trpltongue »

capn and johnsfine,

Thank you all for the clarification! I had a hard time wording the question so I'm glad you were able to understand.

That does go a long way in explaining how things will behave.

The other complicating factor for me is that I am "building" a remote for my parents who live a few states away and use equipment completely different from mine :eek:

I think I've got a good setup in IR now, I'm going to give it a try when I get home. Obviously I can't actually test it, but I'll be watching for any errors etc. Hopefully all will go well :)

Thanks again,

Russell
johnsfine
Site Admin
Posts: 4766
Joined: Sun Aug 10, 2003 5:00 pm
Location: Bedford, MA
Contact:

Post by johnsfine »

You ought to get the CaptureIR hardware and use that for partial testing.

Of course it can't tell you how the real devices will respond to a sequence of signals, but it will tell you what sequence of signals your remote is sending.

Once you start nesting macros inside DKPs inside other macros, odd are you're going to get something wrong on the first try. One extra time shipping the remote back and forth is more trouble and cost that CaptureIR.

With CaptureIR you can see/diagnose any unexpected behaviors from your macros and DKPs.
Capn Trips
Expert
Posts: 3989
Joined: Fri Oct 03, 2003 6:56 am

Post by Capn Trips »

johnsfine wrote:
Capn Trips wrote:Short answer, the remote executes in priority order:
Learned commands,
Keymoves,
Macros,
the Basic function assigned in the Setup Code.


That view seems to blur important distinctions between extender and non extender.
I'm not sure that I agree, unless you're talking about Keymoves/and Macros entered on the keypad of the remote. If you use IR, I'm pretty sure they behave the same way regardless, in that IR saves the keymoves in EEPROM ahead of the Macros.
johnsfine wrote: I expect you meant extender. But then learned keys wouldn't be in the list at all.
Capn Trips wrote: When you execute a button (regardless of how it's called - either by pressing the button, or by invoking it via a macro,
But if you didn't mean extender, then there is the important rule that macros definitions are ignored for keycodes issued in a macro.
Ah, you're right - embedded macros don't work in the unextended remote. But the OTHER priorities remain in that circumstance, right?
johnsfine wrote: For most extenders (including this one) "regardless of how it's called" is correct.

Regarding the main priority question here, I don't recall whether the relevent IR.exe weakness was ever fixed. It used to be that the "keymove over macro" priority rule in extenders depended on something done by IR.exe that IR.exe didn't always do. So you needed to poke it a bit to make that happen (assuming you had any such overloaded keycodes).
Yeah, it used to be that Keymoves and Macros were stored in the EEPROM in the last order in which you entered them in IR, and sometimes one OR the other would take precedence, but I believe it's been about 2 years now that IR ALWAYS re-orders the data such that KEYMOVES are saved before MACROS in the EEPROM. Somebody please correct me if I'm wrong on this one.
Beginners - Read this thread first
READ BEFORE POSTING or your post will be DELETED!


Remotes: OFA XSight Touch, AR XSight Touch
TVs: LG 65" Smart LED TV; Samsung QN850BF Series - 8K UHD Neo QLED LCD TV
RCVR: Onkyo TX-SR875; Integra DTR 40.3
DVD/VCR: Pioneer DV-400VK (multi-region DVD), Sony BDP-S350 (Blu-ray), Toshiba HD-A3 (HD-DVD), Panasonic AG-W1 (Multi-system VCR);
Laserdisc: Pioneer CLD-D704.
Amazon Firestick
tape deck: Pioneer CT 1380WR (double cassette deck)
(But I still have to get up for my beer)
trpltongue
Posts: 34
Joined: Mon Jul 19, 2004 12:39 pm
Location: Houston

Post by trpltongue »

Johnsfine,

I wasn't even aware of the captureIR hardware :oops: I might have to look into that.

When I uploaded the extended file to the remote it complained about the signatures being different. I don't have access to the extender documentation right now (can't access files section for some reason), is this normal behavior? It doesn't seem to be affecting the remote.

I am having an issue with my power keys for each device though. I tried to upload my IR file in the file section but I'm getting a database error and it won't let me upload or even view the diagnosis forum?

Anyhow, I've setup a dkp macro on each of the device power keys:

dkp macro
device: XXX
key: power
skp: shift-L1 (power toggle)
dkp: shift-4 (global macro to turn off all devices)

However, when I hit power on any of my devices, it does the turn off macro for both single and double keypress?

I'm not sure what could be causing this. I'll try to upload my file again tomorrow, maybe I'll have access again.


Thanks,

Russell
Capn Trips
Expert
Posts: 3989
Joined: Fri Oct 03, 2003 6:56 am

Post by Capn Trips »

Well, until the file section is working again and we can look at your IR file, the only suggestion I have is for you to test that the individual strings "SET"-L1" and "SET"-"4" execute what you intend. Then at least you can narrow down whether the problem is with the DKP itself or with one of the included macros.

Do you have a conflicting Global Macro assigned to Power?

(Just a philosophy question. I'm curious why you're using DKP rather than LKP. LKP sems to be the more popular option amongst the regular posters here. I use LKPs extensively myself, but never DKP. I know it's just a matter of taste, but I was wondering what the plusses-minusses were in your estimation)
Beginners - Read this thread first
READ BEFORE POSTING or your post will be DELETED!


Remotes: OFA XSight Touch, AR XSight Touch
TVs: LG 65" Smart LED TV; Samsung QN850BF Series - 8K UHD Neo QLED LCD TV
RCVR: Onkyo TX-SR875; Integra DTR 40.3
DVD/VCR: Pioneer DV-400VK (multi-region DVD), Sony BDP-S350 (Blu-ray), Toshiba HD-A3 (HD-DVD), Panasonic AG-W1 (Multi-system VCR);
Laserdisc: Pioneer CLD-D704.
Amazon Firestick
tape deck: Pioneer CT 1380WR (double cassette deck)
(But I still have to get up for my beer)
johnsfine
Site Admin
Posts: 4766
Joined: Sun Aug 10, 2003 5:00 pm
Location: Bedford, MA
Contact:

Post by johnsfine »

trpltongue wrote:When I uploaded the extended file to the remote it complained about the signatures being different.
Most extenders use a signature intentionally different from the correct signature for that remote in order to have IR.exe find the right RDF file if you download the image back from the remote.

For normal operation the remote doesn't care whether the signature is correct.

IR.exe warns you when the signature is being changed (as you saw when first installing the extender). I doesn't know or care which signature is "correct". Other than .wav files, pretty much nothing actually cares whether the signature is correct.
trpltongue
Posts: 34
Joined: Mon Jul 19, 2004 12:39 pm
Location: Houston

Post by trpltongue »

Capn,

No particular reason that I chose dkp instead of lkp. I guess dkp just felt more natural, sort of like a mouse double click as oppossed to a single click. Although I am finding it a bit finicky in that I tend to press the button too quickly, similar to a mouse double click. I may go in and change them after my dad has used the remote for a while.

johnsfine,

Thanks for the info on the extender signature. I assumed it was normal behavior but I just wasn't sure.

As far as the problem I was having, I think I figured out what was going on. I didn't have anything defined on the shift-L1 key for any of my devices. I just used that as a temporary place holder until I figured out which button I REALLY wanted to assign the power toggle to. My assumption then, is that in a dkp keymove, if there is nothing defined on the skp, then it does the dkp by default?

I temporarily assigned the power toggle to shift-L1 for the tv and the dkp macro worked perfectly.

I am still strugling with the pause command though. I've done some reading and apparently the 8910 and 9910 have difficulty with the pause special protocol in that they are entirely too fast. There was mention of using the KM or RM pause protocol instead, but I can't find either of those. Where should I be looking?

Thanks again guys, you've been great help!

Russell
Post Reply