Automate a csv file

Discussion in 'Perl' started by Narayanan P M, Jul 6, 2015.

  1. Narayanan P M

    Narayanan P M

    Joined:
    Jul 6, 2015
    Messages:
    1
    Likes Received:
    0
    The csv file looks like as given below.

    OUTPUT PATH,a/b/c,,,,
    OUTPUT FILENAME,bind_AHB.sv,,,,
    PK_BIND_MOD_NME,master,,,,
    PK_BIND_MOD_INST,qahb_checker,,,,
    PK_INST_NME,AHB_(MASTER/SAVE)_PK_$COUNT,# VERIFY_BLK ==2--> Master| ==1 --> Slave | COUNT==Running count of num of instance,,,
    ,,,,,
    Signal Start,PK_SIG_NME,PK_SIGNALS_WIDTH,DESIGN_SIG_NME(exact string),,
    ,HRESETn ,1,~dcc_ares,,
    ,HCLK,1,dcc_clk,,
    ,HADDR, [31:0],i_dcc_qhs_haddr,,
    Param Start,PK_PARAM_NME,PK_DEFAULT_VALUE,PK_NEW_VALUE,,
    , AHB_LITE ,0,,,
    , VERIFY_BLK ,0,2,,
    , CONFIG_SIMULATION,0,,,

    I need to automate this in a certain way. It should look for PK_BIND_MOD_NME and PK_INST_NME,AHBand then generate an output file with the name specified in OUTPUT FILENAME ( here its given as bind_AHB.sv) in a certain directory as specified in OUTPUT PATH. The output file should look like
    bind master qahb_checker #(.AHB_LITE(0), .VERIFY_BLK(2),.CONFIG_SIMULATION(0)) qahb_checker (.HRESETn(~dcc_ares), .HCLK(dcc_clk), .HADDR(i_dcc_qhs_haddr));
     
    Narayanan P M, Jul 6, 2015
    #1
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. [nix]
    Replies:
    1
    Views:
    4,099
    [nix]
    Sep 7, 2003
  2. Michal Mikolajczyk
    Replies:
    0
    Views:
    1,004
    Michal Mikolajczyk
    Feb 13, 2004
  3. Tintin92
    Replies:
    1
    Views:
    2,291
    Andrew Thompson
    Feb 14, 2007
  4. jliu66
    Replies:
    0
    Views:
    818
    jliu66
    Oct 19, 2007
  5. sso
    Replies:
    20
    Views:
    3,322
    Martin Gregorie
    Apr 26, 2009
  6. Tim
    Replies:
    1
    Views:
    550
    Peter Otten
    Jul 5, 2010
  7. Li Chen
    Replies:
    18
    Views:
    1,093
    Azmi Farih
    Mar 23, 2010
  8. Sacha Rook

    csv read clean up and write out to csv

    Sacha Rook, Nov 2, 2012, in forum: Python
    Replies:
    2
    Views:
    534
    Hans Mulder
    Nov 2, 2012
Loading...