Altera_Forum
Honored Contributor
16 years agoShould C2H work on pin I/O?
Hi-
I'm working on my first experiments with using the C2H compiler. For starters, I have a SW function that performs a bit-banged SPI output function (CS, CLK, and DATA). It works implemented as a SW function. I've attached the C source file. The problem I'm having is that when I attempt to build it as a HW accelerated function I'm met with the following error: "# 2009.11.17 12.44.13 (*) Running Generator Program for accelerator_SkeletonStandalone_spiWrite identified subroutine named spiWrite making hdl for subroutine named spiWrite ERROR: C2H:33: C2H ERROR: spiWrite::symbol underscorebuiltin_stwio_function_dereference0 not known to parent (c_bare_block=HASH(0x31b09c4)) at file: , line: 33 Accelerator module generation failed." It appears the tool is unable to translate the _builtin_stwio function which is buried in the macro of IOWR_ALTERA_AVALON_PIO_DATA() which I use to toggle my output pins. I'm fearing the worst here. Is it true then that pin I/O within a function selected to accelerate is not possible and then disqualifies the function from HW acceleration? If not, how do I overcome the problem I described? Thanks, John Speth