Advertising
- Untitled
- Monday, October 15th, 2007 at 5:02:50am MDT
- Index: bootloader/main-pp.c
- ===================================================================
- --- bootloader/main-pp.c (revision 15109)
- +++ bootloader/main-pp.c (working copy)
- @@ -32,6 +32,7 @@
- #include "button.h"
- #include "disk.h"
- #include "crc32-mi4.h"
- +#include "rockboxlogo.h"
- #include <string.h>
- #if defined(SANSA_E200)
- #include "i2c.h"
- @@ -450,6 +451,23 @@
- }
- #endif
- +int show_logo( void )
- +{
- + char boot_version[32];
- +
- + snprintf(boot_version, sizeof(boot_version), "Boot Ver. %s", version);
- +
- + lcd_clear_display();
- + lcd_bitmap(rockboxlogo, 0, 10, BMPWIDTH_rockboxlogo, BMPHEIGHT_rockboxlogo);
- + lcd_setfont(FONT_SYSFIXED);
- + lcd_putsxy((LCD_WIDTH/2) - ((strlen(boot_version)*SYSFONT_WIDTH)/2),
- + LCD_HEIGHT-SYSFONT_HEIGHT, (unsigned char *)boot_version);
- +
- + lcd_update();
- +
- + return 0;
- +}
- +
- void* main(void)
- {
- int i;
- @@ -471,6 +489,7 @@
- kernel_init();
- lcd_init();
- font_init();
- + show_logo();
- button_init();
- #if defined(SANSA_E200)
- i2c_init();
- Index: bootloader/Makefile
- ===================================================================
- --- bootloader/Makefile (revision 15109)
- +++ bootloader/Makefile (working copy)
- @@ -8,11 +8,31 @@
- #
- INCLUDES= $(TARGET_INC) -I$(FIRMDIR)/include -I$(FIRMDIR)/export -I. -I$(OBJDIR) \
- - -I$(BUILDDIR)
- + -I$(BUILDDIR) -I$(BUILDDIR)/bitmaps
- DEPFILE = $(OBJDIR)/dep-bootloader
- LDS := $(FIRMDIR)/boot.lds
- +# Set up the bitmap libraries
- +BITMAPLIBS =
- +LINKBITMAPS =
- +ifneq ($(strip $(BMP2RB_MONO)),)
- + BITMAPLIBS += $(BUILDDIR)/libbitmapsmono.a
- + LINKBITMAPS += -lbitmapsmono
- +endif
- +ifneq ($(strip $(BMP2RB_NATIVE)),)
- + BITMAPLIBS += $(BUILDDIR)/libbitmapsnative.a
- + LINKBITMAPS += -lbitmapsnative
- +endif
- +ifneq ($(strip $(BMP2RB_REMOTEMONO)),)
- + BITMAPLIBS += $(BUILDDIR)/libbitmapsremotemono.a
- + LINKBITMAPS += -lbitmapsremotemono
- +endif
- +ifneq ($(strip $(BMP2RB_REMOTENATIVE)),)
- + BITMAPLIBS += $(BUILDDIR)/libbitmapsremotenative.a
- + LINKBITMAPS += -lbitmapsremotenative
- +endif
- +
- ifdef DEBUG
- DEFINES := -DDEBUG
- CFLAGS += -g
- @@ -47,6 +67,8 @@
- all: $(BUILDDIR)/$(BINARY) $(FLASHFILE)
- endif
- +$(DEPFILE): $(BITMAPLIBS)
- +
- dep: $(DEPFILE)
- $(LINKFILE): $(LDS)
- @@ -58,9 +80,23 @@
- $(SILENT)cat $(MAXINFILE) | $(CC) -DMEMORYSIZE=$(MEMORYSIZE) $(INCLUDES) $(TARGET) $(DEFINES) -E -P $(ROMBUILD) - > $(MAXOUTFILE)
- $(SILENT)rm $(MAXINFILE)
- -$(OBJDIR)/bootloader.elf : $(OBJS) $(LINKFILE) $(DEPFILE) $(LIBROCKBOX)
- - $(call PRINTS,LD $(@F))$(CC) $(GCCOPTS) -Wl,--gc-sections -Os -nostdlib -o $@ $(OBJS) -L$(BUILDDIR) -L$(BUILDDIR)/firmware -lrockbox -lgcc -T$(LINKFILE) -Wl,-Map,$(OBJDIR)/bootloader.map
- +build-bitmapsmono:
- + $(call PRINTS,MAKE in bitmaps/mono)$(MAKE) -C bitmaps/mono OBJDIR=$(OBJDIR)/bitmaps/mono
- +build-bitmapsnative:
- + $(call PRINTS,MAKE in bitmaps/native)$(MAKE) -C bitmaps/native OBJDIR=$(OBJDIR)/bitmaps/native
- +
- +build-bitmapsremotemono:
- + $(call PRINTS,MAKE in bitmaps/remote_mono)$(MAKE) -C bitmaps/remote_mono OBJDIR=$(OBJDIR)/bitmaps/remote_mono
- +
- +build-bitmapsremotenative:
- + $(call PRINTS,MAKE in bitmaps/remote_native)$(MAKE) -C bitmaps/remote_native OBJDIR=$(OBJDIR)/bitmaps/remote_native
- +
- +$(BITMAPLIBS): $(BUILDDIR)/lib%.a: build-%
- +
- +$(OBJDIR)/bootloader.elf : $(OBJS) $(LINKFILE) $(DEPFILE) $(LIBROCKBOX) $(BITMAPLIBS)
- + $(call PRINTS,LD $(@F))$(CC) $(GCCOPTS) -Wl,--gc-sections -Os -nostdlib -o $@ $(OBJS) -L$(BUILDDIR) -L$(BUILDDIR)/firmware -lrockbox $(LINKBITMAPS) -lgcc -T$(LINKFILE) -Wl,-Map,$(OBJDIR)/bootloader.map
- +
- $(OBJDIR)/bootloader.bin : $(OBJDIR)/bootloader.elf
- $(call PRINTS,OBJCOPY $(@F))$(OC) -O binary $< $@
- @@ -76,5 +112,9 @@
- $(call PRINTS,cleaning bootloader)-rm -f $(OBJS) $(BUILDDIR)/$(BINARY) $(OBJDIR)/bootloader.asm \
- $(OBJDIR)/bootloader.bin $(OBJDIR)/bootloader.elf $(OBJDIR)/*.map \
- $(LINKFILE) $(MAXOUTFILE) $(DEPFILE)
- + $(SILENT)$(MAKE) -C bitmaps/mono clean OBJDIR=$(OBJDIR)/bitmaps/mono
- + $(SILENT)$(MAKE) -C bitmaps/native clean OBJDIR=$(OBJDIR)/bitmaps/native
- + $(SILENT)$(MAKE) -C bitmaps/remote_mono clean OBJDIR=$(OBJDIR)/bitmaps/remote_mono
- + $(SILENT)$(MAKE) -C bitmaps/remote_native clean OBJDIR=$(OBJDIR)/bitmaps/remote_native
- -include $(DEPFILE)
advertising
Update the Post
Either update this post and resubmit it with changes, or make a new post.
You may also comment on this post.
Please note that information posted here will expire by default in one month. If you do not want it to expire, please set the expiry time above. If it is set to expire, web search engines will not be allowed to index it prior to it expiring. Items that are not marked to expire will be indexable by search engines. Be careful with your passwords. All illegal activities will be reported and any information will be handed over to the authorities, so be good.