mirror of
https://github.com/raphnet/gc_n64_usb-v3
synced 2024-12-22 07:18:52 -05:00
18 lines
250 B
C
18 lines
250 B
C
|
#include <avr/io.h>
|
||
|
#include "usb.h"
|
||
|
|
||
|
void enterBootLoader(void)
|
||
|
{
|
||
|
usb_shutdown();
|
||
|
|
||
|
// AT90USB1287/1286 : 0xF000 (word address)
|
||
|
// ATmega32u2 : ???
|
||
|
asm volatile(
|
||
|
"cli \n"
|
||
|
"ldi r30, 0x00 \n" // ZL
|
||
|
"ldi r31, 0xF0 \n" // ZH
|
||
|
"ijmp");
|
||
|
|
||
|
}
|
||
|
|