diff options
author | inmarket <andrewh@inmarket.com.au> | 2013-12-21 13:21:59 +1000 |
---|---|---|
committer | inmarket <andrewh@inmarket.com.au> | 2013-12-21 13:21:59 +1000 |
commit | d9f02858fdc04c4404834a033850f758e4c8ee7e (patch) | |
tree | 2d7b4759cabf76eba5b7ef2147e58d3c9d7f885b /boards/addons | |
parent | 018a930d5525ffefc30fb2514752918455853685 (diff) | |
download | uGFX-d9f02858fdc04c4404834a033850f758e4c8ee7e.tar.gz uGFX-d9f02858fdc04c4404834a033850f758e4c8ee7e.tar.bz2 uGFX-d9f02858fdc04c4404834a033850f758e4c8ee7e.zip |
Replace NULL's with 0 as NULL is not defined by the Raw32 GOS.
Diffstat (limited to 'boards/addons')
6 files changed, 18 insertions, 18 deletions
diff --git a/boards/addons/gdisp/board_HX8347D_stm32f4discovery.h b/boards/addons/gdisp/board_HX8347D_stm32f4discovery.h index df287477..f486841b 100644 --- a/boards/addons/gdisp/board_HX8347D_stm32f4discovery.h +++ b/boards/addons/gdisp/board_HX8347D_stm32f4discovery.h @@ -28,12 +28,12 @@ static const PWMConfig pwmcfg = { 1000000, /* 1 MHz PWM clock frequency. */ 100, /* PWM period is 100 cycles. */ - NULL, + 0, { - {PWM_OUTPUT_ACTIVE_HIGH, NULL}, - {PWM_OUTPUT_ACTIVE_HIGH, NULL}, - {PWM_OUTPUT_ACTIVE_HIGH, NULL}, - {PWM_OUTPUT_ACTIVE_HIGH, NULL} + {PWM_OUTPUT_ACTIVE_HIGH, 0}, + {PWM_OUTPUT_ACTIVE_HIGH, 0}, + {PWM_OUTPUT_ACTIVE_HIGH, 0}, + {PWM_OUTPUT_ACTIVE_HIGH, 0} }, 0 }; @@ -44,7 +44,7 @@ static const PWMConfig pwmcfg = { * The slave select line is the pin 4 on the port GPIOA. */ static const SPIConfig spi1cfg_8bit = { - NULL, + 0, /* HW dependent part.*/ GPIOA, 4, @@ -57,7 +57,7 @@ static const SPIConfig spi1cfg_8bit = { * The slave select line is the pin 4 on the port GPIOA. */ static const SPIConfig spi1cfg_16bit = { - NULL, + 0, /* HW dependent part.*/ GPIOA, 4, diff --git a/boards/addons/gdisp/board_SSD1289_stm32f4discovery.h b/boards/addons/gdisp/board_SSD1289_stm32f4discovery.h index 866311dc..1d86a67e 100644 --- a/boards/addons/gdisp/board_SSD1289_stm32f4discovery.h +++ b/boards/addons/gdisp/board_SSD1289_stm32f4discovery.h @@ -24,12 +24,12 @@ static const PWMConfig pwmcfg = { 100000, /* 100 kHz PWM clock frequency. */ 100, /* PWM period is 100 cycles. */ - NULL, + 0, { - {PWM_OUTPUT_DISABLED, NULL}, - {PWM_OUTPUT_DISABLED, NULL}, - {PWM_OUTPUT_ACTIVE_HIGH, NULL}, - {PWM_OUTPUT_DISABLED, NULL} + {PWM_OUTPUT_DISABLED, 0}, + {PWM_OUTPUT_DISABLED, 0}, + {PWM_OUTPUT_ACTIVE_HIGH, 0}, + {PWM_OUTPUT_DISABLED, 0} }, 0 }; @@ -61,7 +61,7 @@ static inline void init_board(GDisplay *g) { rccEnableAHB3(RCC_AHB3ENR_FSMCEN, 0); #if defined(GDISP_USE_DMA) - if (dmaStreamAllocate(GDISP_DMA_STREAM, 0, NULL, NULL)) gfxExit(); + if (dmaStreamAllocate(GDISP_DMA_STREAM, 0, 0, 0)) gfxExit(); dmaStreamSetMemory0(GDISP_DMA_STREAM, &GDISP_RAM); dmaStreamSetMode(GDISP_DMA_STREAM, STM32_DMA_CR_PL(0) | STM32_DMA_CR_PSIZE_HWORD | STM32_DMA_CR_MSIZE_HWORD | STM32_DMA_CR_DIR_M2M); #else diff --git a/boards/addons/gdisp/board_SSD1306_i2c.h b/boards/addons/gdisp/board_SSD1306_i2c.h index 449d47ba..3f755f26 100644 --- a/boards/addons/gdisp/board_SSD1306_i2c.h +++ b/boards/addons/gdisp/board_SSD1306_i2c.h @@ -112,7 +112,7 @@ static inline void write_cmd(GDisplay *g, uint8_t cmd) { command[1] = cmd; i2cStart(&I2CD1, &i2cconfig); - i2cMasterTransmitTimeout(&I2CD1, SSD1306_I2C_ADDRESS, command, 2, NULL, 0, MS2ST(10)); + i2cMasterTransmitTimeout(&I2CD1, SSD1306_I2C_ADDRESS, command, 2, 0, 0, MS2ST(10)); i2cStop(&I2CD1); } @@ -120,7 +120,7 @@ static inline void write_data(GDisplay *g, uint8_t* data, uint16_t length) { (void) g; i2cStart(&I2CD1, &i2cconfig); - i2cMasterTransmitTimeout(&I2CD1, SSD1306_I2C_ADDRESS, data, length, NULL, 0, MS2ST(10)); + i2cMasterTransmitTimeout(&I2CD1, SSD1306_I2C_ADDRESS, data, length, 0, 0, MS2ST(10)); i2cStop(&I2CD1); } diff --git a/boards/addons/gdisp/board_SSD1306_spi.h b/boards/addons/gdisp/board_SSD1306_spi.h index 21bf095f..b476fec0 100644 --- a/boards/addons/gdisp/board_SSD1306_spi.h +++ b/boards/addons/gdisp/board_SSD1306_spi.h @@ -37,7 +37,7 @@ * The slave select line is the pin 4 on the port GPIOA. */ static const SPIConfig spi1config = { - NULL, + 0, /* HW dependent part.*/ SSD1306_MISO_PORT, SSD1306_MISO_PIN, diff --git a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h index e0ab85dc..73507f10 100644 --- a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h +++ b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_olimex_stm32_e407.h @@ -18,7 +18,7 @@ #define _GINPUT_LLD_MOUSE_BOARD_H static const SPIConfig spicfg = { - NULL, + 0, GPIOG, 10, /* SPI_CR1_BR_2 |*/ SPI_CR1_BR_1 | SPI_CR1_BR_0, diff --git a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h index 919b767d..d4923c29 100644 --- a/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h +++ b/boards/addons/ginput/touch/ADS7843/ginput_lld_mouse_board_st_stm32f4_discovery.h @@ -20,7 +20,7 @@ * Note that you can tweak the SPI bus speed */ static const SPIConfig spicfg = { - NULL, + 0, GPIOC, 4, /* SPI_CR1_BR_2 |*/ SPI_CR1_BR_1 | SPI_CR1_BR_0, |