mirror of
https://github.com/DragonOS-Community/DragonOS.git
synced 2025-06-19 00:46:31 +00:00
🆕 鼠标驱动(有bug,还不能用)
This commit is contained in:
@ -16,6 +16,7 @@
|
||||
#include "driver/multiboot2/multiboot2.h"
|
||||
#include "driver/acpi/acpi.h"
|
||||
#include "driver/keyboard/keyboard.h"
|
||||
#include "driver/mouse/mouse.h"
|
||||
|
||||
unsigned int *FR_address = (unsigned int *)0xb8000; //帧缓存区的地址
|
||||
|
||||
@ -162,6 +163,7 @@ void system_initialize()
|
||||
|
||||
cpu_init();
|
||||
keyboard_init();
|
||||
mouse_init();
|
||||
// test_slab();
|
||||
// test_mm();
|
||||
|
||||
@ -178,8 +180,23 @@ void Start_Kernel(void)
|
||||
// show_welcome();
|
||||
// test_mm();
|
||||
|
||||
/*
|
||||
while (1)
|
||||
{
|
||||
keyboard_analyze_keycode();
|
||||
struct mouse_packet_3bytes packet = {0};
|
||||
//struct mouse_packet_4bytes packet = {0};
|
||||
int errcode = 0;
|
||||
errcode = mouse_get_packet(&packet);
|
||||
if(errcode == 0)
|
||||
{
|
||||
printk_color(GREEN, BLACK, " (Mouse: byte0:%d, x:%3d, y:%3d)\n", packet.byte0, packet.movement_x, packet.movement_y);
|
||||
//printk_color(GREEN, BLACK, " (Mouse: byte0:%d, x:%3d, y:%3d, byte3:%3d)\n", packet.byte0, packet.movement_x, packet.movement_y, (unsigned char)packet.byte3);
|
||||
}
|
||||
}
|
||||
*/
|
||||
while(1);
|
||||
|
||||
}
|
||||
|
||||
void ignore_int()
|
||||
|
Reference in New Issue
Block a user