PLI usages

C

coolblue

Guest
Hi all,
im using Cadence tool. I am a newbee to verilog. I want to use some
PLIs to interface a C function. I have written 2 files, first one is
mymodule.v and second one, mypli.c
---------------------------
//in the mymodule.v ==>
module mymodule;
initial
$my_pli;
endmodule
----------------
//in the mypli.c ==>
#include "stdio.h"
void my_pli();
{
printf("Hello");
}
------------
i have put these 2 filenames in a file , "run.f"
now i have compiled, elaborated and run these files using command:
ncverilog run.f
i get an eroor message that
"(mypli.c,2|3): expecting the keyword 'module', 'macromodule' or
'primitive'[A.1]."
what should i do?
please explain in simple words. step-by-step.
thank you,
 
Use "doc/pli*" in your Cadence installation. There is very good
description how to create and how to run your own tasks.
 

Welcome to EDABoard.com

Sponsor

Back
Top