h1x0/h300: remove trailing whitespace from bootloaders

Change-Id: I8f3bfbc8287c8f520894e0cd258066d4c7a02197
This commit is contained in:
James Buren 2020-11-14 14:16:42 +00:00
parent 5a223080fa
commit 37eabbfe51
2 changed files with 72 additions and 72 deletions

View file

@ -89,22 +89,22 @@ void start_firmware(void)
void shutdown(void)
{
printf("Shutting down...");
/* We need to gracefully spin down the disk to prevent clicks. */
if (ide_powered())
{
/* Make sure ATA has been initialized. */
storage_init();
/* And put the disk into sleep immediately. */
storage_sleepnow();
}
sleep(HZ*2);
backlight_hw_off();
remote_backlight_hw_off();
__reset_cookie();
power_off();
}
@ -113,14 +113,14 @@ void shutdown(void)
void check_battery(void)
{
int battery_voltage, batt_int, batt_frac;
battery_voltage = _battery_voltage();
batt_int = battery_voltage / 1000;
batt_frac = (battery_voltage % 1000) / 10;
printf("Batt: %d.%02dV", batt_int, batt_frac);
if (battery_voltage <= 310)
if (battery_voltage <= 310)
{
printf("WARNING! BATTERY LOW!!");
sleep(HZ*2);
@ -131,7 +131,7 @@ void check_battery(void)
extern unsigned char pcf50606_intregs[3];
/* From common.c */
extern int line;
extern int line;
extern int remote_line;
void main(void)
@ -187,7 +187,7 @@ void main(void)
/* Start with the main backlight OFF. */
backlight_hw_init();
backlight_hw_off();
remote_backlight_hw_on();
system_init();
@ -202,7 +202,7 @@ void main(void)
adc_init();
button_init();
lcd_init();
lcd_remote_init();
font_init();
@ -222,7 +222,7 @@ void main(void)
if(rtc_alarm)
printf("RTC alarm detected");
/* Don't start if the Hold button is active on the device you
are starting with */
if ((on_button && button_hold()) ||
@ -230,7 +230,7 @@ void main(void)
{
hold_status = true;
}
if (hold_status && !rtc_alarm && (usb_detect() != USB_INSERTED) &&
if (hold_status && !rtc_alarm && (usb_detect() != USB_INSERTED) &&
!charger_inserted())
{
if (detect_original_firmware())
@ -264,7 +264,7 @@ void main(void)
bool request_start = false;
cpu_idle_mode(true);
while(charger_inserted() && !request_start)
{
button = button_get_w_tmo(HZ);
@ -274,7 +274,7 @@ void main(void)
case BUTTON_ON:
request_start = true;
break;
case BUTTON_NONE: /* Timeout */
if(charging_state())
@ -288,7 +288,7 @@ void main(void)
blink_toggle = true;
msg = complete_msg;
}
font_getstringsize(msg, &w, &h, FONT_SYSFIXED);
reset_screen();
if(blink_toggle)
@ -306,7 +306,7 @@ void main(void)
cpu_idle_mode(false);
}
usb_init();
/* A hack to enter USB mode without using the USB thread */
@ -333,7 +333,7 @@ void main(void)
line = 0;
remote_line = 0;
check_battery();
storage_spin(); /* Prevent the drive from spinning down */
sleep(HZ);
}
@ -408,9 +408,9 @@ unsigned short *bidi_l2v(const unsigned char *str, int orientation)
static unsigned short utf16_buf[SCROLL_LINE_SIZE];
unsigned short *target;
(void)orientation;
target = utf16_buf;
while (*str)
str = utf8decode(str, target++);
*target = 0;