Skip to content

Commit

Permalink
Merge pull request #8 from mlippett/master
Browse files Browse the repository at this point in the history
Editorial changes
  • Loading branch information
djpwilk committed Oct 15, 2012
2 parents 812f486 + d40a081 commit ee3cdba
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion doc/component_description.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Module Description
==================

The Multi-UART module consists of Transmit and Receive servers. These can be employed independently or togeather based on the application needs.
The Multi-UART module consists of Transmit and Receive servers. These can be employed independently or together based on the application needs.

Cores
-----
Expand Down
8 changes: 4 additions & 4 deletions doc/example_applications.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,12 @@ The following tools should be installed on the host system in order to run this
Build options
--------------

``app_sk_muart_com_demo`` application use the following modules in order to achive its desired functionality.
``app_sk_muart_com_demo`` application uses the following modules in order to achieve its desired functionality.

* **sc_multi_uart**: utilizes TX and RX servers provided by the component
* **sc_util**: uses ``module_xc_ptr`` functions to perform pointer related arithmetic such as reading from and writing into memory

This demo application is built by default for XP-SKC-L2 Slicekit Core board, SQAURE connector type. This application can also be built for other compatible connectors as follows:
This demo application is built by default for XP-SKC-L2 Slicekit Core board, SQUARE connector type. This application can also be built for other compatible connectors as follows:

To build for STAR connector, make the following changes in ``src\main.xc`` file:

Expand Down Expand Up @@ -98,7 +98,7 @@ The application operates a state machine to differentiate between user commands

Generally, the data token received by RX buffering logical core tells which UART channel a character has been received on. The logical core then extracts this character out of the buffer slot, validates it utilising the provided validation function and inserts it into a larger, more comprehensive buffer.The RX buffering is implemented as an example only and may not be necessary for other applications. The TX logical core already provides some buffering supported at the component level.

The TX handler operates by polling the buffer which is filled by the Rx handler. When an entry is seen, Tx handler pulls it from the buffer and perform an action based on current state of the handler.
The TX handler operates by polling the buffer which is filled by the Rx handler. When an entry is seen, the Tx handler pulls it from the buffer and performs an action based on the current state of the handler.

The channel for the TX logical core is primarily used for reconfiguration. This is discussed in more detail in :ref:`sec_reconf_rxtx`. Specific usage of the API is also discussed in :ref:`sec_interfacing_tx` and :ref:`sec_interfacing_rx`.

Expand All @@ -108,7 +108,7 @@ The channel for the TX logical core is primarily used for reconfiguration. This
Quick Start Guide
-----------------

Quick starter guide and applicatioj usage is available in ``doc_quickstart`` of the application.
Quick starter guide and application usage is available in ``doc_quickstart`` of the application.

.. _sec_demo_features:

Expand Down
14 changes: 7 additions & 7 deletions doc/programming_guide.rst
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ This is an overview of the key header files that are required, as well as the lo
Source Code
++++++++++++

All of the files required for operation are located in the ``module_multi_uart`` directory. The files that are need to be included for use of this component in an application are:
All of the files required for operation are located in the ``module_multi_uart`` directory. The files that need to be included for use of this component in an application are:

.. list-table::
:header-rows: 1
Expand All @@ -30,7 +30,7 @@ All of the files required for operation are located in the ``module_multi_uart``
Configuration of Multi-UART component
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Multi-UART component configuration takes place in two domains - a static compile time configuration (discussed in this section) and a runtime dynamic configuration (as discussed in :ref:`sec_initialisation` and :ref:`sec_reconf_rxtx`.
Multi-UART component configuration takes place in two domains - a static compile time configuration (discussed in this section) and a runtime dynamic configuration (as discussed in :ref:`sec_initialisation` and :ref:`sec_reconf_rxtx`).

Static configuration is done by the application providing configuration header files ``multi_uart_tx_conf.h`` and ``multi_uart_rx_conf.h``.

Expand Down Expand Up @@ -59,11 +59,11 @@ Below is a summary of the configuration options that are in the ``multi_uart_tx_
* - UART_TX_MAX_BAUD_RATE
- 115200
- less than or equal to 115200
- Define the max baud rate the API will allow configuration. Validated to 115200
- Defines the max baud rate the API will allow configuration of. Validated to 115200
* - UART_TX_CLOCK_DIVIDER
- (UART_TX_CLOCK_RATE_HZ / UART_TX_MAX_BAUD_RATE)
- Any appropriate divider
- It is recommended to leave this at the default. Is used to set the clock divider when configuring clocking from the internal reference clock
- It is recommended to leave this at the default. It is used to set the clock divider when configuring clocking from the internal reference clock
* - UART_TX_OVERSAMPLE
- 2
- {1|2}
Expand Down Expand Up @@ -105,22 +105,22 @@ Below is a summary of the configuration options that are in the ``multi_uart_rx_
* - UART_RX_MAX_BAUD
- 115200
- less than or equal to 115200
- Define the max baud rate the API will allow configuration. Validated to 115200.
- Defines the max baud rate the API will allow configuration of. Validated to 115200.
* - UART_RX_CLOCK_DIVIDER
- (UART_RX_CLOCK_RATE_HZ / UART_RX_MAX_BAUD)
- Any appropriate divider
- It is recommended to leave this at the default. Is used to set the clock divider when configuring clocking using either internal or external clocks.
* - UART_RX_OVERSAMPLE
- 4
- Should remain at 4
- Oversample count for the max baud rate. It is recommended to leave this value as it is unless it is understood the effects that changing this value will have.
- Oversample count for the max baud rate. It is recommended that this value is left as it is unless the effects of changing it are well understood.

.. _sec_initialisation:

Initialisation
~~~~~~~~~~~~~~

The initialisation and configuration process for both the RX and TX operations is the same. For configuration the functions :c:func:`uart_rx_initialise_channel` or :c:func:`uart_tx_initialise_channel` is utilised. The flow is visualised in :ref:`fig_uart_init_flow` and a working example taken from the echo test application that is utilised for verification.
The initialisation and configuration process for both the RX and TX operations is the same. For configuration, the functions :c:func:`uart_rx_initialise_channel` or :c:func:`uart_tx_initialise_channel` are utilised. The flow is visualised in :ref:`fig_uart_init_flow` and a working example taken from the echo test application that is used for verification.

.. _fig_uart_init_flow:

Expand Down
2 changes: 1 addition & 1 deletion module_multi_uart/src/rx/multi_uart_rx.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ int uart_rx_initialise_channel( int channel_id, e_uart_config_parity parity, e_u
* character
* @param[in] chan_id UART channel ID from which the char came from
* @param[in,out] uart_word UART char in the format DATA_BITS|PARITY|STOP BITS (parity optional
* according to config), modified to clean UART charcater on successful * return
* according to config), modified to clean UART character on successful * return
* @return Return 0 on valid data, -1 on validation fail
*/
int uart_rx_validate_char( int chan_id, REFERENCE_PARAM(unsigned,uart_word) );
Expand Down
4 changes: 2 additions & 2 deletions module_multi_uart/src/tx/multi_uart_tx.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,12 @@ unsigned int uart_tx_assemble_word( int channel_id, unsigned int uart_char );
int uart_tx_put_char( int channel_id, unsigned int uart_char );

/**
* Multi UART Transmit Thread
* Multi UART Transmit function
*/
void run_multi_uart_tx( streaming chanend cUART, REFERENCE_PARAM(s_multi_uart_tx_ports, tx_ports), clock uart_clock);

/**
* Pause the Multi-UART TX thread for reconfiguration
* Pause the Multi-UART TX task for reconfiguration
* @param cUART chanend to UART TX thread
* @param t timer for running buffer clearance pause
*/
Expand Down

0 comments on commit ee3cdba

Please sign in to comment.