This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

sprintf/printf/stack - limit - TINI400

Hello I am Leandro (Buenos Aires - Argentina) with respect to the limitation of sprintf/printf/stack. (15 bytes compact, 40 bytes large)
This is valid for the TINI400 of 1M.?

Why neither it shouts linker, nor the compilation, with this:

void _DebugProcess_(void) {

	unsigned char	byCnt, byNum;
	char		strVct[16][4];
	char		strOut[64];

        for(byNum = 0x30, byCnt = 0;
            byNum <  0x3A;
            byNum++, byCnt++)
        {

		strVct[byCnt][0] = byNum;
		strVct[byCnt][1] = 0;
	}

	byNum+=7;

	for(; byNum <  0x47;
            byNum++, byCnt++)
        {

		strVct[byCnt][0] = byNum;
		strVct[byCnt][1] = 0;
	}


	sprintf(
	strOut,
	"%s, %s, %s, %s, %s, %s, %s, %s,          %s, %s, %s, %s, %s, %s, %s, %s",
		strVct[0],
		strVct[1],
	        strVct[2],
	        strVct[3],
		strVct[4],
		strVct[5],
		strVct[6],
		strVct[7],
		strVct[8],
		strVct[9],
		strVct[10],
		strVct[11],
		strVct[12],
		strVct[13],
		strVct[14],
		strVct[15]
		); //48 bytes


}


Thanks :)

0