Page 1 of 1
C++ sample?
Posted: Thu Apr 11, 2013 9:02 pm
by rocketdawg
Is there a c++ example?
One cannot just change the make file to use g++ since many "C" files do not have __cdecl guards/directives.
Do I have to build a kernel library and then link that to my c++ main()?
Re: C++ sample?
Posted: Thu Apr 11, 2013 9:07 pm
by Giovanni
Hi,
There are C++ examples in the repository, you should checkout the trunk for the latest C++ code. There is a C++ wrapper for the kernel objects too.
Giovanni
Re: C++ sample?
Posted: Thu Apr 11, 2013 9:15 pm
by rocketdawg
thanks,
I'm using the ChibiStudio and built some examples and downloaded to the F4 Discovery.
I see a STM32F103 g++ example.
I'm using a STM32F4 so it should not be hard to figure it out.
I'll look at the repo as well.
Re: C++ sample?
Posted: Thu Apr 11, 2013 9:49 pm
by Giovanni
On the repo there is an F4 example, it is not different, a C demo differs from a C++ one just because main.cpp file and the C++ wrapper, try comparing makefiles.
Giovanni
Re: C++ sample?
Posted: Thu Apr 11, 2013 9:57 pm
by rocketdawg
I see it.
Great! Thanks