I'm not a professional coder. I'm a retired hardware designer of FPGA and ASICS. So please bear with me. My hobby is robotics and other electronic based projects.
I want to pass to a concat function char arrays A, B, and concat to char array O . The attached code works just fine.
It seems that the size of the arrays should not be needed. Is there a way to pass these arrays and determine the array size within the function?
replace this function call:
concatCharArraysABtoO(A, sizeof(A), B, sizeof(B), O, sizeof(O));
with this: concatCharArraysABtoO(A, B, O);
Another question is there an easier way to concat char arrays?
more use of program memory and data memory. This code adds 35 data bytes and 306 program bytes. If recollection serves Strings use more memory. I've a tight budget in both program and data memory.
i've found there's plenty of flash. i've run out of data space but had plenty of flash. you can store static (const) data and strings in flash. see PROGMEM
@gcjr Thanks, I'm doing that already. I'm at 23000 Program and and not much more then 200 left over bytes for data. When it gets real tight I'll start stripping out anything not needed like error messages. I know before I'm done there will be a crunch. So crunching it down as I go is way easier.
I cannot reveal the project until the patent is filed. I will say the data structures are significant and must be held in memory for speed. Too much data for memory of either kind. EPROM is also used, this is cumbersome, but good for startup purposes.
I'm adding an SD Card to store data that is swapped in and out during configuration selections.