diff -Naur ./src/Stk500.C ../uisp/src/Stk500.C
--- ./src/Stk500.C	2004-02-07 20:12:33.000000000 +0100
+++ ../uisp/src/Stk500.C	2004-07-02 04:51:17.934963728 +0200
@@ -77,7 +77,7 @@
 const TByte TStk500::ExtDevParams_Reply[] = { 0x14, 0x10 };
 
 /* FIXME: troth/2002-10-02: Get rid of all these magic numbers now that we
-   know what they mean. (See REAME.stk500) */
+   know what they mean. (See README.stk500) */
 
 TStk500::SPrgPart TStk500::prg_part[] = {
   {"AT90S4414",
@@ -278,26 +278,47 @@
 TByte TStk500::ReadByte(TAddr addr)
 {
   TByte val = 0xff;
-
+  // STK500 command: read_fuse_bits
+  TByte buf[4] = { 0x72, 0x20 };
+  // STK500 command: read_lock_bits
+  TByte buf1[3] = { 0x73, 0x20 };
+  
   if (segment == SEG_FUSE)
   {
     switch (addr) 
     {
       case AVR_FUSE_LOW_ADDR:
-        if (TestFeatures(AVR_FUSE_RD))
+		// special case for ATtiny11 fuses (quick job here. not optimum but works. :(
+		if(vendor_code == 0x1e && part_family == 0x90 && part_number == 0x4) {
+  		 EnterProgrammingMode();
+		 Send(buf, 2, 4);
+		 if(buf[1] == 0x10) {
+		  Info (1, "Cannot read low fuse bits on this device. "
+                "Returning 0xff\n");
+		 }
+		 else {
+		  // tiny11 has 5 fuse bits (%000XXXXX)
+		  val = buf[1] | 0xE0; 
+		 }
+		 break;
+		}
+		// any other case (not tiny11)
+		else {
+         if (TestFeatures(AVR_FUSE_RD))
           val = ReadFuseLowBits();
-        else
+         else
           Info (1, "Cannot read low fuse bits on this device. "
                 "Returning 0xff\n");
+		}
         break;
 
       case AVR_FUSE_HIGH_ADDR:
-        if (TestFeatures(AVR_FUSE_HIGH))
+	    if (TestFeatures(AVR_FUSE_HIGH))
           val = ReadFuseHighBits();
         else
           Info (1, "Cannot read high fuse bits on this device. "
                 "Returning 0xff\n");
-        break;
+		break;
 
       case AVR_CAL_ADDR:
         if (TestFeatures(AVR_CAL_RD))
@@ -308,13 +329,28 @@
         break;
 
       case AVR_LOCK_ADDR:
-        val = ReadLockBits();
+		// special case for ATtiny11 fuses (quick job here. not optimum but works. :(
+	    if(vendor_code == 0x1e && part_family == 0x90 && part_number == 0x4) {
+         Send(buf1, 2, 3);
+		 LeaveProgrammingMode();
+	 	 if(buf1[1] == 0x10) {
+		  Info (1, "Error reading lock-bits...\n");
+		 }
+		 else {
+		  // tiny11 has two lock-bits (%00000XX0)
+		  val = buf1[1] | 0xF9; 
+		 }
+		 break;
+		}
+		else {
+ 		 val = ReadLockBits();
+		}
         break;
 
       case AVR_FUSE_EXT_ADDR:
-        if (TestFeatures(AVR_FUSE_EXT))
+		 if (TestFeatures(AVR_FUSE_EXT))
           val = ReadFuseExtBits();
-        else
+         else
           Info (1, "Cannot read extended fuse bits on this device. "
                 "Returning 0xff\n");
         break;
@@ -337,23 +373,38 @@
 /* Write byte to active segment */
 void TStk500::WriteByte(TAddr addr, TByte byte, bool flush_buffer)
 {
+  // STK500 command: write_fuse_bits
+  TByte buf[4] = { 0x62, 0x0, 0x0, 0x20 };
+  
   if (segment == SEG_FUSE)
   {
     switch (addr) 
     {
       case AVR_FUSE_LOW_ADDR:
+	   // special case for ATtiny11 fuses (quick job here. not optimum but works. :(
+	   if(vendor_code == 0x1e && part_family == 0x90 && part_number == 0x4) {
+		EnterProgrammingMode();
+		// set high fuse-bit always 0xFF on tiny11 (& tiny12)
+		buf[2] = 0xFF;
+		// let the user set only the 5 relevant bits
+	    buf[1] = byte | 0xE0;
+		Send(buf, 4, 2);
+		LeaveProgrammingMode();
+	   }
+	   else {
         if (TestFeatures(AVR_FUSE_RD))
           WriteFuseLowBits(byte);
         else
           Info (1, "Cannot write low fuse bits on this device.\n");
-        break;
+	   }
+       break;
 
       case AVR_FUSE_HIGH_ADDR:
-        if (TestFeatures(AVR_FUSE_HIGH))
+	    if (TestFeatures(AVR_FUSE_HIGH))
           WriteFuseHighBits(byte);
         else
           Info (1, "Cannot write high fuse bits on this device.\n");
-        break;
+	    break;
 
       case AVR_CAL_ADDR:
         /* Calibration byte is always readonly. */
@@ -514,9 +565,9 @@
 
 TByte TStk500::ReadFuseLowBits()
 {
-  TByte cmd[] = { 0x50, 0x00, 0x00, 0x00 };
-
-  return UniversalCmd(cmd);
+   TByte cmd[] = { 0x50, 0x00, 0x00, 0x00 };
+   return UniversalCmd(cmd);
+  
 }
 
 
@@ -686,7 +737,7 @@
 
   /* Expected response is { 0x14, <output>, 0x10 } */
   Send(buf, sizeof(buf), 3);
-
+ 
   LeaveProgrammingMode();
 
   if ((buf[0] != 0x14) || (buf[2] != 0x10))
