|
Message
From: rich_daddio at yahoo.com<rich_daddio@y...>
Date: Fri Feb 22 00:31:15 CET 2008
Subject: [openrisc] Printf using OR1K C test and verilog.
Hi, I am not sure if this is what you are looking for but take a look at OpenRISC 1000 Architecture Manual under "Function Calling Sequence" and the table of registers, and that might help you.
http://www.opencores.org/cvsweb.shtml/or1k/docs/openrisc_arch.pdf
HTH & Best Regards,
Rich d ----- Original Message ----- From: Rahul Wagh<rahul.wagh@m...> To: Date: Wed Feb 20 09:14:25 CET 2008 Subject: [openrisc] Printf using OR1K C test and verilog.
> Hi, > > As you might have seen, when we say printf("....") in a > OR1k testcase > written in C, it calls the printf routine written in support.c > file. That > does not give the actual printing of the message within > "..." though. > Anybody has tried that in OR1k ? Any suggestions / pointers ? > At my end, I figured out that the GPR R3 gets the starting address > of the > memory location where the message in printf is stored. Using that, > I wrote a > small code in verilog monitor (or1200_monitor.v) to access the > memory (till > you get an ASCII equivalent of NULL or something like that) and > display the > things in %c format to get the message. However, this helps only > for > 'pure-text' type messages. It does not work for messages like the > following > : > printf("Register value = %x",reg_value); > Can anybody throw some light on how to do this ? (How does one > track the > location of the arguments passed to the printf statement ? etc..) > Thanks, > Rahul. > >
|
 |