From: Himlam8484 on 12 Feb 2007 22:53 I found a C compiler for picoblaze, it have a manual and some examples. But i try to compile it following the direction in the manual, it was not work. It always noticed "open failes" . i also write a simple C program to test but nothing can make it run. I also try to write a email to author, but he did not answer yet. Can anyone use it and get good results? Himlam
From: backhus on 13 Feb 2007 02:36 Himlam8484 schrieb: > I found a C compiler for picoblaze, it have a manual and some > examples. But i try to compile it following the direction in the > manual, it was not work. It always noticed "open failes" . i also > write a simple C program to test but nothing can make it run. > > I also try to write a email to author, but he did not answer yet. Can > anyone use it and get good results? > > > Himlam > Hi Himlam, let me set some points straight. 1.) There "is" no PicoBlaze processor into any FPGA unless you have synthesized the PicoBlaze sources (and the rest of your design) and downloaded the bitstream into the FPGA. 2.) As far as I know there is only one C-Compiler available for the PicoBlaze: PCCOMP from Francesco Poderico. This one supports only Picoblaze for Spartan3 and Virtex II FPGAs. So, which kind of FPGA are u using on your board? Which "open fails"? The open for reading your source code or have you used an open() function in your source? In the first case you probably made some mistake while invoking the compiler. In the second case you just forgot that you are writing code for a simple microcontroller. There is nothing to open. Have a look at the manual. The allowed statements are as reduced as the PicoBlaze itself is. So take good care what you are programming. Not everything is allowed or meaningful when using PCCOMP. About the other questions: You can run the KCPSM.EXE under linux by using some DOS emulation program. I'm running it under wine : wine kcpsm.exe <infile.psm> I'm not sure about the KCPSM3.EXE. Either your WINE is not up to date, or maybe you forgot to put the ROM_form.* templates into the correct path? Have a nice synthesis Eilert
From: Himlam8484 on 13 Feb 2007 04:44 Hi Eilert, Thank you very much for your idea. i am using a IC XC3S400. I know it get a Picoblaze inside. First, i only test program PCCOOMP to sure it runs well. "open failed" means PCCOMP can not open file( for example, I downloaded a file from the place i loaded PCCOMP soft). I open these files with Borland C, and they are Ok. But when i compiled in PCCOMP , it always failed. I have no occassion to get a code to load into Picobalze. By the way, i think you get much knowledge about FPGA, can you make me clear somethings? i would like to program for Picoblaze In C, i have to include "Spartan3.h" to be able to use Picoblaze languege in C, wouldn't I? Please tell me with my stupid questions. have a nice day! Him Lam
From: backhus on 14 Feb 2007 02:25 Himlam8484 schrieb: > > Hi Eilert, > > Thank you very much for your idea. i am using a IC XC3S400. I know it > get a Picoblaze inside. First, i only test program PCCOOMP to sure it > runs well. "open failed" means PCCOMP can not open file( for example, > I downloaded a file from the place i loaded PCCOMP soft). I open these > files with Borland C, and they are Ok. But when i compiled in PCCOMP , > it always failed. > > I have no occassion to get a code to load into Picobalze. > > By the way, i think you get much knowledge about FPGA, can you make me > clear somethings? i would like to program for Picoblaze In C, i have > to include "Spartan3.h" to be able to use Picoblaze languege in C, > wouldn't I? Please tell me with my stupid questions. > > have a nice day! > > Him Lam > Hi Him, Today I have tested PCCOMP 1.8.4 with two of its examples (sqrt and fibonacci) Two things have to be taken care of: the header files have either to be placed in a subdirectory called lib, or the includes hav to be changed to e.g. #include "spartan3.h" if the header files are in the same directory as the source file. whatever you prefer. i used the following commandline: pccomp -c -s example_sqrt.c pccomp -c -s ex_fibnacci_s3.c there was a little error in the fibonnacci source: on line 69 you have to add a missing #endif but then it compiles without errors. after all mi directory looked like this: 14.02.2007 08:02 <DIR> . 14.02.2007 08:02 <DIR> .. 14.02.2007 07:40 941 example_sqrt.c 14.02.2007 07:41 5.567 example_sqrt.fra 14.02.2007 07:41 5.574 example_sqrt.pod 14.02.2007 07:41 5.566 example_sqrt.psm 14.02.2007 08:02 2.105 ex_fibnacci_s3.c 14.02.2007 08:02 5.532 ex_fibnacci_s3.fra 14.02.2007 08:02 5.563 ex_fibnacci_s3.pod 14.02.2007 08:02 5.531 ex_fibnacci_s3.psm 03.12.2006 13:45 356.287 pccomp.exe 03.07.2005 14:41 211.332 pccomp_manual.pdf 28.01.2005 09:23 771 spartan3.h 04.02.2005 15:00 768 sqrt.h The *.psm files have to be assembled with the kcpsm3.exe In order to do so you have to rename or copy the *.psm files to dos-like 8.3 filenames. e.g. sqrt.psm and fibo.psm. Now kcpsm3 can assemble these sources, and your directory may look like this: 14.02.2007 08:16 148 CONSTANT.TXT 14.02.2007 07:40 941 example_sqrt.c 14.02.2007 07:41 5.567 example_sqrt.fra 14.02.2007 07:41 5.574 example_sqrt.pod 14.02.2007 07:41 5.566 example_sqrt.psm 14.02.2007 08:02 2.105 ex_fibnacci_s3.c 14.02.2007 07:41 2.097 ex_fibnacci_s3.c~ 14.02.2007 08:02 5.532 ex_fibnacci_s3.fra 14.02.2007 08:02 5.563 ex_fibnacci_s3.pod 14.02.2007 08:02 5.531 ex_fibnacci_s3.psm 14.02.2007 08:16 8.085 FIBO.COE 14.02.2007 08:16 5.703 FIBO.DEC 14.02.2007 08:16 8.876 FIBO.FMT 14.02.2007 08:16 7.168 FIBO.HEX 14.02.2007 08:16 13.806 FIBO.LOG 14.02.2007 08:16 4.309 FIBO.M 14.02.2007 08:16 7.179 FIBO.MEM 14.02.2007 08:02 5.531 fibo.psm 14.02.2007 08:16 23.300 FIBO.V 14.02.2007 08:16 19.273 FIBO.VHD 05.07.2005 08:33 90.308 KCPSM3.EXE 14.02.2007 08:16 228 LABELS.TXT 14.02.2007 08:16 25.517 PASS1.DAT 14.02.2007 08:16 25.517 PASS2.DAT 14.02.2007 08:16 30.702 PASS3.DAT 14.02.2007 08:16 39.894 PASS4.DAT 14.02.2007 08:16 53.003 PASS5.DAT 03.12.2006 13:45 356.287 pccomp.exe 03.07.2005 14:41 211.332 pccomp_manual.pdf 25.01.2002 15:17 857 ROM_form.coe 04.07.2005 17:05 15.275 ROM_form.v 05.07.2005 08:39 12.748 ROM_form.vhd 28.01.2005 09:23 771 spartan3.h 14.02.2007 08:14 8.085 SQRT.COE 14.02.2007 08:14 5.998 SQRT.DEC 14.02.2007 08:14 10.025 SQRT.FMT 04.02.2005 15:00 768 sqrt.h 14.02.2007 08:14 7.168 SQRT.HEX 14.02.2007 08:14 15.318 SQRT.LOG 14.02.2007 08:14 4.604 SQRT.M 14.02.2007 08:14 7.179 SQRT.MEM 14.02.2007 07:41 5.566 sqrt.psm 14.02.2007 08:14 23.300 SQRT.V 14.02.2007 08:14 19.273 SQRT.VHD The files SQRT.VHD/V/MEM etc. and FIBO.VHD/V/MEM etc. are the sources for your Picoblaze-ROM. Depending on the flow you use you have to include the right one to your ISE-Project. Now you can implement your design and download the bitfile to your FPGA. I don't know which source you have tried. The above examples work just fine. Have a nice synthesis Eilert
|
Pages: 1 Prev: Virtex 4 SATA redux Next: Xilinx platform cable USB API? |