* fixed GCC 4.4.0 mingw compilation:
[fw/sdcc] / sim / ucsim / avr.src / inst.cc
index 32809dec91c63cf45920edab8f8226a4965d7f32..5818294f6211b74213c3728822c14f7ce88471eb 100644 (file)
@@ -46,16 +46,32 @@ cl_avr::nop(t_mem code)
 }
 
 
+/*
+ * Sleep
+ * SLEEP
+ * 1001 0101 100X 1000
+ *____________________________________________________________________________
+ */
+
 int
 cl_avr::sleep(t_mem code)
 {
+  sleep_executed= 1;
   return(resGO);
 }
 
 
+/*
+ * Watchdog Reset
+ * WDR
+ * 1001 0101 101X 1000
+ *____________________________________________________________________________
+ */
+
 int
 cl_avr::wdr(t_mem code)
 {
+  //FIXME
   return(resGO);
 }
 
@@ -72,7 +88,7 @@ cl_avr::ser_Rd(t_mem code)
 {
   t_addr d= (code&0xf0)>>4;
   t_mem data= 0xff;
-  ram->write(d, &data);
+  ram->write(d, data);
   return(resGO);
 }