STM32F10x library
Macros | Functions | Variables
lcd_io.c File Reference

HD44780 via IO pins, 8 bit (low level) More...

#include <inttypes.h>
#include <stm32f10x_gpio.h>
#include "lcd_io_pindef.h"

Macros

#define LCD_RS_1   GPIO_WriteBit(LCD_RS_PORT, LCD_RS_BIT, Bit_SET)
 
#define LCD_RS_0   GPIO_WriteBit(LCD_RS_PORT, LCD_RS_BIT, Bit_RESET)
 
#define LCD_RW_1   GPIO_WriteBit(LCD_RW_PORT, LCD_RW_BIT, Bit_SET)
 
#define LCD_RW_0   GPIO_WriteBit(LCD_RW_PORT, LCD_RW_BIT, Bit_RESET)
 
#define LCD_EN_1   GPIO_WriteBit(LCD_EN_PORT, LCD_EN_BIT, Bit_SET)
 
#define LCD_EN_0   GPIO_WriteBit(LCD_EN_PORT, LCD_EN_BIT, Bit_RESET)
 
#define _BV(x)   (1 << x)
 

Functions

void _delay_us (uint32_t)
 extern
 

Variables

const uint8_t lcd_busw = 0x10
 

Detailed Description

HD44780 via IO pins, 8 bit (low level)

Author
Matej Kogovsek (matej.nosp@m.@ham.nosp@m.radio.nosp@m..si)
Note
This file is part of mat-stm32f1-lib
Implements low level functions required by lcd.c
Pin mapping is defined in lcd_io_pindef.h

Macro Definition Documentation

#define _BV (   x)    (1 << x)

Bit value macro

#define LCD_EN_0   GPIO_WriteBit(LCD_EN_PORT, LCD_EN_BIT, Bit_RESET)

Clear EN macro

#define LCD_EN_1   GPIO_WriteBit(LCD_EN_PORT, LCD_EN_BIT, Bit_SET)

Set EN macro

#define LCD_RS_0   GPIO_WriteBit(LCD_RS_PORT, LCD_RS_BIT, Bit_RESET)

Clear RS macro

#define LCD_RS_1   GPIO_WriteBit(LCD_RS_PORT, LCD_RS_BIT, Bit_SET)

Set RS macro

#define LCD_RW_0   GPIO_WriteBit(LCD_RW_PORT, LCD_RW_BIT, Bit_RESET)

Clear RW macro

#define LCD_RW_1   GPIO_WriteBit(LCD_RW_PORT, LCD_RW_BIT, Bit_SET)

Set RW macro

Variable Documentation

const uint8_t lcd_busw = 0x10

Actual LCD bus width = 4 bit