Topics

Sketch too big

joe@...
 

when compiling code for a V6 from https://github.com/reedbn/ubitxv6/ I received this error message

Arduino: 1.8.13 (Windows 10), Board: "Arduino Nano, ATmega328P"
Sketch uses 30750 bytes (100%) of program storage space. Maximum is 30720 bytes.text section exceeds available space in board
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.
Sketch too big; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing it.
Error compiling for board Arduino Nano.

I thought I read this code would fit a V6 kit




option enabled in File -> Preferences.

Jack, W8TEE
 

I just compiled it to 30316 bytes just fine. However, I'm using release 1.8.12.

Jack, W8TEE

On Saturday, June 20, 2020, 3:58:57 PM EDT, joe@... <joe@...> wrote:


when compiling code for a V6 from https://github.com/reedbn/ubitxv6/ I received this error message

Arduino: 1.8.13 (Windows 10), Board: "Arduino Nano, ATmega328P"
Sketch uses 30750 bytes (100%) of program storage space. Maximum is 30720 bytes.text section exceeds available space in board
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.
Sketch too big; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing it.
Error compiling for board Arduino Nano.

I thought I read this code would fit a V6 kit




option enabled in File -> Preferences.

--
Jack, W8TEE

W2CTX
 

I too got same as you Jack with 1.8.12.
So I loaded 1.8.13 and it does give too large error!

rOn

On Saturday, June 20, 2020, 4:10:08 PM EDT, Jack, W8TEE via groups.io <jjpurdum@...> wrote:


I just compiled it to 30316 bytes just fine. However, I'm using release 1.8.12.

Jack, W8TEE

On Saturday, June 20, 2020, 3:58:57 PM EDT, joe@... <joe@...> wrote:


when compiling code for a V6 from https://github.com/reedbn/ubitxv6/ I received this error message

Arduino: 1.8.13 (Windows 10), Board: "Arduino Nano, ATmega328P"
Sketch uses 30750 bytes (100%) of program storage space. Maximum is 30720 bytes.text section exceeds available space in board
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.
Sketch too big; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing it.
Error compiling for board Arduino Nano.

I thought I read this code would fit a V6 kit




option enabled in File -> Preferences.

--
Jack, W8TEE

Bill Cromwell
 

Hi,

I have 8.1.9 and I compiled/installed with that.

73,

Bill KU8H

bark less - wag more

On 6/20/20 3:58 PM, joe@... wrote:
when compiling code for a V6 from https://github.com/reedbn/ubitxv6/ I received this error message
Arduino: 1.8.13 (Windows 10), Board: "Arduino Nano, ATmega328P"
Sketch uses 30750 bytes (100%) of program storage space. Maximum is 30720 bytes.text section exceeds available space in board
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.
Sketch too big; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing it.
Error compiling for board Arduino Nano.
I thought I read this code would fit a V6 kit
option enabled in File -> Preferences.

Jack, W8TEE
 

Man, a 400 byte change is huge. Right now I don't have the time to dig into it, but I'm sure there's got to be a way to pare down some bytes somewhere, or just back off to 1.8.12.

Jack, W8TEE

On Saturday, June 20, 2020, 4:19:15 PM EDT, W2CTX via groups.io <w2ctx@...> wrote:


I too got same as you Jack with 1.8.12.
So I loaded 1.8.13 and it does give too large error!

rOn

On Saturday, June 20, 2020, 4:10:08 PM EDT, Jack, W8TEE via groups.io <jjpurdum@...> wrote:


I just compiled it to 30316 bytes just fine. However, I'm using release 1.8.12.

Jack, W8TEE

On Saturday, June 20, 2020, 3:58:57 PM EDT, joe@... <joe@...> wrote:


when compiling code for a V6 from https://github.com/reedbn/ubitxv6/ I received this error message

Arduino: 1.8.13 (Windows 10), Board: "Arduino Nano, ATmega328P"
Sketch uses 30750 bytes (100%) of program storage space. Maximum is 30720 bytes.text section exceeds available space in board
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.
Sketch too big; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing it.
Error compiling for board Arduino Nano.

I thought I read this code would fit a V6 kit




option enabled in File -> Preferences.

--
Jack, W8TEE

--
Jack, W8TEE

Reed N
 

Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed

 

Some library routines must have become bloated with new "features".
In the old days I wrote library routines in MASM just to shrink code in DOS!

Raj

At 21/06/2020, you wrote:
Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed

Arv Evans
 

Reed & Jack

I wonder if the bloat might be from some of the #includes or maybe 
in an update to the automatically included arduino.h ?  How to find 
where it is coming from may be the real issue.

Next I wonder if it might be overcome by modifying compile parameters 
such as adding more levels of optimization...?

Arv
_._


On Sun, Jun 21, 2020 at 12:04 AM Reed N <greenkid336600+groupsio@...> wrote:
Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed

Jack, W8TEE
 

Arv:

I'm not sure how to address it. One way would be to remove a header file include and measure the 1.8.12 and 1.8.13 sizes to see if the impact is uniform. However, that would not test the core libraries. Also, any observed changes could be in the code generator and not the library itself. It's an interesting problem but, unfortunately, I'm up to my butt in alligators right now and don't have the time to investigate. Maybe later.

Jack, W8TEE

On Sunday, June 21, 2020, 12:31:39 PM EDT, Arv Evans <arvid.evans@...> wrote:


Reed & Jack

I wonder if the bloat might be from some of the #includes or maybe 
in an update to the automatically included arduino.h ?  How to find 
where it is coming from may be the real issue.

Next I wonder if it might be overcome by modifying compile parameters 
such as adding more levels of optimization...?

Arv
_._


On Sun, Jun 21, 2020 at 12:04 AM Reed N <greenkid336600+groupsio@...> wrote:
Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed


--
Jack, W8TEE

W2CTX
 

Played a little:

bands.cpp
#include "bands.h"
//#include "utils.h"


constexpr Band_t bands [] PROGMEM {
//  {       0UL,      255UL, 255, "U8"},//Utility conversion option
//  {       0UL,    65535UL, 254, "UF"},//Utility conversion option
//  {  530000UL,  1700000UL, 253, "AM"},//Broadcast AM, actually centers at 268, but uint8 can't do that
//  { 1800000UL,  2000000UL, 160, "A0"},//0xA0 is 160
  { 3500000UL,  4000000UL,  80, "80"},
  { 5330500UL,  5403500UL,  60, "60"},
  { 7000000UL,  7300000UL,  40, "40"},
  {10100000UL, 10150000UL,  30, "30"},
  {14000000UL, 14350000UL,  20, "20"},
  {18068000UL, 18168000UL,  17, "17"},
  {21000000UL, 21450000UL,  15, "15"},
  {24890000UL, 24990000UL,  12, "12"},
//  {26965000UL, 27405000UL,  11, "CB"},//Citizen's Band
  {28000000UL, 29700000UL,  10, "10"},
};


ubitxv6.ino

//#include <Wire.h>
#include "encoder.h"
#include "menu.h"
#include "menu_main.h"
//#include "morse.h"
#include "pin_definitions.h"
#include "push_button.h"
#include "nano_gui.h"
//#include "settings.h"
#include "setup.h"
#include "si5351.h"
#include "touch.h"
#include "tuner.h"
#include "ui_touch.h"


results 1.8.13:

Sketch uses 30694 bytes (99%) of program storage space. Maximum is 30720 bytes.
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.




On Sunday, June 21, 2020, 2:04:06 AM EDT, Reed N <greenkid336600+groupsio@...> wrote:


Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed

Jack, W8TEE
 

Hmmm...that leaves 26t bytes unused. Can you run it?

Jack, W8TEE

On Sunday, June 21, 2020, 2:18:28 PM EDT, W2CTX via groups.io <w2ctx@...> wrote:


Played a little:

bands.cpp
#include "bands.h"
//#include "utils.h"


constexpr Band_t bands [] PROGMEM {
//  {       0UL,      255UL, 255, "U8"},//Utility conversion option
//  {       0UL,    65535UL, 254, "UF"},//Utility conversion option
//  {  530000UL,  1700000UL, 253, "AM"},//Broadcast AM, actually centers at 268, but uint8 can't do that
//  { 1800000UL,  2000000UL, 160, "A0"},//0xA0 is 160
  { 3500000UL,  4000000UL,  80, "80"},
  { 5330500UL,  5403500UL,  60, "60"},
  { 7000000UL,  7300000UL,  40, "40"},
  {10100000UL, 10150000UL,  30, "30"},
  {14000000UL, 14350000UL,  20, "20"},
  {18068000UL, 18168000UL,  17, "17"},
  {21000000UL, 21450000UL,  15, "15"},
  {24890000UL, 24990000UL,  12, "12"},
//  {26965000UL, 27405000UL,  11, "CB"},//Citizen's Band
  {28000000UL, 29700000UL,  10, "10"},
};


ubitxv6.ino

//#include <Wire.h>
#include "encoder.h"
#include "menu.h"
#include "menu_main.h"
//#include "morse.h"
#include "pin_definitions.h"
#include "push_button.h"
#include "nano_gui.h"
//#include "settings.h"
#include "setup.h"
#include "si5351.h"
#include "touch.h"
#include "tuner.h"
#include "ui_touch.h"


results 1.8.13:

Sketch uses 30694 bytes (99%) of program storage space. Maximum is 30720 bytes.
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.




On Sunday, June 21, 2020, 2:04:06 AM EDT, Reed N <greenkid336600+groupsio@...> wrote:


Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed

--
Jack, W8TEE

W2CTX
 

Actually I proved nothing except making the bands smaller allows it to compile!
There is still lib issue of size!

rOn

On Sunday, June 21, 2020, 2:18:29 PM EDT, W2CTX via groups.io <w2ctx@...> wrote:


Played a little:

bands.cpp
#include "bands.h"
//#include "utils.h"


constexpr Band_t bands [] PROGMEM {
//  {       0UL,      255UL, 255, "U8"},//Utility conversion option
//  {       0UL,    65535UL, 254, "UF"},//Utility conversion option
//  {  530000UL,  1700000UL, 253, "AM"},//Broadcast AM, actually centers at 268, but uint8 can't do that
//  { 1800000UL,  2000000UL, 160, "A0"},//0xA0 is 160
  { 3500000UL,  4000000UL,  80, "80"},
  { 5330500UL,  5403500UL,  60, "60"},
  { 7000000UL,  7300000UL,  40, "40"},
  {10100000UL, 10150000UL,  30, "30"},
  {14000000UL, 14350000UL,  20, "20"},
  {18068000UL, 18168000UL,  17, "17"},
  {21000000UL, 21450000UL,  15, "15"},
  {24890000UL, 24990000UL,  12, "12"},
//  {26965000UL, 27405000UL,  11, "CB"},//Citizen's Band
  {28000000UL, 29700000UL,  10, "10"},
};


ubitxv6.ino

//#include <Wire.h>
#include "encoder.h"
#include "menu.h"
#include "menu_main.h"
//#include "morse.h"
#include "pin_definitions.h"
#include "push_button.h"
#include "nano_gui.h"
//#include "settings.h"
#include "setup.h"
#include "si5351.h"
#include "touch.h"
#include "tuner.h"
#include "ui_touch.h"


results 1.8.13:

Sketch uses 30694 bytes (99%) of program storage space. Maximum is 30720 bytes.
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.




On Sunday, June 21, 2020, 2:04:06 AM EDT, Reed N <greenkid336600+groupsio@...> wrote:


Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed

W2CTX
 

No I only have the Teensy T4


On Sunday, June 21, 2020, 2:27:44 PM EDT, Jack, W8TEE via groups.io <jjpurdum@...> wrote:


Hmmm...that leaves 26t bytes unused. Can you run it?

Jack, W8TEE

On Sunday, June 21, 2020, 2:18:28 PM EDT, W2CTX via groups.io <w2ctx@...> wrote:


Played a little:

bands.cpp
#include "bands.h"
//#include "utils.h"


constexpr Band_t bands [] PROGMEM {
//  {       0UL,      255UL, 255, "U8"},//Utility conversion option
//  {       0UL,    65535UL, 254, "UF"},//Utility conversion option
//  {  530000UL,  1700000UL, 253, "AM"},//Broadcast AM, actually centers at 268, but uint8 can't do that
//  { 1800000UL,  2000000UL, 160, "A0"},//0xA0 is 160
  { 3500000UL,  4000000UL,  80, "80"},
  { 5330500UL,  5403500UL,  60, "60"},
  { 7000000UL,  7300000UL,  40, "40"},
  {10100000UL, 10150000UL,  30, "30"},
  {14000000UL, 14350000UL,  20, "20"},
  {18068000UL, 18168000UL,  17, "17"},
  {21000000UL, 21450000UL,  15, "15"},
  {24890000UL, 24990000UL,  12, "12"},
//  {26965000UL, 27405000UL,  11, "CB"},//Citizen's Band
  {28000000UL, 29700000UL,  10, "10"},
};


ubitxv6.ino

//#include <Wire.h>
#include "encoder.h"
#include "menu.h"
#include "menu_main.h"
//#include "morse.h"
#include "pin_definitions.h"
#include "push_button.h"
#include "nano_gui.h"
//#include "settings.h"
#include "setup.h"
#include "si5351.h"
#include "touch.h"
#include "tuner.h"
#include "ui_touch.h"


results 1.8.13:

Sketch uses 30694 bytes (99%) of program storage space. Maximum is 30720 bytes.
Global variables use 819 bytes (39%) of dynamic memory, leaving 1229 bytes for local variables. Maximum is 2048 bytes.




On Sunday, June 21, 2020, 2:04:06 AM EDT, Reed N <greenkid336600+groupsio@...> wrote:


Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed

--
Jack, W8TEE

Arv Evans
 

Jack

Okay.  When we see you wearing alligator shoes we can assume that the 
gators have been tamed and you are ready for other problems!  8-)

Arv
_._



On Sun, Jun 21, 2020 at 12:02 PM Jack, W8TEE via groups.io <jjpurdum=yahoo.com@groups.io> wrote:
Arv:

I'm not sure how to address it. One way would be to remove a header file include and measure the 1.8.12 and 1.8.13 sizes to see if the impact is uniform. However, that would not test the core libraries. Also, any observed changes could be in the code generator and not the library itself. It's an interesting problem but, unfortunately, I'm up to my butt in alligators right now and don't have the time to investigate. Maybe later.

Jack, W8TEE

On Sunday, June 21, 2020, 12:31:39 PM EDT, Arv Evans <arvid.evans@...> wrote:


Reed & Jack

I wonder if the bloat might be from some of the #includes or maybe 
in an update to the automatically included arduino.h ?  How to find 
where it is coming from may be the real issue.

Next I wonder if it might be overcome by modifying compile parameters 
such as adding more levels of optimization...?

Arv
_._


On Sun, Jun 21, 2020 at 12:04 AM Reed N <greenkid336600+groupsio@...> wrote:
Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed


--
Jack, W8TEE

Jack, W8TEE
 

Emoji

On Sunday, June 21, 2020, 3:03:22 PM EDT, Arv Evans <arvid.evans@...> wrote:


Jack

Okay.  When we see you wearing alligator shoes we can assume that the 
gators have been tamed and you are ready for other problems!  8-)

Arv
_._



On Sun, Jun 21, 2020 at 12:02 PM Jack, W8TEE via groups.io <jjpurdum=yahoo.com@groups.io> wrote:
Arv:

I'm not sure how to address it. One way would be to remove a header file include and measure the 1.8.12 and 1.8.13 sizes to see if the impact is uniform. However, that would not test the core libraries. Also, any observed changes could be in the code generator and not the library itself. It's an interesting problem but, unfortunately, I'm up to my butt in alligators right now and don't have the time to investigate. Maybe later.

Jack, W8TEE

On Sunday, June 21, 2020, 12:31:39 PM EDT, Arv Evans <arvid.evans@...> wrote:


Reed & Jack

I wonder if the bloat might be from some of the #includes or maybe 
in an update to the automatically included arduino.h ?  How to find 
where it is coming from may be the real issue.

Next I wonder if it might be overcome by modifying compile parameters 
such as adding more levels of optimization...?

Arv
_._


On Sun, Jun 21, 2020 at 12:04 AM Reed N <greenkid336600+groupsio@...> wrote:
Well that's annoying. Since obviously the code didn't change between Arduino versions, that means there's 400 bytes of extra Arduino bloat being built into the new version! :/


Reed


--
Jack, W8TEE


--
Jack, W8TEE