- Main Page
- Modules
- Data Structures
- Files
- Directories

# UART

## Files
file | e_uart_char.h
| Manage UART.

## Detailed Description

## Introduction

This package contains all the ressources you need to control the UART (universal asynchronous receiver transmitter). The microcontroller p30f6014A has two UART controller: UART1 and UART2.

Warning:
  In this package, the functions are written in ASM. We have "e_init_uartX.s" file for the initializing functions, "e_uartX_rx.s" file for receiving data functions and "e_uartX_tx.s" file for transmitting data functions (X can be 1 or 2).
  Even these files are written in ASM, you can call them by including the e_uart_char.h files in your C code (look at the exemple in e_uart_char.h).

## Bluetooth

The e-puck has his bluetooth module connected on the uart1. Two ways are possibles when you work with bluetooth:

- you are the master, look at this: Bluetooth
- you are the slave.

When you are the slave, you can communicate with the master device exactely by the same way as you do to communicate through the uart. The bluetooth protocole is made to look like as transparent as possible. This is possible because the master initialize the communication and the bluetooth module answer automatically to create the connection. After that the connection was created, you can communicate with the master by using the uart protocole.

Author:
  Doc: Jonathan Besuchet