STAR Firmware by JonnyC - Source Code and Explanation

We are using GIT at work now, but strictly internal of course, but I'm somewhat familiar, still not comfortable with it. We use TortoiseGit as the UI.

Nice. I tried TortoiseGit, but it was still too confusing. Just started using SourceTree and it makes Git bearable. I still miss my SVN "synchronize" feature so I can see all incoming changes. The whole fetch/pull process frustrates me.

question on the -os command when using avr studio 5.1. where is this setting? obviously using the gui interface of avr studio, im not using a command line interface where i can just type in -os.

i ask because my compiled code hex looks larger than the 1k space of a attiny13a.

thanks

Brian

Brian - by looks large, what do you mean exactly?

Go to Project -> Properties, then click on Toolchain and select Optimization under AVR/GNU C Compiler, select -Os.

1.8k file size

thank you

Yeah, if you don't set the compiler to -Os it comes out way too large.

even set to -os it is still too large. it was 777bytes (base 16) and now its 752 bytes (base 16) which is still 1.8k.

ill start over and build with -os on rather than just rebuilding the existing project.

Brian

Huh. Did you add a lot of stuff to it? It should build just fine, even with a few extra modes added in. This is what it should look like:

yup those are my settings. 1.83kb file size

i added nothing. pasted it into the editor, changed the settings, saved (to make sure the settings would take effect and then built.

Brian

Hmmm. Are you sure you're selecting the AVR/GNU C Compiler and not the AVR/GNU C Linker? Did you delete the initial information that is in the file when you start a new project?

yes and yes

Not sure what's going on then, it should work. Did you create a C executable project for the ATTiny13A? I've never had a compile issue with these settings and I'm also using 5.1.

yes and yes……:slight_smile:

I also can’t get the unedited star firmware to compile under Atmel Studio (V6.1). This is also with the optimization level set for -Os. Is there some other setting somewhere that we are missing?

Error 1 Program Memory Usage : 1036 bytes 101.2 % Full (Memory Overflow)
Data Memory Usage : 50 bytes 78.1 % Full star 0 0 star

I know that some people have had issues with 6.1 not working size wise. The optimization routine must have changed.

i just tried toms revision of the code. it comes out at 1.73k

Gotta be something on your end then, but I don't know what it is. I would try downloading version 5.0 and try again.