示例#1
0
void fb_print_force(const char* str) {
	size_t len = strlen(str);
	int i;
	for(i = 0; i < len; i++) {
		fb_putc(str[i]);
	}
}
示例#2
0
文件: arch-msm.cpp 项目: haret/haret
static void __preload
QSD8xxxFbPutc(struct fbinfo *fbi, char c)
{
    // Draw the character to the fb as usual
    fb_putc(fbi, c);

    // Only initiate DMA transfer after a newline
    if (c != '\n')
        return;

    // Initiate the DMA transfer to update the display
    QSD8xxxFbDmaData* data = (QSD8xxxFbDmaData*)fbi->putcFuncData;
    if (getMMUReg() & 0x1)
    {
        *(uint32 *)data->fbDmaSize = (fbi->scry << 16) | (fbi->scrx);
        *(uint32 *)data->fbDmaPhysFb = data->fbPhysAddr;
        *(uint32 *)data->fbDmaStride = fbi->scrx * 2;
        *(uint32 *)data->fbDmaStart = 0;
    }
    else
    {
        *(uint32 *)(0xaa200000 + 0x90004) = (fbi->scry << 16) | (fbi->scrx);
        *(uint32 *)(0xaa200000 + 0x90008) = data->fbPhysAddr;
        *(uint32 *)(0xaa200000 + 0x9000c) = fbi->scrx * 2;
        *(uint32 *)(0xaa200000 + 0x00044) = 0;
    }
}
示例#3
0
void fb_print_center(const char* str) {
	int i;
	int pad = (gFbTWidth-strlen(str))/2;
	for(i=0;i<pad;i++) {
		fb_putc(' ');
	}
	fb_print(str);
}
示例#4
0
// Write a positive decimal integer to the screen.
void fb_putui(unsigned int i) {
	if (i == 0) {
		fb_putc('0');
		return;
	}
	char c[32];
	itoa(i,c);
	fb_write(c);
}
示例#5
0
void fb_print(const char* str) {
	if(!gFbDisplayText)
		return;

	unsigned int len = strlen(str);
	int i;
	for(i = 0; i < len; i++) {
		fb_putc(str[i]);
	}
}
示例#6
0
void fb_print_line(char c) {
	int i;
	for(i=0;i<gFbTWidth;i++) {
		fb_putc(c);
	}
}
示例#7
0
// Clear the framebuffer.
void fb_clear() {
	int i;
	for (i = 0; i < FB_NUM_CELLS; ++i) fb_putc(0x20); // Put a whitespace.
}
示例#8
0
文件: debug.c 项目: MrAlert/loadMii
static int dputc (int c) {
	return fb_putc(c);
}