Changeset 368 for trunk/softs/tsar_boot


Ignore:
Timestamp:
Apr 16, 2013, 5:33:46 PM (11 years ago)
Author:
cfuguet
Message:

Modification in tsar/trunk/softs/tsar_boot

Writing the carriage return ('\r')character whenever the
line feed character ('\n') is written on the tty.
This modification has been implemented in the boot_putc
function.

Relocating the ldscript of the tsar_boot into each platform
conf directory.

Location:
trunk/softs/tsar_boot
Files:
2 added
1 deleted
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/softs/tsar_boot/Makefile

    r293 r368  
    7070all: $(TARGET)
    7171
    72 $(TARGET): $(BUILD_DIR) $(OBJS) conf/ldscript $(BUILD_DIR)/platform.ld
     72$(TARGET): $(BUILD_DIR) $(OBJS) $(PLATFORM_DIR)/ldscript $(BUILD_DIR)/platform.ld
    7373        $(ECHO) "[   LD   ]     $@"
    74         $(LD) -o $@ -T conf/ldscript $(OBJS)
     74        $(LD) -o $@ -T $(PLATFORM_DIR)/ldscript $(OBJS)
    7575        $(DU) -D $@ > $@.txt
    7676
  • trunk/softs/tsar_boot/src/boot_tty.c

    r348 r368  
    1414void boot_putc(const char c)
    1515{
    16         unsigned int* tty_address = (unsigned int*) TTY_BASE;
    17         iowrite32(&tty_address[TTY_WRITE], (unsigned int)c);
     16    unsigned int* tty_address = (unsigned int*) TTY_BASE;
     17    iowrite32(&tty_address[TTY_WRITE], (unsigned int)c);
     18
     19    if (c == '\n')
     20    {
     21        iowrite32(&tty_address[TTY_WRITE], (unsigned int)'\r');
     22    }
    1823}
    1924
     
    2530    {
    2631        if (buffer[n] == 0) break;
     32
    2733        boot_putc(buffer[n]);
    2834    }
     
    7480void boot_exit()
    7581{
    76     static const char exit_str[] = "\n\r!!! Exit Processor ";
    77     static const char eol_str[] = " !!!\n\r";
    78 
    7982    register int pid;
    8083    asm volatile( "mfc0 %0, $15, 1": "=r"(pid) );
    8184
    82     boot_puts(exit_str);
     85    boot_puts("\n!!! Exit Processor ");
    8386    boot_putx(pid);
    84     boot_puts(eol_str);
     87    boot_puts(" !!!\n");
    8588
    8689    while(1) asm volatile("nop");   // infinite loop...
Note: See TracChangeset for help on using the changeset viewer.