]> cloudbase.mooo.com Git - z180-stamp.git/blobdiff - avr/cmd_boot.c
Define fifos: msg_tx_fifo, msg_rx_fifo
[z180-stamp.git] / avr / cmd_boot.c
index 58c4f569e276199ed0a1dc7240f61d654972c0f2..17ed746e35edde82ff814d15a2f83f8daa05e17a 100644 (file)
@@ -4,11 +4,11 @@
  */
 #include "common.h"
 #include <stdlib.h>
-#include <util/delay.h>
 #include <avr/pgmspace.h>
 
 #include "command.h"
 #include "z80-if.h"
+//#include "debug.h"
 
 /* ugly hack to get Z180 loadfile into flash memory */
 #define const const FLASH
@@ -32,7 +32,7 @@ static void z80_load_mem(void)
 
                z80_bus_cmd(Request);
                z80_write_block((const FLASH unsigned char *) &hdrom[sec_base],  /* src */
-                               hdrom_address[sec],                  /* dest */
+                               hdrom_address[sec],                  /* dest */
                                hdrom_length_of_sections[sec]);      /* len */
                z80_bus_cmd(Release);
                sec_base+=hdrom_length_of_sections[sec];
@@ -143,34 +143,3 @@ command_ret_t do_restart(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv
        return CMD_RET_SUCCESS;
 }
 
-
-command_ret_t do_clock(cmd_tbl_t *cmdtp, int flag, int argc, char *const argv[])
-{
-       uint32_t freq;
-
-       (void) cmdtp; (void) flag;
-
-       if (argc == 2) {
-               freq = strtoul(argv[1], NULL, 10);
-               if (freq == 0) {
-                       printf_P(PSTR("CPU clock cannot be 0\n"));
-                       return CMD_RET_USAGE;
-               }
-
-               if (freq > F_CPU / 2) {
-                       printf_P(PSTR("Max CPU clock freq. is: %luHz\n"), F_CPU/2);
-                       return CMD_RET_USAGE;
-               }
-
-               if (z80_clock_set(freq) < 0) {
-                       printf_P(PSTR("Setting CPU clock freq. to %luHz failed.\n"),
-                                               freq);
-               }
-       }
-
-       printf_P(PSTR("CPU clock: %luHz\n"), z80_clock_get());
-
-
-       return CMD_RET_SUCCESS;
-}
-