See "C WITHOUT RAM" section of this 2006 article named "Tiny AVR Serial Port Programmer".

...and this Webpage...

Compiling C-code for an AVR like the ATtiny2313 with few resources---and zero SRAM---is indeed practical.

But today STMicro sells tiny 32-bit STM32 ARM microcontroller chips (e.g., STM32L021D4P7, 5mm x 6mm TSSOP-14) with plenty of program flash and SRAM for under $1 US.  STM even claims "32-bits for 32-cents" in large volumes for their ARM Cortex chips.

Best regards,


On 6/4/2018 7:35 PM, Erik Christiansen wrote:

On 04.06.18 19:19, Benoit Steinmetz wrote:
p.s:  I have recently started a topic on avrfreaks about this issue [2].
Your link has caused me to visit avrfreaks for the second time in a
decade, leading me to wonder if answers would appear here. Normally I'd
point to the useful software admonition "Be conservative in what you
output, and liberal in tolerance of input.", but I see that your target
is an ATtiny2313. With only 1K instructions available, I'm surprised
to see any 'C' used at all, and understand the desire to trim every
superfluous instruction.

One question: Does the omission of sign extension by avr-gcc remain
without optimisation for size?

My current project, also on an ATtiny2313, is 100% assembler -
simplified event scheduler, state machines, HAL, the lot. But at least
you could fall back to an ATtiny4313 if the 'C' blows out, I guess.


AVR-GCC-list mailing list

*Bruce D. Lightner*
*Lightner Engineering*
8551 La Jolla Shores Drive
La Jolla, California 92037-3044
Mobile/SMS: +1-858-228-7579
Voice: +1-858-551-0770 ext. 2

/CONFIDENTIALITY NOTICE: This e-mail and any attachments may contain confidential information intended solely for the use of the addressee. If the reader of this message is not the intended recipient, any distribution, copying, or use of this e-mail or its attachments is prohibited. If you received this message in error, please notify the sender immediately by e-mail and delete this message and any copies. Thank you./
AVR-GCC-list mailing list

Reply via email to