diff --git a/downloader/downloader.c b/downloader/downloader.c index 41837dc..605f7d4 100644 --- a/downloader/downloader.c +++ b/downloader/downloader.c @@ -10,9 +10,8 @@ #define redbus 0x0300 -void download_file(char* file) { +void download_file() { unsigned int i; - unsigned int x; con->cursor_mode = 0; conprint("Downloading file, please wait warmly.", 0, 6); rb_map_device(0x05); @@ -53,8 +52,8 @@ void main() { conprint("Internet Disk Retrieval System V1.3", 0, 0); conprint("Please remove disk now", 0, 1); conprint("Enter a URL to download from: ", 0, 2); - con->cursor_y = 3; - strcpy(buffer, read_keyboard()); + con->cursor_y = 3; + strcpy(buffer, read_keyboard()); conprint("You are trying to download a file from: ", 0, 3); conprint(buffer, 0, 4); con->cursor_x = 23; @@ -63,7 +62,7 @@ void main() { memset(ynbuf, 0, 50); strcpy(ynbuf, read_keyboard()); if(ynbuf[0] == 'Y' || ynbuf[0] == 'y') { - download_file(buffer); + download_file(); } else{ conprint("Download cancelled", 0, 6); } diff --git a/include/extensions.h b/include/extensions.h new file mode 100644 index 0000000..6fcd63e --- /dev/null +++ b/include/extensions.h @@ -0,0 +1,20 @@ +#ifndef EXTENSIONS_H +#define EXTENSIONS_H +extern void wait(); +extern void stop(); + +void sleep_ticks(int n){ + unsigned int i; + for(i = 0; i < n; ++i){ + wait(); + } +} + +void sleep_seconds(int n){ + unsigned int i; + for(i = 0; i < n * 20; ++i){ + wait(); + } +} + +#endif \ No newline at end of file