- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am going to be using PSoC for a fairly large project. I was thinking of using C++ since it would make my code easier to organise. However latency will be farily important for my project. I will also be implementing 2 PID controllers for the project. From what I understand using C++ would cause my PSoC to slow down and might also cause memory issues. How much of a drop in speed are we talking about. How likely are the memory issues. Are there any other problems I should be aware of.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
bebe,
Which type of PSoC were you planning on using?
C++ compilers used to be bloated. But advances in optimizing compiling has reduced code size and, depending on the setting, reduced executing time. Additionally most C++ compilers still allow for modules to be coded in C or assembler to further improve execution time.
If you are planning on using PSoC Creator as the IDE for your project, I am not aware of C++ being available.
However, if you plan to use a PSoC6 for your project, ModusToolBox as C++ as well as there are versions of the PSoC6 with up to 2MB of FLASH and 1 MB of SRAM.
Len
"Engineering is an Art. The Art of Compromise."
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
bebe,
Which type of PSoC were you planning on using?
C++ compilers used to be bloated. But advances in optimizing compiling has reduced code size and, depending on the setting, reduced executing time. Additionally most C++ compilers still allow for modules to be coded in C or assembler to further improve execution time.
If you are planning on using PSoC Creator as the IDE for your project, I am not aware of C++ being available.
However, if you plan to use a PSoC6 for your project, ModusToolBox as C++ as well as there are versions of the PSoC6 with up to 2MB of FLASH and 1 MB of SRAM.
Len
"Engineering is an Art. The Art of Compromise."
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I am going to be using PSoC for a fairly large project. I was thinking of using C++ since it would make my code easier to organise. However latency will be farily important for my project. I will also be implementing 2 PID controllers for the project. From what I understand using C++ would cause my PSoC to slow down and might also cause memory issues. How much of a drop in speed are we talking about. How likely are the memory issues. Are there any other problems I should be aware of.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
BeBe,
Although there probably will be some FLASH overhead when using C++ over C, the code "bloat" of the old days using C++ is mostly gone.
One trick I would use is to code in C++ as desired. If I'm pushing the code size limit or need better performance I convert my C++ code to C (or assembler) as needed.
Len
"Engineering is an Art. The Art of Compromise."