jung6717 / arduino

Automatically exported from code.google.com/p/arduino
0 stars 0 forks source link

Bugs in ArduinoISP #265

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I have picked up a couple of obvious bugs in ArduinoISP. While they may not
be an issue now (I dont have anything bigger than a 328 to test), this
could be a problem on bigger chips like the 644 and 1280.

Code:

typedef struct param {
  uint8_t devicecode;
  uint8_t revision;
  uint8_t progtype;
  uint8_t parmode;
  uint8_t polling;
  uint8_t selftimed;
  uint8_t lockbytes;
  uint8_t fusebytes;
  int flashpoll;
  int eeprompoll;
  int pagesize;
  int eepromsize;
  int flashsize;
}  

* flashpoll could and should be uint8_t
* eeprompoll should be uint16_t (i assume time cant be negative)
* pagesize and eepromsize should be uint16_t (i assume size cant be less
than 0)
* flashsize should be uint32_t given it expects 4 bytes, again cant be less
than zero

The biggest potential problem is with flashsize, as currently it limits it
to 32kb.

Original issue reported on code.google.com by xacc....@gmail.com on 26 May 2010 at 6:01

GoogleCodeExporter commented 9 years ago

Original comment by dmel...@gmail.com on 29 Dec 2011 at 8:26

GoogleCodeExporter commented 9 years ago
Suggested changed available in https://github.com/rsbohn/ArduinoISP. Will 
submit to the Arduino project.

Original comment by rsb...@gmail.com on 18 Feb 2012 at 3:23