mirror of
https://github.com/CTCaer/hekate.git
synced 2024-11-23 02:16:41 +00:00
Various fixes
This commit is contained in:
parent
45ca2938f5
commit
11df6030f9
4 changed files with 10 additions and 7 deletions
|
@ -38,7 +38,7 @@ void set_fan_duty(u32 duty)
|
||||||
gpio_config(GPIO_PORT_S, GPIO_PIN_7, GPIO_MODE_GPIO);
|
gpio_config(GPIO_PORT_S, GPIO_PIN_7, GPIO_MODE_GPIO);
|
||||||
gpio_output_enable(GPIO_PORT_S, GPIO_PIN_7, GPIO_OUTPUT_DISABLE);
|
gpio_output_enable(GPIO_PORT_S, GPIO_PIN_7, GPIO_OUTPUT_DISABLE);
|
||||||
|
|
||||||
PWM(PWM_CONTROLLER_PWM_CSR_1) = PWM_CSR_EN | (1 << 24); // Max PWM to disable fan.
|
PWM(PWM_CONTROLLER_PWM_CSR_1) = PWM_CSR_EN | (0x100 << 16); // Max PWM to disable fan.
|
||||||
|
|
||||||
PINMUX_AUX(PINMUX_AUX_LCD_GPIO2) = 1; // Set source to PWM1.
|
PINMUX_AUX(PINMUX_AUX_LCD_GPIO2) = 1; // Set source to PWM1.
|
||||||
gpio_config(GPIO_PORT_V, GPIO_PIN_4, GPIO_MODE_SPIO); // Fan power mode.
|
gpio_config(GPIO_PORT_V, GPIO_PIN_4, GPIO_MODE_SPIO); // Fan power mode.
|
||||||
|
@ -55,7 +55,7 @@ void set_fan_duty(u32 duty)
|
||||||
// If disabled send a 0 duty.
|
// If disabled send a 0 duty.
|
||||||
if (inv_duty == 236)
|
if (inv_duty == 236)
|
||||||
{
|
{
|
||||||
PWM(PWM_CONTROLLER_PWM_CSR_1) = PWM_CSR_EN | (1 << 24); // Bit 24 is absolute 0%.
|
PWM(PWM_CONTROLLER_PWM_CSR_1) = PWM_CSR_EN | (0x100 << 16); // Bit 24 is absolute 0%.
|
||||||
regulator_disable_5v(REGULATOR_5V_FAN);
|
regulator_disable_5v(REGULATOR_5V_FAN);
|
||||||
|
|
||||||
// Disable fan.
|
// Disable fan.
|
||||||
|
|
|
@ -121,7 +121,8 @@ int parse_fss(launch_ctxt_t *ctxt, const char *path, fss0_sept_t *sept_ctxt)
|
||||||
stock = true;
|
stock = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (stock && ctxt->pkg1_id->kb <= KB_FIRMWARE_VERSION_620 && (!emu_cfg.enabled || h_cfg.emummc_force_disable))
|
bool emummc_disabled = !emu_cfg.enabled || h_cfg.emummc_force_disable;
|
||||||
|
if (stock && ctxt->pkg1_id->kb <= KB_FIRMWARE_VERSION_620 && emummc_disabled)
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -365,7 +365,7 @@ void hos_eks_bis_clear()
|
||||||
se_aes_crypt_ecb(14, 1, eks, sizeof(hos_eks_mbr_t), eks, sizeof(hos_eks_mbr_t));
|
se_aes_crypt_ecb(14, 1, eks, sizeof(hos_eks_mbr_t), eks, sizeof(hos_eks_mbr_t));
|
||||||
|
|
||||||
// Write EKS blob to SD.
|
// Write EKS blob to SD.
|
||||||
memcpy(mbr + 0x60, eks, sizeof(hos_eks_mbr_t));
|
memcpy(mbr + 0x80, eks, sizeof(hos_eks_mbr_t));
|
||||||
hos_eks_rw_try(mbr, true);
|
hos_eks_rw_try(mbr, true);
|
||||||
|
|
||||||
free(eks);
|
free(eks);
|
||||||
|
|
|
@ -359,9 +359,11 @@ void nyx_init_load_res()
|
||||||
load_saved_configuration();
|
load_saved_configuration();
|
||||||
|
|
||||||
FIL fp;
|
FIL fp;
|
||||||
f_open(&fp, "bootloader/sys/res.pak", FA_READ);
|
if (!f_open(&fp, "bootloader/sys/res.pak", FA_READ))
|
||||||
|
{
|
||||||
f_read(&fp, (void *)NYX_RES_ADDR, f_size(&fp), NULL);
|
f_read(&fp, (void *)NYX_RES_ADDR, f_size(&fp), NULL);
|
||||||
f_close(&fp);
|
f_close(&fp);
|
||||||
|
}
|
||||||
|
|
||||||
// If no custom switch icon exists, load normal.
|
// If no custom switch icon exists, load normal.
|
||||||
if (f_stat("bootloader/res/icon_switch_custom.bmp", NULL))
|
if (f_stat("bootloader/res/icon_switch_custom.bmp", NULL))
|
||||||
|
|
Loading…
Reference in a new issue