Show Posts
Pages: [1] 2 3 4
1  Forum 2005-2010 (read only) / Troubleshooting / Re: Ethernet + Wire combined = crash!? on: January 26, 2010, 05:45:14 am
There are three kinds of memory on an Arduino:
Flash - where your program code is stored
SRAM - stores variables
EEPROM - memory storage that retains contents without power

Your flash memory usage is 11 KB however your receive buffer goes into RAM not flash! So while you are under the Flash limit, you are exceeding the amount of SRAM. Also take note that some Arduino libraries consume SRAM for buffers (Serial takes 128 bytes, Wire takes 160 bytes).

The memory sizes for each Arduino can be found here:
2  Forum 2005-2010 (read only) / Bugs & Suggestions / Re: arduino with vista on: January 18, 2009, 11:27:00 pm
Nope, no need to replace it with anything. Once I deleted mine the Arduino IDE seems to automatically use the new version.
3  Forum 2005-2010 (read only) / Bugs & Suggestions / Re: arduino with vista on: January 18, 2009, 09:18:16 pm
What you are seeing is Java disabling Vista's Aero Glass. I fixed this by installing the latest Java Runtime Environment ( and then deleting the "java" folder within the Arduino folder.
4  Forum 2005-2010 (read only) / Bugs & Suggestions / Re: Ethernet library : More explanations on: November 19, 2008, 01:59:12 am
Ok just to make it clear that I don't have any Arduino Ethernet shields but I will try and offer my assistance.

Briefly looking at your code, I can see a couple of errors that could be contributing to the unexpected events you are encountering.

1. The line:
client.println("User-Agent: AVR ethernet\r\n");
Should be:
client.println("User-Agent: AVR ethernet");
The extra carriage return and newline characters you have would cause the server to think you have completed your HTTP GET request.

2. You are disconnecting the Client at the wrong time. You should change your "if (client_state==STEP2)" block to be this (the yellow highlighted line is the line I changed):
   if (client_state==STEP2)
  if (client.available()) {
    char c =;
  [glow]else if (!client.connected())[/glow]
  {    Serial.println();


Hope this helps.
5  Forum 2005-2010 (read only) / Syntax & Programs / Re: I2C -- EEPROM testing on: March 21, 2009, 07:41:54 pm
Ahh sorry I should have been more clear.

If you started a write of 32 bytes at 0x11 you would indeed hit the address 0x1F and then wrap around to 0x00.
6  Forum 2005-2010 (read only) / Syntax & Programs / Re: I2C -- EEPROM testing on: March 21, 2009, 07:25:59 pm
For clarification:
The Wire library has a buffer of 32 bytes. This includes the 2 byte write address of the EEPROM, hence the maximum number of data bytes you can write at once is 30 bytes.

The page sizes are, as you say "hardwired".

There's an alternative to using delays with the EEPROM, this technique works for my 24LC256. Simply use this code after writing any bytes to the EEPROM:
do {
} while (Wire.endTransmission() > 0);
7  Forum 2005-2010 (read only) / Syntax & Programs / Re: .noinit section on: August 09, 2008, 06:57:48 am
I am testing with version 0011, are you?
Yes indeed I am. Tried in both Windows Vista and Ubuntu.
8  Forum 2005-2010 (read only) / Syntax & Programs / Re: .noinit section on: August 07, 2008, 11:47:31 pm
To make sure that the linker is finding the library you could try this sketch
Still no success. Compiles and runs fine, just the .noinit variables are reinitialised to 0.
9  Forum 2005-2010 (read only) / Syntax & Programs / Re: .noinit section on: August 07, 2008, 04:21:38 am
You are welcome to try it yourself if you want, the library is here:

You don[ch8217]t need to call any functions in the library, just copy the code to a DateTime directory under  the library directory and #include <DateTime.h>
I gave this a shot with no success smiley-sad. Variables are still 0 after a reset.
Thanks for your help so far. Maybe if could have some more testers we could narrow down what's causing it to not work.
10  Forum 2005-2010 (read only) / Syntax & Programs / Re: .noinit section on: August 06, 2008, 02:56:11 am
Its working, its just that your not printing what you think your printing. try this
Unfortunately it is still not working. I copied your code exactly but I am still getting the same serial output regardless of how many times I reset the board:
Old: 0
New: 1234
11  Forum 2005-2010 (read only) / Syntax & Programs / Re: .noinit section on: August 06, 2008, 01:52:03 am
Not only is the data held through a reset, my USB freeduino board held the data in RAM with the power disconnected for more than 10 seconds.
So it is working for you?

Here is my test sketch:
int savedFlag __attribute__ ((section(".noinit")));

void setup() {
  Serial.print("Old: ");
  savedFlag = 1234;
  Serial.print("New: ");

void loop() {
However every time after reset the value of savedFlag is always 0 (it is as if the .noinit section is not working).

I am using an Arduino Diecimila board on arduino-0011. I have tried using Windows Vista Ultimate 64-bit and Ubuntu 8.04 with the same results.
Is the bootloader that is causing issues?
12  Forum 2005-2010 (read only) / Syntax & Programs / Re: .noinit section on: August 05, 2008, 05:44:29 am
I think you're possibly being overly cautious about wearing out EEPROM.
Yes you are probably right.

How often is the reset and/or variable change likely to occur?
I wanted to keep the current time in seconds across resets, however I should be getting a real-time clock soon (which also has 50-odd bytes of battery-backed RAM) so I won't need to worry about using the EEPROM at all.

So while I no longer need the .noinit section, it might be beneficial to other users.
13  Forum 2005-2010 (read only) / Syntax & Programs / .noinit section on: August 01, 2008, 03:12:02 am
I was reading about the .noinit section here:
I tried to get it working in an Arduino sketch however my variables keep being initialized to 0.
I want to use it to retain some variables in RAM across resets as it would be better than wearing out the EEPROM by doing excessive writes.

Does any one know how to get it working? Thanks.
14  Forum 2005-2010 (read only) / Interfacing / Re: Compile Serproxy in Visual Studio 8 on: May 01, 2009, 10:13:55 pm
I managed to compile serproxy in Visual C++ 2008 Express. It seems the serproxy.dsp file had UNIX line endings and not Windows ones.

I applied the fix for the COM ports limit (, and a binary version can be downloaded from here:
15  Forum 2005-2010 (read only) / Development / Re: dual-protocol bootloader? on: January 22, 2010, 05:53:00 am
It seems to me that the main difference between the 1k bootloader and the original one is that the 1k version assumes all the pages written to flash always come in order, and in blocks equal to the device Flash page size. Is it a reasonable assumption?
Yes that's how it is.
Although I don't think it was intentional. It should have used the address sent in the 'U' command. Maybe it was overlooked or wouldn't fit in 1K. Regardless, it seems to be working fine with Arduino's avrdude uploader.
Pages: [1] 2 3 4