I'm new to embedded system and programmation in general, I wouldn't be able to start from 'scratch' for sure! I'm still trying to understand why the constructor PruIo::PruIo() is defined differently in pruio.h pruIo* pruio_new(uint16 Act, uint8 Av, uint32 OpD, uint8 SaD); and in pruio_c_wrapper.h PruIo* pruio_new(uint8 Av, uint32 OpD, uint8 SaD, uint8 Pru); and which one should I use. I get that pruIo and PruIo are two different struct, but that's it. R
Il giorno giovedì 24 settembre 2015 00:14:17 UTC+2, William Hermans ha scritto: > > *Both the headers are in the local include folder of the bbb, and the c >> file in the src/c_wrapper folder (with pruio.h and pruio_c_wrapper.h)* > > > Yeah after reading that stackoverflow post it did occur to me it could be > a shared library linker option "issue". Which I find kind of odd, but I do > not typically use other peoples code as such. Usually I write my own code > from "scratch", and try to avoid as much third party code as possible. > Third party abstraction layers bother me even more . . . > > On Wed, Sep 23, 2015 at 3:05 PM, hllpc <[email protected] > <javascript:>> wrote: > >> >> Both the headers are in the local include folder of the bbb, and the c >> file in the src/c_wrapper folder (with pruio.h and pruio_c_wrapper.h) >> Il giorno mercoledì 23 settembre 2015 23:11:34 UTC+2, William Hermans ha >> scritto: >>> >>> Ah, this seems to be a libpruio-ism . . . others have had similar issues >>> >>> >>> http://stackoverflow.com/questions/27517043/undefined-reference-to-pruio-new-and-pruio-config-on-beaglebone-black >>> >>> But nothing there specific to your error. >>> >>> On Wed, Sep 23, 2015 at 1:56 PM, William Hermans <[email protected]> >>> wrote: >>> >>>> *rb.c: In function ‘main’:* >>>>> *rb.c:19:25: error: ‘PRUIO_DEF_ACTIVE’ undeclared (first use in this >>>>> function)* >>>>> >>>>> *And I've no idea why, since PRUIO_DEF_ACTIVE is defined in pruio.h.* >>>>> *Do you know what could be my mistake?!* >>>>> *Thanks in advance* >>>> >>>> >>>> This means that PRUIO_DEF_ACTIVE is undefined or is not in the same >>>> scope as the c file using it. >>>> >>>> On Wed, Sep 23, 2015 at 1:16 PM, hllpc <[email protected]> wrote: >>>> >>>>> Thanks for your answer TJF! >>>>> I'm working C language directly on the bbb from PuTTy, so >>>>> I did my first attempt with rb mode but (after including both pruio.h >>>>> and pruio_c_wrapper.h ) i got an error in: >>>>> >>>>> >>>>> pruIo *io = pruio_new(PRUIO_DEF_ACTIVE, 1, 0x98, 0); // average, >>>>> open delay and sampe delay 0 >>>>> >>>>> >>>>> rb.c: In function ‘main’: >>>>> rb.c:19:25: error: ‘PRUIO_DEF_ACTIVE’ undeclared (first use in this >>>>> function) >>>>> >>>>> And I've no idea why, since PRUIO_DEF_ACTIVE is defined in pruio.h. >>>>> Do you know what could be my mistake?! >>>>> Thanks in advance >>>>> BR >>>>> >>>>> >>>>> >>>>> Il giorno mercoledì 16 settembre 2015 18:26:52 UTC+2, TJF ha scritto: >>>>>> >>>>>> Hi! >>>>>> >>>>>> Control input pins? You can control output pins. Do you mean >>>>>> configure? >>>>>> >>>>>> Even if you use dedicated PRUSS for the two pin sets, it'd be the >>>>>> same subsystem to sample the data (TSC_ADC_SS). >>>>>> >>>>>> The way to go is: >>>>>> >>>>>> - use PRU1 for the input part (running libpruio) >>>>>> - use PRU0 for your customized controller, getting input from >>>>>> libpruio >>>>>> >>>>>> BR >>>>>> >>>>> -- >>>>> For more options, visit http://beagleboard.org/discuss >>>>> --- >>>>> You received this message because you are subscribed to the Google >>>>> Groups "BeagleBoard" group. >>>>> To unsubscribe from this group and stop receiving emails from it, send >>>>> an email to [email protected]. >>>>> For more options, visit https://groups.google.com/d/optout. >>>>> >>>> >>>> >>> -- >> For more options, visit http://beagleboard.org/discuss >> --- >> You received this message because you are subscribed to the Google Groups >> "BeagleBoard" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> For more options, visit https://groups.google.com/d/optout. >> > > -- For more options, visit http://beagleboard.org/discuss --- You received this message because you are subscribed to the Google Groups "BeagleBoard" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
