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

IrMaster: a program for IR signal generation and analysis
Goto page 1, 2  Next
 
Post new topic   Reply to topic    JP1 Remotes Forum Index -> JP1 - Software
View previous topic :: View next topic  
Author Message
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Tue Oct 25, 2011 1:12 pm    Post subject: IrMaster: a program for IR signal generation and analysis Reply with quote

I have just completed the first version of IrMaster. Source available here, download link for binary, download setup.exe (for Windows only).

This program is not a "program with a GUI", nor is it a GUI for a particular program. Rather, it is a "Meta program", offering a GUI for a number of IR related programs, presently IrpMaster (advanced IR rendering program by myself), Makehex (older IR rendering program), DecodeIR (tries to identify an IR signal), and AnalyzeIR (which is my name of the Analyze-Function of the ExchangeIR-Library). Future extensions to other, possibly not yet written, programs are possible.

Note that I have written two different programs with quite similar names: IrMaster, the present one, a GUI, and IrpMaster, a library and a command line program, an IR signal render, but without a GUI. Please do not confuse.

So what can this program do: From a data base of known IR signals IR signals corresponding to arbitrary parameter values can be computed. Export files in different formats can be generated, for usage of other programs. For this, two alternative renders (my own IrpMaster as well as the older Makehex) are available. By using the clipboard, IR signals in Pronto format (for example from Internet articles) can be directly sent to the analyzers AnalyzeIR and DecodeIR. (To my knowledge, no other program presently allows this.) A computed signal can be sent proper hardware: For investigating possible non-documented IR signals of owned equipment, a "war dialer" can send whole parameter regions of IR signals. For this, hardware support in the form of GlobalCaché or IRTrans, or (unfortunatelly at the time of this writing not yet implemented) LIRC-support is required. A simple calculator intended for simple computations on IR signal timings is provided.

Written in Java, it runs on the all "relevant" platforms. Smile

The binary distribution contains all third-party components necessary.

Installation on Windows: just unpack in a (preferably empty) directory, double click on the jar. For browser related functions, it may be necessary to fill in the absolute address to your preferred browser (like c:\program files\...\program.exe). On Linux: just unpack. At least on my Suse/Gnome, double clicking on a jar does nothing sensible but opens a file archiver, might be different on other Gnome/KDE's. Anyhow it can be started for example from the command line by "java -jar IrMaster.jar". Or install in a directory like /usr/local/irmaster, copy or link the wrapper irmaster.sh to /usr/local/bin after making desired changes.

Update for release 1.0.0:
With the creation of IrScrutinizer (which functionally vastly surpasses IrMaster), IrMaster is not longer actively developed. The last version, somewhat ironically promoted to version 1.0.0, is planned to be the last release. Users are encouraged to migrate to IrScrutinizer. The Windows setup.exe for IrMaster has been eliminated, replaced by the combined installer for IrScrutinizer and IrMaster.


Edit (2011-10-26) Dowload link for binary adjusted.
Edit (2011-11-01) Download link for setup.exe added
Edit (2012-08-24) Release of version 0.3.0; download links for binarys not changed, for sources fixed. Title "commercialized"
Edit (2012-11-25) Release of version 0.3.1; download links not changed
Edit (2014-02-05) Release of version 1.0.0
Edit (2014-06-20) Release of version 1.0.1


Last edited by Barf on Fri Jun 20, 2014 2:23 pm; edited 7 times in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website
mdavej
Expert


Joined: 08 Oct 2003
Posts: 3256

PostPosted: Tue Oct 25, 2011 3:23 pm    Post subject: Reply with quote

Fantastic job, Barf. This is an amazing tool. I've only scratched the surface by trying to render and decode pronto hex so far, but it's looking good. The ability to output actual hardware is great.

I have one request so far. When exporting, I'd like to have some way to immediately open the file from within the GUI so I don't have to hunt for it. Something like the View button on the Options tab would work fine.

What is the purpose of the XML format? Do you have plans to use that for feeding data into other JP1 tools in the future?
Back to top
View user's profile Send private message
The Robman
Site Owner


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

PostPosted: Tue Oct 25, 2011 4:43 pm    Post subject: Reply with quote

I just tried playing with it. As an experiment, I selected NEC2 and entered device code 54, sub-device 22 and function 233, then I clicked Render to generate the Pronto hex. Then I clicked Decode and got the following output on the clipboard:

protocol = NEC2, device = 54, subdevice = 22, obc = 233
protocol = JVC{2}, device = 233, obc = 22

Do you know why the sprurious JVC decode it coming up?

I'm obviously gonna have to set aside some time to play with this interesting looking program.
_________________
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
vickyg2003
Site Admin


Joined: 20 Mar 2004
Posts: 6499
Location: Florida

PostPosted: Tue Oct 25, 2011 5:54 pm    Post subject: Reply with quote

Looks like a nice tool for the "masses", Wink . I ran into a problem trying to get to the help "content" to see if I could get a handle on how to use it.

Error message wrote:
Could not start browser with command `firefox file:/C:/remotejp/irpmaster/docs/irmaster.html


However at the command line this will work:
firefox file:/C:/remotejp/irpmaster/docs/irmaster.html
Back to top
View user's profile Send private message Visit poster's website
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Wed Oct 26, 2011 12:44 pm    Post subject: Reply with quote

Thanx for those kind words! Razz

Quote:
When exporting, I'd like to have some way to immediately open the file from within the GUI so I don't have to hunt for it. Something like the View button on the Options tab would work fine.

Should be quite easy to do, at least if opening in the browser. However, at least on Windows it raises the issue if opening text files in "the" browser is the sensible thing to do, or if it would have been better to imitate the explorer and open "the text editor" on it. I am not satisfied with the windows integration (as I wrote in the TODO), and would welcome some advice from someone who knows how it should be done according to style guides etc. But I am not very happy for windows-specific code.

Quote:
What is the purpose of the XML format?

It is almost like a principle for me: a good tool should be able to export its data in an information preserving, easily parse-able format, for other programs to convert and feed upon. It is thus easy to write a converter to any sensible format by processing the easily parse-able xml-format by, e.g., an XSLT-Script or another xml transformation language or program.

Quote:
Do you have plans to use that for feeding data into other JP1 tools in the future?
All suggestions are welcome. I discuss some in the TODO file.

Quote:
I clicked Decode and got the following output on the clipboard:

protocol = NEC2, device = 54, subdevice = 22, obc = 233
protocol = JVC{2}, device = 233, obc = 22

Do you know why the sprurious JVC decode it coming up?

You should ask a DecodeIR-expert since it is really an DecodeIR-issue. But to my understanding, several decodes is not necessarily a bug, just a question that has more than one correct answer. BTW, running the test script that comes with IrpMaster reveals a large number of issues, if I recall it correctly, more than 130000 failed decodes and 2 core dumps...

Quote:
Looks like a nice tool for the "masses", Wink . I

I am not sure it the "masses", say with their Logitec Harmony, would agree... Wink But IrMaster definitely has a larger target group than IrpMaster.



Quote:
Error message wrote:
Could not start browser with command `firefox file:/C:/remotejp/irpmaster/docs/irmaster.html

Have you tried selecting the full path-name for the browser in the Options pane? Cf. my first post.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
gfb107
Expert


Joined: 03 Aug 2003
Posts: 3364
Location: Cary, NC

PostPosted: Wed Oct 26, 2011 12:56 pm    Post subject: Reply with quote

This is Java, right? In Java 6 and later there is the java.awt.Desktop class for doing that sort of thing. See http://download.oracle.com/javase/6/docs/api/java/awt/Desktop.html

I use Desktop.getDesktop().browse( URI uri ) in RM/RMIR to launch the default browser for the stuff in the Help menu (Readme, Tutorial, Wiki, Forums, etc). There is also Desktop.getDesktop().edit( File file ) and Desktop.getDesktop().open( File file ).
Barf wrote:

Should be quite easy to do, at least if opening in the browser. However, at least on Windows it raises the issue if opening text files in "the" browser is the sensible thing to do, or if it would have been better to imitate the explorer and open "the text editor" on it. I am not satisfied with the windows integration (as I wrote in the TODO), and would welcome some advice from someone who knows how it should be done according to style guides etc. But I am not very happy for windows-specific code.

_________________
-- Greg
Original RemoteMaster developer
JP1 How-To's and Software Tools
The #1 Code Search FAQ and it's answer (PLEASE READ FIRST)
Back to top
View user's profile Send private message Visit poster's website
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Wed Oct 26, 2011 2:28 pm    Post subject: Reply with quote

@gfb107:
Thanx. Fills my needs exactly. One advantage is also that if some user does not like the selections made, someone else is to blaim. Or, better, he can fix it himself.

I feel slightly ashamed not having found this by myself Embarassed ...
Back to top
View user's profile Send private message Send e-mail Visit poster's website
3FG
Expert


Joined: 19 May 2009
Posts: 3165

PostPosted: Wed Oct 26, 2011 10:21 pm    Post subject: Reply with quote

The Robman wrote:
protocol = NEC2, device = 54, subdevice = 22, obc = 233
protocol = JVC{2}, device = 233, obc = 22
Do you know why the sprurious JVC decode it coming up?
I'm not sure why the JVC decode is showing up. The same Pronto Hex, imported into IR or IRScope using DecodeIR2.43 (same as IrMaster), doesn't show the JVC{2} decode.

JVC{2} means a JVC signal which is missing its lead in, and the last part of a NEC2 signal is nearly identical to JVC{2}. Only the leadout time is different, and of course DecodeIR ignores leadout times which are too long. You can see the similarity by looking at the IRP forms:
...................JVC {38k,525}<1,-1|1,-3>(16,-8,(D:8,F:8,1,-45)+)
NEC2 {38.4k,564}<1,-1|1,-3>(16,-8,D:8,S:8,F:8,~F:8,1,-78)+
Note that the complement of 233 is 22.

I speculate that IrMaster is calling DecodeIR twice, which in this case would be incorrect, since all of the bursts were fully decoded on the first call. However, I don't understand the "contexts" that DecodeIR returns to calling programs, and so I can't provide advice on how to know whether a second call is needed.
Back to top
View user's profile Send private message
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Thu Oct 27, 2011 2:09 pm    Post subject: Reply with quote

I found a problem in the code (decodePronto in IrpMaster.DecodeIR to be exact). I replaced that implementation with calls to functions in the class IrpMaster.Pronto -- and the multiple decode is gone! There was also some problems e.g. in decoding some, not all, rc5 commands, also gone.

I will be submit a new version as soon as I get time to it, probably on Saturday.

IrpMaster, and thus also IrMaster, reports all decodes from DecodeIR, without trying to be "smart". The calling interface -- calling a function repeatedly until it returns null -- is an anachronism that I have tried to encapsulate in the DecodeIR class of IrpMaster. This wrapper is in a way a precessor to that class.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Sat Oct 29, 2011 2:53 pm    Post subject: Reply with quote

I have made the changes I promised, and some more. The issue with DecodeIR has been fixed. The "open last export" has been implemented -- I had to change the ending of the export file to .txt for this to work without requiring hard customization of user's systems. I have changed all browse and open commands according to Greg's suggestion, thus leaving the browser configuration a disabled corpse -- will likely be nuked in the next version. Export directory is now per default a subdirectory of the default temporary directory (java.io.tmpdir). If it is nonexisting, it is created. Bugs when changing the debug code fixed. Properly handles shutdown by closing. Nonparseable debug code is now interpreted as 0. Standard stdout and stderr is restored immediately before exiting.

The source- and the binary distribution linked above have been updated. Version is called 0.1.1.

There is also a Windows-typical setup.exe distribution, available for download here, build by the Inno installer.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Thu May 03, 2012 3:32 pm    Post subject: Reply with quote

I have done a lot of work, and released version 0.1.2 of IrMaster, available in source and binary form, and for WIndows users, a particularly user friendly setup-file. Links are the same in the download area. I have also hosted it, as well as IrpMaster, on my site harctoolbox.org. This also means that the Java names have changed to be of the form org.harctoolbox.IrMaster.*.

I really should have written a release note, but my energy ran out... Wink The larger improvements is the support of LIRC, both as export format, and as output hardware: support of a (patched) LIRC server, allowing a LIRC server to send CCF signals from the network, thus sort-of mimicing the behavior of, e.g., a GlobalCache. (Patch enabling this is available here ) There is also a beefed-up IRCalculator, also computing EFCs/EFC5s. And a lot of smaller improvements. Like improved (but still too geeky) documentation. Also IrpMaster has a new release, with e.g. the --disregard-repeat-mins (see http://www.hifi-remote.com/forums/viewtopic.php?t=13396&start=31).

The binary distribution IrpMaster has been eliminated. Instead there is a smart wrapper installed, allowing to call the command line program IrpMaster in a slighty user friendlier way.

Feedback and suggestions for improvements are solicited.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Fri Aug 24, 2012 12:48 pm    Post subject: Reply with quote

Announcing IrMaster 0.3.0

I have just uploaded IrMaster 0.3.0, a Windows setup.exe, as well as a zipped binary distribution (for non-Windows users, and Windows users who do not like setup-exes). Sources available on my web site.

There are a number of improvements, in particular to make the program both easier and nicer to use. There is an "easy" mode, under Windows accessible by clicking the IrMaster Easy icon. In order to make the program as simple as possible for the novice, also the different elements of the user interface (hardware support, some menus, Makehex support,...) are disabled by default, and the user has to enable it manually, if desired. Per default, error messages etc are presented as popups, like in most Windows (Mac, KDE, Gnome) program. Most panels have its own help panels. UEI learned format is read as well as exported. The "War dialer" is finished. Cool icons, thanx to the Crystal project. See the release notes for a full list.

Actually, I have tried really hard to improve usability for beginners and "beginners" (as requested by Rob).

Release notes:
Quote:
Release notes for IrMaster 0.3.0.

Renamed this document to IrMaster.releasenotes.txt

Use nice icons from the crystal project. (Licensed under LGPL.)

There is now a shortcut menu, allowing shortcuts not only from that
menu, but also, using accelerators from the F-Keys on the keyboard.

Now there is an IrMaster icon. This is associated with the top Frame,
and also installed
as Windows icon in the setup program. The plotter also sets its
(unzoomed) content as its icon.

New menu Tools. Update check moved from Help menu to this.

The "war dialer" has been finished. That is, the pause button works,
can also resume. The "current F" can be changed while paused. The Note
button allows for entering notes to last F sent. The accumulated notes
are saved through the Save button, and cleared by the Clear button.

The IrCalc pand has now been removed. The code has been moved to a
separate project. Instead it is now a separate
project/namespace, org.harctoolbox.IrCalc. It can be accesses through
the new Tools menu.

There is a command-line only option --easy, that severely limits the
elements presented to the user. Removes as much as possible of what
can be confusing for the unexperienced. Aimed at the beginning user; inspired
by a private conversation with Rob Crowe. The windows installer
installs a separate icon, invoking the program with that option.

Most panes now have a help for the pane, causing a pop-up window (or
the console) to show a 10-100 lines of help for that pane. Can alternatively be
output to the console.

The IR Protocols pane has a "Docu" button that pops up a help on
selected protocol, and its IRP definition (if IrpMaster is selected as
renderer, otherwise the irp file is shown).

On the IR Protocols pane, the D, S, F, T, "Additional parameters" are
made insensitive whenever not part of the currently selected protocol.

There is now an option "use pop-ups for errors etc." that makes errors,
warnings, info appear as pop-ups if selected, as many conventional GUI
programs. If not selected, these are messages are still output to the
console, as before.

UEI learned format is now accepted instead of ccf input -- both
IrpMaster CLI and IrMaster CCF window. New option -u|--uei in
IrpMaster to generate UEI learned format as output.

EFC computations from the IrCalc pane has been removed -- it did not
fit in, and the EFC5 stuff was probably wrong.

Look and feel settings are now in a Options pull-right menu, have been
removed from the Options pane.

Support for exporting UEI learned format in xml and text exports.

Now using the "HarcHardware 0.8.0" library instead of Harctoolbox
0.8.0. This contains a lot of, mostly internal, improvements, but is
not documented yet. Probably not really visible for the user of
IrMaster. GlobalCache is now queried directly on startup.

Using 0.2.1 of IrpMaster, with its improvements, see its release notes.
Using fixed version of PlPlot, so the scaling is output in
"engineering units", e.g. 10^3n, for some n.

Misc. minor bugfixes, layout fixes, documentation fixes, etc.
================================================================
Releasenotes for IrMaster 0.2.0 and IrpMaster 0.2.0

User visible changes:

Plotting implemented using PtPlot.

Wave export and Audio Hardware output device implemented.
New export format Lintronic.

Wave import.

Many fixes to appearance, more careful layout etc. The main window now
rescales sensibly, making it possible to enlarge CCF window and/or the
log window. The divider on top of the log window allows for resizing
log window.

Have the send-button enabled some more, thus restoring old
short-circuiting behavior (render and sending if text area empty)

The short pronto forms 5000, 5001, 6000, 900a are now recognized in
the CCF window. They can be Plotted (and Analyzed!) directly.

IrpMaster: --analyzeIR --ccf .... was not working; fixed.

war dialer now has #-sends options.

IrProtocols.ini: MCE: make the T toggle. rs200 and intertechno new
protocols. A few toggling protocol (like rc6 and rc5x) was erroneously
written like (...,T=1-T)+, changed to ((...)+,T=1-T).

Internal improvements:

Many internal improvements in API and its documentation.

made exit codes uniform, see IrpUtils

Use jcommander for the decoding of command line decoding of the main
class of class Wave.

Macro new class, presently not really used yet. ModulatedIrSequence
new, use that in the API when appropriate. append(double) and
parseMacro new. use IrSignal(protocolIni, arg_i, args) in
main. Improved API: use doubles for data (in microseconds, not
periods) and for modulation frequency.

Version info moved into class Version (both IrMaster and IrpMaster).

use odd/even index in IrSequences instead of sign. Improved Help
message in Plotter. Put Time in Plotter header. Implemented plotting
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vickyg2003
Site Admin


Joined: 20 Mar 2004
Posts: 6499
Location: Florida

PostPosted: Fri Aug 24, 2012 5:20 pm    Post subject: Reply with quote

I recently needed to generate some Pronto Hex. I downloaded IRMaster and Makehex and Makehex gui. and tried them all.

Several years ago, I had used the command line version of makehex. It was pretty difficult for me. This time around I tried mdavej's makehex gui and that was a LOT easier than using plain old command line makehex but still pretty cryptic. In comparisson, the IRMaster was a pleasure to use. Fill in the D, S, F and I was on my way. Norhing cryptic at all.
For the novice user, with a well known protocol, this was definately the way to go.


The nice thing about makehex was I was that I could also create a file to create some unknown protocol, but I haven't done that for 5 years and I found it difficult.. I understand the your "Irpmaster" is what I need to use for that.
Back to top
View user's profile Send private message Visit poster's website
Barf



Joined: 24 Oct 2008
Posts: 682

PostPosted: Sat Aug 25, 2012 6:14 am    Post subject: Reply with quote

Hi Vicky,

nice to hear that you get well along with IrMaster. Please try the current version also, I have worked hard to make it both simpler, nicer, and prettier.

Quote:
The nice thing about makehex was I was that I could also create a file to create some unknown protocol, but I haven't done that for 5 years and I found it difficult..

Yes, it is a difficult problem, and will be so no matter what tools we have... Wink IrMaster does not really address that use case: you can of course edit a/the configuration file, but it is simply not designed for the use case. I have been thinking about creating some tool for that use case, but the number of users/usages is probably microscopic. As you suggest, using IrpMaster from the command line is not that bad: The error messages by e.g. erroneous IRPs are reasonably good (thanks to ANTLR!), the debug features may also be useful. If you have any particular suggestions, tell me.
Back to top
View user's profile Send private message Send e-mail Visit poster's website
vickyg2003
Site Admin


Joined: 20 Mar 2004
Posts: 6499
Location: Florida

PostPosted: Sat Aug 25, 2012 7:34 am    Post subject: Reply with quote

Barf wrote:
Vicky wrote:
The nice thing about makehex was I was that I could also create a file to create some unknown protocol, but I haven't done that for 5 years and I found it difficult..

Yes, it is a difficult problem, and will be so no matter what tools we have... Wink IrMaster does not really address that use case: you can of course edit a/the configuration file, but it is simply not designed for the use case. I have been thinking about creating some tool for that use case, but the number of users/usages is probably microscopic. As you suggest, using IrpMaster from the command line is not that bad: The error messages by e.g. erroneous IRPs are reasonably good (thanks to ANTLR!), the debug features may also be useful. If you have any particular suggestions, tell me.

Yes, as far as I know, there isn't a huge demand for this feature, at least not in the JP1 community. But there certainly are a lot of uses for pronto hex, not only in the pronto themselves, but also many other remotes have utilities for importing pronto hex. For me, I can usually write an executor, for one of my remotes and simply capture the pronto hex in IRScope. So I'm not really in the "market" for either makehex or irpmaster, unless I need 100's of commands.
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  Next
Page 1 of 2

 
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