Yikes!  trouble uploading

Ok now this is the first time I have ever tried anything like this … i.e. using a device like this to do anything.

I had it all connected and on trying to upload my sketch i get errors. I have disconnected all wires but the USB as instructed in the troubleshooting section. Still no go.

I get these errors.

avrdude: stk500_getsync(): not in sync: resp=0x30
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x51

I haven’t a clue what the problem is … so in case it is a problem with my sketch … here it is.

#include <Wire.h>

#define CG (B1010000)
boolean resetSuccess = false;
int isReset = 13;

int byteArray = {01, 01, 01, 60, 60, 60, 60, 60, 60, 8, 8, 8, 33, 33, 33, 255};

void setup()
{
pinMode(isReset, OUTPUT);
digitalWrite(isReset, LOW);

Wire.begin(); // join i2c bus (address optional for master)
}

void loop()
{
if (resetSuccess)
{
delay (2000); // our work is done - pause for a while
resetSuccess = false;
} else {
resetCartridge();
resetSuccess = verifyCartridge();
digitalWrite(isReset, resetSuccess);
}
}

void resetCartridge()
{
for (int i=3; i < sizeof(byteArray)/2; i++)
{
Wire.beginTransmission(CG);
Wire.send(i);
Wire.send(byteArray*);*

  • Wire.endTransmission();*
  • delay(4);*
  • }*
    }
    void movePointerTo(int deviceAddr, int memoryAddr)
    {
  • Wire.beginTransmission(deviceAddr);*
  • Wire.send(memoryAddr);*
  • Wire.endTransmission();*
    }
    boolean verifyCartridge()
    {
  • boolean success = true;*
  • movePointerTo(CG, 3);*
  • Wire.requestFrom(CG, 3);*
  • while (Wire.available())*
  • {*
  • if (Wire.receive() == 60 && success == true)*
  • {*
  • // looking good so far*
  • } else {*
  • success = false;*
  • }*
  • }*
  • return success;*
    }

OK ... sorry ... when all else fails read the directions. I hadn't allowed it to install whatever it wanted to install.

It is uploading now without error.

don't know if it is working at the moment ... but it is uploading the sketch.