examples: Even more coding-style fixes.

This commit is contained in:
Uwe Hermann
2011-11-13 17:07:21 +01:00
parent c3fea659d1
commit bb8741a79b
31 changed files with 157 additions and 175 deletions

View File

@@ -159,7 +159,7 @@ void dogm128_update_display(void)
u8 page, column;
/* Tell the display that we want to start. */
spi_set_nss_low(DOGM128_SPI);
spi_set_nss_low(DOGM128_SPI);
for (page = 0; page <= 7; page++) {
dogm128_send_command(0xB0 + page); /* Set page. */

View File

@@ -33,24 +33,24 @@ void gpio_setup(void)
/* Set GPIO6/7 (in GPIO port B) to 'output push-pull' for the LEDs. */
gpio_set_mode(GPIOB, GPIO_MODE_OUTPUT_2_MHZ,
GPIO_CNF_OUTPUT_PUSHPULL, GPIO6);
GPIO_CNF_OUTPUT_PUSHPULL, GPIO6);
gpio_set_mode(GPIOB, GPIO_MODE_OUTPUT_2_MHZ,
GPIO_CNF_OUTPUT_PUSHPULL, GPIO7);
GPIO_CNF_OUTPUT_PUSHPULL, GPIO7);
/* A0 of DOGM128 */
gpio_set_mode(GPIOB, GPIO_MODE_OUTPUT_50_MHZ,
GPIO_CNF_OUTPUT_PUSHPULL, GPIO14);
GPIO_CNF_OUTPUT_PUSHPULL, GPIO14);
/* Reset of DOGM128 */
gpio_set_mode(GPIOB, GPIO_MODE_OUTPUT_50_MHZ,
GPIO_CNF_OUTPUT_PUSHPULL, GPIO10);
GPIO_CNF_OUTPUT_PUSHPULL, GPIO10);
/* DOGM128/SPI2 clock and MOSI and NSS(CS1) */
gpio_set_mode(GPIOB, GPIO_MODE_OUTPUT_50_MHZ,
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO12);
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO12);
gpio_set_mode(GPIOB, GPIO_MODE_OUTPUT_50_MHZ,
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO13);
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO13);
gpio_set_mode(GPIOB, GPIO_MODE_OUTPUT_50_MHZ,
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO15);
GPIO_CNF_OUTPUT_ALTFN_PUSHPULL, GPIO15);
}
void spi_setup(void)