JP1 Remotes Forum Index JP1 Remotes


FAQFAQ SearchSearch 7 days of topics7 Days MemberlistMemberlist UsergroupsUsergroups RegisterRegister
ProfileProfile Log in to check your private messagesLog in to check your private messages Log inLog in

Programming OARUSB04G

 
Post new topic   Reply to topic    JP1 Remotes Forum Index -> JP1 - Beginners
View previous topic :: View next topic  
Author Message
manno



Joined: 27 Jan 2015
Posts: 9

                    
PostPosted: Wed Jan 28, 2015 12:28 am    Post subject: Programming OARUSB04G Reply with quote

Hello,

I'm a newbie here and love the idea of programming remotes to do what I need. After searching and reading quite a bit, I need a little help.

I just bought a OFA OARUSB04G and wanting to program it. Here's my situation, I have two devices - a TV and a openelec media box. Obviously I want the TV to be controlled by the "TV" button and the media box from the "STB" button. The catch is that the media box remote sends codes that will control the TV, not by design. For example, I press "Setup" on the media box remote and it will turn down the volume on my TV. This happens with about a dozen buttons on the remote with no way to fix it. I have the ability to remap remote codes on the media box though.

So my thought is that I can have the OFA remote learn the TV remote and then setup custom codes for the media box that are out of range from the TV codes and program those into the OFA.

I'm using RMIR to open the settings.bin file from my remote so that I can see how things work. I'm confused on how to setup multiple devices and write that back to the settings.bin file.

Also, the media box has a remote code layout like this:

# ZAP-A10 NEC remote
factory_code = 0xfe010001
work_mode = 1
repeat_enable = 1
release_delay = 150
debug_enable = 1
reg_control = 0xfbe40

key_begin
0x03 63 ;SEARCH^M
0x43 62 ;SETUP^M
0x44 30 ;AUDIO^M
0x06 20 ;SUBTITLE^M
0x0f 24 ;ANDROIDO^M
key_end

I'm not sure how to convert this into the hex cmd that RMIR or RM needs.

If I can set this:
0x43 62 ;SETUP^M
to something like this:
0x91 62 ;SETUP^M
and then write:
Setup 0x91 etc...
to settings.bin, I think this may work...

I appreciate any help given!
Back to top
View user's profile Send private message
3FG
Expert


Joined: 19 May 2009
Posts: 3367

                    
PostPosted: Wed Jan 28, 2015 11:29 pm    Post subject: Reply with quote

I would approach this by
1) Get the OARUSB04G to completely control your TV. It looks like it uses NEC1 device 1.
2) Choose a different device number--say 5 but still using NEC1, because the media center will probably learn that easily. Make a device upgrade, setting the OBCs of the various functions of the openelec to 0,1,2,3.. (or any other numbers you like)

For 1) I'd first try to see if one of the built in TV setup codes will work. The candidates are 0885, 1282, 3065, 3470, and 3560. Use the instructions on page 3 of the manual. If none of the setup codes fully work, learn any non-working buttons into the '04G, and use RMIR to download from the remote. Of course, if none work, you should learn the all of the TV codes and convert them to an upgrade. Two things to do: On the Options/Advanced menu, select Learned To Upgrade Conversion. RMIR will remember this setting in subsequent sessions. After learning and downloading from the '04G, click Create Missing Upgrades. Next, look at the Learned Signals tab which should show the decodes of all your learned signals. Presumably these will be NEC1 device 1. Select all the learns (delete any which haven't decoded correctly) and click Convert to Device Upgrade. If for some reason the automatic conversion doesn't work, use the following instructions, substituting the decoded device number, and filling in the decoded OBCs.

For 2) on the Devices tab, click New, select NEC1, device 5 (leave subdevice blank), switch to the Functions tab and enter OBCs of your choosing to whatever buttons you wish to use to control the openelec. Don't forget to go to the Buttons or Layout tab and assign all the functions to buttons! It isn't necessary to use NEC1 here or device 5-- anything except NEC1 device 1 will work. Sometimes people just use some other built in setup code, which is fine as long as it sends a signal on all of the buttons you intend to use.
Back to top
View user's profile Send private message
manno



Joined: 27 Jan 2015
Posts: 9

                    
PostPosted: Thu Jan 29, 2015 10:36 pm    Post subject: Reply with quote

Thanks for the info here! Very valuable!

Here's what I have so far...

I attempted to learn the TV and STB remotes to get all of the data. I notice that there is a mix of NEC1 and NEC2 protocols. Each remote has about half NEC1 and half NEC2. Why is this?

So what I did was select the TV learned data that was NEC1 and "Convert to Device Upgrade." I then did the same for the other half ov the TV data that was NEC2. So now I have two entries under the Device tab (since I can't seem to combine the protocols):

TV 2002 005A NEC1
TV 2003 005A NEC2

I did the same with the STB (media box) and came up with another two similar entries under the device tab.

CABLE 2000 005A NEC1
CABLE 2001 005A NEC2

These CABLE entries have a device value of 5 while the TV has 1.

At this point, I was able to edit the hex cmd values for the STB (under the device tab) so that they will not conflict with the TV remote. I need to be able to edit the STB values since I can't change the TV codes but can change the STB codes on the media box itself.

Under the General tab, the setup codes are:

TV 3758
STB 1877

How do I upload all of this data to the remote correctly? Don't all of the setup codes need to be the same and match the particular devices? Don't I need to combine the NEC1 and NEC2 protocols per device so that it uploads correctly? I'm still working on how all this functions Smile

Thanks for the help!
Back to top
View user's profile Send private message
mdavej
Expert


Joined: 08 Oct 2003
Posts: 4501

                    
PostPosted: Thu Jan 29, 2015 11:05 pm    Post subject: Reply with quote

Start a new device upgrade file and pick "NEC 1or2 Combo" protocol, enter 1 in the Device box. Paste in your OBC codes and function names on the functions tab and pick NEC1 or NEC2 as appropriate for each in the Style column. This combines both into one device. Setup code is arbitrary. Pick any number you like. Repeat the procedure for your other device using 5 (or whatever you decided to use) in the Device box.
Back to top
View user's profile Send private message
manno



Joined: 27 Jan 2015
Posts: 9

                    
PostPosted: Thu Jan 29, 2015 11:55 pm    Post subject: Reply with quote

Thanks! I'm attempting to make this happen...

One major issue, the RM GUI is freaking out, every time I try to copy the functions from RMIR and paste into the new RM Device Upgrade, the RM GUI kinda crashes where I can't see what I just pasted and leaves everything highlighted. I can get some of the data to show by double-clicking on each cell. Do you know why this is happening? I'll try on another machine to see if I get the same response...
Back to top
View user's profile Send private message
3FG
Expert


Joined: 19 May 2009
Posts: 3367

                    
PostPosted: Fri Jan 30, 2015 12:04 am    Post subject: Reply with quote

First, the difference between NEC1 and NEC2 is in the way IR signals are repeated. NEC1 will send the frame containing device and OBC once. If the button is held down, the remote will send "dittos" to indicate to your component that the NEC1 signal is being repeated. The ditto has the same duration as the main signal, but is just a couple of on pulses. The idea here is to save batteries. If the user wants to set the TV channel to 333, the 3 button should be pressed and released 3 times. The TV won't think treat any dittos (caused by holding the button for a while) to mean that the 3 should be repeated. This is great for entering channel numbers, but it means that e.g. the volume button has to be repeatedly tapped in order to make a large change in volume.

NEC2 sends the main signal, and sends it again if the button is held down. Good for setting volume, and not so good for setting the channel. Some components expect a mix of NEC1 and NEC2, but NEC2 would be used only for volume, fast forward, etc. Some components use all NEC2, and have internal logic to figure out what the user had in mind.

Now, it is surprising that you've got a mixture of NEC1 and NEC2, especially since the device number is 1. NEC (the Japanese company) restricts use of most NEC (the IR protocol) device numbers to companies who have licensed the protocol. So Denon uses 210, Yamaha uses numbers in the 120 range, Pioneer in the 160 range, etc. Anybody is free to use 0, and I believe 1 has few if any restrictions. Nearly anybody using NEC device numbers 0 or 1 uses NEC1 exclusively. Try the Lookup Tool (link above) and check out the large number of setup codes for NEC1 device 1. On the other hand, NEC2 device 1 has no setup codes.

If you're willing, I'd like you to relearn the TV signals, and check to see if the two sets of learns always decode with the same IR protocol, or if sometimes it switches between NEC1 and NEC2. This is more a favor to me than anything, so if you're uncomfortable doing the relearns, that's fine.

So, you can either make an upgrade with all functions employing NEC1 device 1 (that's what I would try first), or you can change to the NEC 4 DEV Combo executor which will allow you to select among NEC1/NEC2/NECx1/NECx2. (The NECx protocols use a different lead-in timing.) You can save some typing by copying entire columns and pasting them into a second instance of RM or RMIR, but I think you'll have to manually set the NEC1 or NEC2 attribute.

In any event, for the media box, there's no reason to use two styles of NEC1. Just choose NEC1.
Back to top
View user's profile Send private message
manno



Joined: 27 Jan 2015
Posts: 9

                    
PostPosted: Fri Jan 30, 2015 1:14 am    Post subject: Reply with quote

Thanks for the info 3FG! That does make sense about the difference between the 1 and 2 protocol.

After doing a relearn of the TV remote, it looks like the 1 or 2 protocol is random, never the same, for some functions at least:

Learn #1:

TV Power 46 37974 NEC1
TV OK 46 37974 NEC1
TV 1 41 38095 NEC2
TV 2 41 38095 NEC2
TV 3 41 38095 NEC2
TV 4 41 37974 NEC2
TV 5 41 38095 NEC2
TV 6 41 38095 NEC2
TV 7 41 37974 NEC2
TV 8 41 38095 NEC2
TV 9 41 38095 NEC2
TV 0 41 38095 NEC2
TV Menu 41 37974 NEC2
TV dash 41 37974 NEC2
TV Left 46 37974 NEC1
TV Up 41 37974 NEC2
TV Right 46 37974 NEC1
TV Down 41 38095 NEC2
TV Vol+ 46 38095 NEC1
TV Vol- 46 38095 NEC1

Learn #2:

TV Power 46 38216 NEC1
TV OK 46 38095 NEC1
TV 1 41 38095 NEC2
TV 2 41 38095 NEC2
TV 3 41 38095 NEC2
TV 4 41 38095 NEC2
TV 5 41 38095 NEC2
TV 6 41 38095 NEC2
TV 7 46 38095 NEC1
TV 8 46 38216 NEC1
TV 9 46 38095 NEC1
TV 0 41 38216 NEC2
TV Menu 46 38095 NEC1
TV Right 46 38095 NEC1
TV Left 46 38095 NEC1
TV Up 46 38095 NEC1
TV Down 46 37974 NEC1
TV Vol+ 46 38095 NEC1
TV Vol- 41 38216 NEC2

By the looks of this, I'd assume that, like you said, setting everything to NEC1 would probably work fine, correct?

Thanks again for the help!
Back to top
View user's profile Send private message
3FG
Expert


Joined: 19 May 2009
Posts: 3367

                    
PostPosted: Fri Jan 30, 2015 1:29 am    Post subject: Reply with quote

I don't understand this. It looks like there are only two decoded OBCs: 41 (NEC2) and 46 (NEC1). There should be a unique OBC for each function (exception: sometimes e.g. Vol+ is the same as up arrow.) So these look like poor learns or the decoding is erroneous. I'd like you to save an RMIR file with a complete set of learns, upload it here to the diagnosis area, and post a link to your upload. Also tell us the brand and model of your TV. Maybe this isn't really NEC at all. However, before uploading your RMIR file , please verify that your learned signals do actually control your TV. If they don't, change your method of learning. Don't forget to read the manual!
Back to top
View user's profile Send private message
manno



Joined: 27 Jan 2015
Posts: 9

                    
PostPosted: Fri Jan 30, 2015 1:45 am    Post subject: Reply with quote

The 41 and 46 are from the "Size" column in RMIR. The OBC are all unique numbers. I was indeed able to control my TV with the OFA. Here is the link to the .bin file from the OFA learned data:

http://www.hifi-remote.com/forums/dload.php?action=file&file_id=13120

Thanks!
Back to top
View user's profile Send private message
3FG
Expert


Joined: 19 May 2009
Posts: 3367

                    
PostPosted: Fri Jan 30, 2015 2:18 am    Post subject: Reply with quote

Considering that Vol+ decodes as NEC1 and Vol- as NEC2, I'm pretty sure that the all of the signals should be NEC1. Additionally, since we now know the TV is a Westinghouse, and uses device 1, JP1Master tells us that e.g. this file is likely to have the same codes as your TV, and in fact it does. BTW, setup codes TV 0885 or 1282 should control most of the functions of your TV.

So, make your upgrade all NEC1.
Back to top
View user's profile Send private message
manno



Joined: 27 Jan 2015
Posts: 9

                    
PostPosted: Fri Jan 30, 2015 2:28 am    Post subject: Reply with quote

I did exactly that and made everything NEC1 and all works now! I have one minor issue about the power code for the STB but I think that is hardcoded in the box itself. I'll need to do a bit more research on this and see how to change that at the box...

I appreciate all of the help and learned quite a bit about the process. Thank you!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic       JP1 Remotes Forum Index -> JP1 - Beginners All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


 

Powered by phpBB © 2001, 2005 phpBB Group
Top 7 Advantages of Playing Online Slots The Evolution of Remote Control