Wiselib
Public Types | Public Member Functions
wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART > Class Template Reference

iSense Implementation of Serial Communication FacetiSense implementation of the Serial Communication Facet. More...

#include <isense_com_uart.h>

Inherits wiselib::UartBase< OsModel_P, uint8, uint8 >.

List of all members.

Public Types

enum  ErrorCodes { SUCCESS = OsModel::SUCCESS, ERR_UNSPEC = OsModel::ERR_UNSPEC }
typedef OsModel_P OsModel
typedef
iSenseSerialComUartModel
< OsModel, MESSAGE_TYPE_IN,
MESSAGE_TYPE_OUT, UART > 
self_type
typedef self_typeself_pointer_t
typedef uint8 block_data_t
typedef uint8 size_t
typedef uint8 uart_packet_length_t
enum  ReturnValues
typedef delegate2< void,
size_t, block_data_t * > 
uart_delegate_t
typedef vector_static< OsModel,
uart_delegate_t,
UART_BASE_MAX_RECEIVERS > 
CallbackVector
typedef CallbackVector::iterator CallbackVectorIterator

Public Member Functions

 iSenseSerialComUartModel (isense::Os &os)
int enable_serial_comm ()
int disable_serial_comm ()
int write (size_t len, block_data_t *buf)
void handle_uart_packet (uint8 type, uint8 *buf, uart_packet_length_t length)
virtual void execute (void *userdata)
int reg_read_callback (T *obj_pnt)
int unreg_read_callback (int idx)
void notify_receivers (size_t len, block_data_t *data)

Detailed Description

template<typename OsModel_P, int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
class wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >

iSense Implementation of Serial Communication Facet

iSense implementation of the Serial Communication Facet.

This implementation is "packet based", so that it can work with iShell (having a packet type in first byte, using DLE and so).

Alternatively, there is also a "buffered UART" (isense_com_bufferuart.h) that sends buffers directly.


Member Typedef Documentation

template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
typedef uint8 wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::block_data_t
typedef vector_static<OsModel, uart_delegate_t, UART_BASE_MAX_RECEIVERS > wiselib::UartBase< OsModel_P, uint8 , uint8 , UART_BASE_MAX_RECEIVERS >::CallbackVector [inherited]
typedef CallbackVector::iterator wiselib::UartBase< OsModel_P, uint8 , uint8 , UART_BASE_MAX_RECEIVERS >::CallbackVectorIterator [inherited]
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
typedef OsModel_P wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::OsModel
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
typedef self_type* wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::self_pointer_t
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
typedef iSenseSerialComUartModel<OsModel, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART> wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::self_type
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
typedef uint8 wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::size_t
typedef delegate2<void, size_t, block_data_t*> wiselib::UartBase< OsModel_P, uint8 , uint8 , UART_BASE_MAX_RECEIVERS >::uart_delegate_t [inherited]
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
typedef uint8 wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::uart_packet_length_t

Member Enumeration Documentation

template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
enum wiselib::iSenseSerialComUartModel::ErrorCodes
Enumerator:
SUCCESS 
ERR_UNSPEC 

Constructor & Destructor Documentation

template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::iSenseSerialComUartModel ( isense::Os os) [inline]

Member Function Documentation

template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
int wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::disable_serial_comm ( ) [inline]
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
int wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::enable_serial_comm ( ) [inline]
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
virtual void wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::execute ( void *  userdata) [inline, virtual]
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
void wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::handle_uart_packet ( uint8  type,
uint8 *  buf,
uart_packet_length_t  length 
) [inline]
void wiselib::UartBase< OsModel_P, uint8 , uint8 , UART_BASE_MAX_RECEIVERS >::notify_receivers ( size_t  len,
block_data_t data 
) [inline, inherited]
int wiselib::UartBase< OsModel_P, uint8 , uint8 , UART_BASE_MAX_RECEIVERS >::reg_read_callback ( T *  obj_pnt) [inline, inherited]
int wiselib::UartBase< OsModel_P, uint8 , uint8 , UART_BASE_MAX_RECEIVERS >::unreg_read_callback ( int  idx) [inline, inherited]
template<typename OsModel_P , int MESSAGE_TYPE_IN = isense::Uart::MESSAGE_TYPE_CUSTOM_IN_1, int MESSAGE_TYPE_OUT = isense::Uart::MESSAGE_TYPE_PLOT, int UART = 0>
int wiselib::iSenseSerialComUartModel< OsModel_P, MESSAGE_TYPE_IN, MESSAGE_TYPE_OUT, UART >::write ( size_t  len,
block_data_t buf 
) [inline]

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines