| 230 | |
| 231 | |
| 232 | void control_reset(void) { |
| 233 | memset(&control.ports, 0, sizeof control.ports); |
| 234 | |
| 235 | control.privileged = 0xFFFFFF; |
| 236 | control.protectedStart = control.protectedEnd = 0xD1887C; |
| 237 | control.protectionStatus = 0; |
| 238 | control.stackLimit = 0; |
| 239 | control.cpuSpeed = 0; |
| 240 | control.flashUnlocked = false; |
| 241 | control.protectedPortsUnlocked = false; |
| 242 | control.off = false; |
| 243 | control.ports[0xF] = 0x2; |
| 244 | |
| 245 | gui_console_printf("[CEmu] Control reset.\n"); |
| 246 | } |
| 247 | |
| 248 | bool control_save(FILE *image) { |
| 249 | return fwrite(&control, sizeof(control), 1, image) == 1; |
nothing calls this directly
no test coverage detected