Hmm, don't take it as an offense, but this forum is really a place to ask help if you are trying to do something in Perl and are encountering problems doing it, it is not a bureau to write free programs for you.

If you want to hire someone to do the work for you, you may look at this page: http://perlguru.com/gforum.cgi?forum=19;

Just an example on how you could do what you want. If you have the following line:

Code

static const data16 HEAD_SELECT = 0x000F; // <3:0> - RW

and want to write:

Code

set SymList [list [list HEAD_SELECT [list 0 0x000F 0]] \

I'll assume that you want to use the 0x000F value of the first line to populate the value un the second line. This could be done with something like this (assuming you input line above is stored in the $line variable):

You just have to do something like this for all cases, and you are done. Pretty simple, isn't it?

Or may be it does not look simple at all to you. If it looks like mumbo jumbo to you, then we are back to what I was saying at the beginning: may be you should hire someone to do the job and pay that person. It would probably take me just a few hours to do the work, so it would not necessarily be very expensive (but let me be clear, I am a feelance consultant, but I am emphatically not offering my services to do it, I have enough work to fill my day for the time being).

As an additional comment, I must say that you are very very far from giving enough details on how one should use the data from your input file to derive the data to be inserted in your output file. Just for the sample line that coded above, there are many more things derived from my assumptions on or my understanding of what you need than from your description of what you need. You've got to be much more precise and detailed in your specs or bill of requirements.

So, if you find someone to do the work, you'll have do describe much more precisely what you need. No one can write a program and hope to be right just from the example you gave.

It's best if you start doing the program, and when you get stuck, focus your question exactly on the point where you are stuck, not the whole program.

Also, since you said that you don't have much experience in programming, it would be helpful if you make clear wheather the question relates to how to solve a problem in general (i.e. "how do I implement a sorting routine"), or to something particular in Perl (i.e. "I know the algorithm of doing a quicksort, but does Perl offer already some tools to sort my data?").

Finally, whenever you start writing something in Perl, ALWAYS start your program with the following directives:

Code

use strict; use warnings FATAL => qw(all); use diagnostics;

Doing so, will save you a lot of work. Once you get more experienced in Perl programming, you might consider to reduce this to