these payloads may not work , i have no clue honestly i attached them , also there are 2 helper py scripts that might work with some of these payloads
26 lines
573 B
C
26 lines
573 B
C
#include <stdint.h>
|
|
|
|
#define WDT_RESTART 0x6000501c
|
|
#define PMC_SCRATCH0 0x7000e450
|
|
#define BOOTROM_USB_SEND 0x000035e5 // Low-level raw send function
|
|
|
|
typedef void (*usb_send_raw_fn)(void *buffer, uint32_t length);
|
|
|
|
void _start() {
|
|
*(volatile uint32_t *)WDT_RESTART = 0xcafe;
|
|
|
|
*(volatile uint32_t *)PMC_SCRATCH0 = 0xdeadbeef;
|
|
|
|
char msg[] = "JIBOWORKS";
|
|
|
|
usb_send_raw_fn send_to_pc = (usb_send_raw_fn)BOOTROM_USB_SEND;
|
|
|
|
send_to_pc(msg, 10);
|
|
|
|
while (1) {
|
|
*(volatile uint32_t *)WDT_RESTART = 0xcafe;
|
|
for (volatile int i = 0; i < 10000; i++)
|
|
;
|
|
}
|
|
}
|