Page 1 of 1

Circular buffer max length

Posted: Thu Dec 07, 2023 8:56 am
by RGV250
Hi,
There was an issue with max string length for the uart being limited to 256, I am wondering if the circular buffer has the same limitation as I am getting the string as expected now but the code still does not work. Before I carry on trying to find out where the issue is I would like to know if that has a limit of 256 which could also cause a problem.

Regards,
Bob

Re: Circular buffer max length

Posted: Thu Dec 07, 2023 10:15 am
by BenR
Hi Bob,

I checked and it looks like there isn't an 8-bit limitation here on the CB or the length of the returned string. You might need to attach your project so we can try and help.

Re: Circular buffer max length

Posted: Thu Dec 07, 2023 10:27 am
by mnfisher
If it's the same project as in the UART thread - you have idx as a byte in Parse_Rx which may cause an issue...

Note that you can access characters in a string using .c = .str[.idx] rather using mid$ etc

Martin

Re: Circular buffer max length

Posted: Thu Dec 07, 2023 11:23 am
by RGV250
Hi,
Thanks for confirming the length is OK.
Thank Martin, I had missed that value.
Still having issues but at least I know it is deeper that that.

Bob