Commit eefcaf758eec7b34287f86f99a5d7d60de28654c
authorJakob Gruber <jakob.gruber@gmail.com>
Thu, 2 Aug 2012 08:33:06 +0000 (10:33 +0200)
committerJakob Gruber <jakob.gruber@gmail.com>
Fri, 10 Aug 2012 14:17:20 +0000 (16:17 +0200)
simavr/sim/avr_eeprom.c

index eccedbe7c495c0455abfe059f4a0b4d6cdf3bde0..376cec84e5129ee4713330cf27165c1edf8dee65 100644 (file)
@@ -88,18 +88,18 @@ static int avr_eeprom_ioctl(struct avr_io_t * port, uint32_t ctl, void * io_para
                case AVR_IOCTL_EEPROM_SET: {
                        avr_eeprom_desc_t * desc = (avr_eeprom_desc_t*)io_param;
                        if (!desc || !desc->size || !desc->ee || (desc->offset + desc->size) > p->size) {
-                               printf("%s: AVR_IOCTL_EEPROM_SET Invalid argument\n",
+                               AVR_LOG(port->avr, LOG_WARNING, "EEPROM: %s: AVR_IOCTL_EEPROM_SET Invalid argument\n",
                                                __FUNCTION__);
                                return -2;
                        }
                        memcpy(p->eeprom + desc->offset, desc->ee, desc->size);
-                       printf("%s: AVR_IOCTL_EEPROM_SET Loaded %d at offset %d\n",
+                       AVR_LOG(port->avr, LOG_TRACE, "EEPROM: %s: AVR_IOCTL_EEPROM_SET Loaded %d at offset %d\n",
                                        __FUNCTION__, desc->size, desc->offset);
                }       break;
                case AVR_IOCTL_EEPROM_GET: {
                        avr_eeprom_desc_t * desc = (avr_eeprom_desc_t*)io_param;
                        if (!desc || (desc->offset + desc->size) > p->size) {
-                               printf("%s: AVR_IOCTL_EEPROM_GET Invalid argument\n",
+                               AVR_LOG(port->avr, LOG_WARNING, "EEPROM: %s: AVR_IOCTL_EEPROM_GET Invalid argument\n",
                                                __FUNCTION__);
                                return -2;
                        }