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

Rounding learned signals in IR.exe
Goto page 1, 2, 3  Next
 
Post new topic   Reply to topic    JP1 Remotes Forum Index -> JP1 - Software
View previous topic :: View next topic  
Author Message
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Fri Jan 05, 2007 3:38 pm    Post subject: Reply with quote

One very time consuming task that I have to do alot with IR, is cut & paste all the timing data for a new protocol that somebody has captured so I can decode the signals by hand. Do you think you could add a "summary" like feature which will output all of the timing data at once so I can copy it to a text file, rather than having to grab it one signal at a time.

Another thing I have to do before I can start running global edits on the data is round up/down all the times so like times are actually the same. Would it be possible to add rounding as an optional extra to IR?
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!


Last edited by The Robman on Fri Mar 13, 2009 8:08 pm; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website
binky123
Expert


Joined: 14 Feb 2004
Posts: 1292

PostPosted: Mon Jan 08, 2007 6:51 pm    Post subject: Reply with quote

THis might be getting beyond my abilities or knowledge on IR. Is the information that you want available already? Is there example code already that generates summary data? If the data is already available and there is some code that generates summary data/window then i might be able to piece it together for you.

I understand the rounding as i had to do that in my simple irscan.c program but i'm not familiar with how IR parses the learning data. I thought decodeir.dll did that.
Back to top
View user's profile Send private message
johnsfine
Site Admin


Joined: 10 Aug 2003
Posts: 4766
Location: Bedford, MA

PostPosted: Mon Jan 08, 2007 9:10 pm    Post subject: Reply with quote

IR.exe does significant processing on the learned data to transform it into a series if timings before handing it to DecodeIr.

The learning process does serious "rounding" to make similar values identical before storing the signals. Sometimes it does too much. I'm surprised you want more rounding than that.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Mon Jan 08, 2007 11:33 pm    Post subject: Reply with quote

binky123 wrote:
THis might be getting beyond my abilities or knowledge on IR. Is the information that you want available already? Is there example code already that generates summary data? If the data is already available and there is some code that generates summary data/window then i might be able to piece it together for you.

When you click on a learned signal in the Learned Signals tab, if you have the "Forced Learned Timings" option selected, IR will display the learned timings in 3 panels on the right side of the GUI (below the protocol, device code info).

When you click on File > Summary, IR produces a text sheet that summarizes all the user programming and at the bottom of this sheet is a list of all the learned signal decodes (ie, the protocol, device code, OBC, etc info).

What I'm looking for is a second summary option that also retrieves the learned signal info, except that rather than listing the protocol and device codes, etc all I'm looking for is the learned timing data.

johnsfine wrote:
The learning process does serious "rounding" to make similar values identical before storing the signals. Sometimes it does too much. I'm surprised you want more rounding than that.

Within one signal, the times are consistant enough that it's easy to convert them into binary data, but when you're trying to convert 30 or 40 buttons at a time, it's a drag to have to first convert -498 and -499 and -501 and -502 and -503, etc etc into -500. If the rounding process where to convert all the times to the nearest 10, let's say, I would just have to convert -490 and -510 to -500 and I'd be good to go.
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
binky123
Expert


Joined: 14 Feb 2004
Posts: 1292

PostPosted: Sat Jan 13, 2007 12:05 pm    Post subject: Reply with quote

ok, i've located the MakeSummary() function and it loops thru the LearnedCode list and outputs info. I also located where the 3 RAW panels data is calculated from the Burst data.

How did you want this data presented in the Summary? Also the rounding option, did you want that menu item added to the Advanced Tab list?
Back to top
View user's profile Send private message
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Sat Jan 13, 2007 12:55 pm    Post subject: Reply with quote

real button name, notes, timing data

for example...

Code:
up,,+1890 -1610 +810 -272 +270 {snip} -268 +270 -546 +522 -554 +270 -77734
down,,+1890 -1610 +810 -272 +270 {snip} -268 +270 -546 +522 -554 +270 -77734
select,ok,+1890 -1610 +810 -272 +270 {snip} -268 +270 -546 +522 -554 +270 -77734

I think the rounding feature could be offered as an option on the Learned Signals tab. My initial thoughts are that there could be an addition button at the bottom of the screen called "Rounding" which when clicked initiates a small pop-up screen where you can type in what number you would like the data rounded to (ie, the nearest 10, 100, 500, etc) and then you could select whether to apply the rounding to all of the learned signals or just the one that's selected.

Actually, now that I think about it, if you were to get this working there's another feature that would be nice to have. The code snippet above is actually for a bi-phase signal, so the next step in decoding it is to split up all the double times (eg, convert all the -540 times into two -270 times), so if there was an option to do that also, that would be great.
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
binky123
Expert


Joined: 14 Feb 2004
Posts: 1292

PostPosted: Sun Jan 21, 2007 4:47 pm    Post subject: Reply with quote

The Robman wrote:

Actually, now that I think about it, if you were to get this working there's another feature that would be nice to have. The code snippet above is actually for a bi-phase signal, so the next step in decoding it is to split up all the double times (eg, convert all the -540 times into two -270 times), so if there was an option to do that also, that would be great.


I would like to release one more IR7 as beta4. Algorithmically, how did you want the above implemented? Internally, the burst pairs are just printed out with the first as + and the second as -. You want this + + and - -? What about he GUI for this? a checkbox somewhere?
Back to top
View user's profile Send private message
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Sun Jan 21, 2007 5:27 pm    Post subject: Reply with quote

It should be a user decision, rather than automatic, so a GUI checkbox or something would be appropiate. Basically, I'd like the ability to split certain times in half, so it the timing string looked something like this...

-500 +500 -500 +1000 -1000 +1000 -500

I could split it into this...

-500 +500 -500 +500 +500 -500 -500 +500 +500 -500

What would make it even better would be the option to add a delimiter between the resulting pairs, such as...

-500 +500; -500 +500; +500 -500; -500 +500; +500 -500 ;
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
binky123
Expert


Joined: 14 Feb 2004
Posts: 1292

PostPosted: Sun Jan 21, 2007 5:51 pm    Post subject: Reply with quote

Given I'm not a GUI guy, it looks too difficult for me to implement it.
Back to top
View user's profile Send private message
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Tue Jan 23, 2007 10:49 am    Post subject: Reply with quote

binky123 wrote:
I was thinking of 3 boxes for single, repeat, extra. clicking on each box will show the drop-down list of each burst signal and then checking an entry will cause the list to be changed so that specific entry is split.

Just FYI, if I'm going to split a bi-phase signal, I'm going to want to do it for the entire signal, I'm never going to want to do it just for the single, repeat or extra portion.
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
binky123
Expert


Joined: 14 Feb 2004
Posts: 1292

PostPosted: Tue Jan 23, 2007 11:41 am    Post subject: Reply with quote

Ok, so you just want one long list of the data. Internally, it is stored in an array and then a count is kept for the single, repeat, extra bursts. The first section of the array is single, followed by repeat and then extra burst pairs.
Back to top
View user's profile Send private message
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Tue Jan 23, 2007 12:21 pm    Post subject: Reply with quote

Regardless of how the signal is represented by IR, if it's a bi-phase signal, the whole signal will be bi-phase, not just one part of the signal, so I would want to apply the edit to all three parts.
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Sun Jan 28, 2007 2:01 pm    Post subject: Reply with quote

Thanks for all your efforts with this. I'll drop a line to Mark to see if he has any more pointers regarding the GUI stuff.

Anyway, I tried out the bi-phase thing and I'm not sure how to get it to work right. If you open the FromRob.ir file that's always included with IR, click on the ReplayTV signal learned to the P&P:Rewind button.

The raw signal looks like this...
+2664 -890 +444 -440 +444 -440 +444 -880 +444 -880 +888 -440 +444 -440 +444 -440 +444 -440 +444 -440 +444 -440 +444 -440 +888 -880 +444 -440 +444 -440 +444 -440 +444 -440 +444 -440 +444 -440 +888 -880 +444 -440 +444 -440 +444 -440 +888 -440 +444 -880 +888 -109216

Then, if you round it to 420 it looks like this...
+2520 -840 +420 -420 +420 -420 +420 -840 +420 -840 +840 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +840 -840 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +840 -840 +420 -420 +420 -420 +420 -420 +840 -420 +420 -840 +840 -109200

What I'd like to do next is split all the +840 and -840 items into two 420 items. To do this, I'd like to enter 420 (without a sign) into the bi-phase rounding box which should cause IR to split any +840 items into "+420 +420" and any -840 items into "-420 -420".

I would want to do this edit globally to all of the learned signals. The next 3 signals learned in P&P mode are also bi-phase ReplayTV signals, so the edits entered should work for them also.

So, what do you think, is this do-able?
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
binky123
Expert


Joined: 14 Feb 2004
Posts: 1292

PostPosted: Sun Jan 28, 2007 2:34 pm    Post subject: Reply with quote

The bi-phase usage is fairly simple. It just brings up a drop down list of all the bursts in the signal. You then select/highight which entry you want to be split. It then splits it and adds a '*' at the end.

So you are saying you want to change this to an Edit box like the LocalRoundTo and just enter a number in here. The number will be used to search in the signal list for signals to split.
Back to top
View user's profile Send private message
The Robman
Site Owner


Joined: 01 Aug 2003
Posts: 20376
Location: Chicago, IL

PostPosted: Sun Jan 28, 2007 4:25 pm    Post subject: Reply with quote

binky123 wrote:
So you are saying you want to change this to an Edit box like the LocalRoundTo and just enter a number in here. The number will be used to search in the signal list for signals to split.

Exactly. You could use the drop-down approach also if you like, as long as it just gives me one copy of each burst time and then applies the change across the whole signal.

I did figure out how to use the current drop down after a while. Unfortunately, this method would be way more time consuming that what I do now, so it wouldn't be any use to me. Remember, the time when I would be using these two new features is when I'm trying to decode signals that somebody has learned and DecodeIR doesn't recognize the protocol. I will use the rounding edit to make the signals as uniform as possible so that I can apply global edits to them in order to convert them to binary. The rounding option means that I have to do alot fewer edits to get the burst times uniform before doing the edits that convert the signals to binary. Having the times in the Summary sheet saves me the time of having to cut and paste 20 or 30 signals, some of which may come in three parts. The bi-phase option would save me the edits where I convert the double times into single times. With the current setup, I can do that with just two edits (ie, +840 ==> +420 +420, and -840 ==> -420 -420) so to have to do it once for each burst time, across many different signals, would be alot of work.

The next step with bi-phase signals, to convert the times to binary, is the tricky one. With pulse width signals you don't need to worry about the boundary between pairs (eg, when you edit +400 -400 to "0" and +400 -800 to "1") but with bi-phase you can't just use global edits because it would be too easy for the edit to go across the wrong boundary. For example, where are the boundaries in +400 -400 +400 -400? Is this two pairs where the pair is "+400 -400", or are the middle 2 bursts the pair (ie, -400 +400) and the other two bursts are the end of one pair and the beginning of another. Therefore, what I have to do next with bi-phase signals is import the text file into a spreadsheet and force the columns to be the pair boundaries, then I can do the global edits.

In order for the bi-phase feature in IR to really save me some time, I would need the ability to insert a delimiter into the mix. For example, goig back to the signal I posted earlier, after splitting all the double times into single times, it would look like this...

+2520 -420 -420 +420 -420 +420 -420 +420 -420 -420 +420 -420 -420 +420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 +420 -420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 -420 +420 +420 -420 -420 +420 -420 +420 -420 +420 -420 +420 +420 -420 +420 -420 -420 +420 +420 -109200

What I'd like to be able to do now is put a delimiter in there either after every 2 burst times, the only option should be whether to put it on the even breaks or the odd breaks.

If I chose EVEN breaks, the result should look like this...
+2520 -420; -420 +420; -420 +420; -420 +420; -420 -420; +420 -420; -420 +420; +420 -420; +420 -420; +420 -420; +420 -420; +420 -420; +420 -420; +420 -420; +420 +420; -420 -420; +420 -420; +420 -420; +420 -420; +420 -420; +420 -420; +420 -420; +420 +420; -420 -420; +420 -420; +420 -420; +420 -420; +420 +420; -420 +420; -420 -420; +420 +420; -109200

If I chose ODD breaks, it should look like this...
+2520; -420 -420; +420 -420; +420 -420; +420 -420; -420 +420; -420 -420; +420 +420; -420 +420; -420 +420; -420 +420; -420 +420; -420 +420; -420 +420; -420 +420; +420 -420; -420 +420; -420 +420; -420 +420; -420 +420; -420 +420; -420 +420; -420 +420; +420 -420; -420 +420; -420 +420; -420 +420; -420 +420; +420 -420; +420 -420; -420 +420; +420 -109200

My next step would be to try and convert the results into binary, which I would do by converting "-420 +420" to "0" and "+420 -420" to "1". The results using the above timing strings would be...

EVEN...
+2520 -420;0;0;0; -420 -420;1;0;1;1;1;1;1;1;1; +420 +420; -420 -420;1;1;1;1;1;1; +420 +420; -420 -420;1;1;1; +420 +420;0; -420 -420; +420 +420; -109200

ODD...
+2520; -420 -420;1;1;1;0; -420 -420; +420 +420;0;0;0;0;0;0;0;1;0;0;0;0;0;0;0;1;0;0;0;0;1;1;0; +420 -109200

At this point, experience would tell me that the ODD one is correct, as I happen to know to expect what we call a "double wide pair" in the beginning of the Replay signal (ie, the "420 -420; +420 +420" string). The EVEN string has lots of mis-matched pairs, so this is obviously not the way to go. (If anyone is paying really close attention and is wondering why there appears to only be 7 bits in the OBC portion of this signal, it's because the leadout pair "+420 -109200+ is really "+420 -420 -108780" so there's a final "1" bit hidden in there).
_________________
Rob
www.hifi-remote.com
Please don't PM me with remote questions, post them in the forums so all the experts can help!
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic       JP1 Remotes Forum Index -> JP1 - Software All times are GMT - 5 Hours
Goto page 1, 2, 3  Next
Page 1 of 3

 
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
Get Smart! the band's official homepage Rockabilly Central