Lee Shen / FTHR_USB_serial_qSPI
Embed: (wiki syntax)

« Back to documentation index

mbed Namespace Reference

mbed Namespace Reference
[EventsNetsocket]

Parser class for parsing AT commands. More...

Data Structures

class  AnalogIn
 An analog input, used for reading the voltage on a pin. More...
class  AnalogOut
 An analog output, used for setting the voltage on a pin. More...
class  BusIn
 A digital input bus, used for reading the state of a collection of pins. More...
class  BusInOut
 A digital input output bus, used for setting the state of a collection of pins. More...
class  BusOut
 A digital output bus, used for setting the state of a collection of pins. More...
class  CANMessage
 CANMessage class. More...
class  CAN
 A can bus client, used for communicating with can devices. More...
class  DigitalIn
 A digital input, used for reading the state of a pin. More...
class  DigitalInOut
 A digital input/output, used for setting or reading a bi-directional pin. More...
class  DigitalOut
 A digital output, used for setting the state of a pin. More...
class  Ethernet
 An ethernet interface, to use with the ethernet pins. More...
class  FlashIAP
 Flash IAP driver. More...
class  I2C
 An I2C Master, used for communicating with I2C slave devices. More...
class  I2CSlave
 An I2C Slave, used for communicating with an I2C Master device. More...
class  InterruptIn
 A digital interrupt input, used to call a function on a rising or falling edge. More...
class  InterruptManager
 Use this singleton if you need to chain interrupt handlers. More...
class  LowPowerTicker
 Low Power Ticker. More...
class  LowPowerTimeout
 Low Power Timout. More...
class  LowPowerTimer
 Low power timer. More...
class  PortIn
 A multiple pin digital input. More...
class  PortInOut
 A multiple pin digital in/out used to set/read multiple bi-directional pins. More...
class  PortOut
 A multiple pin digital out. More...
class  PwmOut
 A pulse-width modulation digital output. More...
class  RawSerial
 A serial port (UART) for communication with other serial devices This is a variation of the Serial class that doesn't use streams, thus making it safe to use in interrupt handlers with the RTOS. More...
class  Serial
 A serial port (UART) for communication with other serial devices. More...
class  SerialBase
 A base class for serial port implementations Can't be instantiated directly (use Serial or RawSerial) More...
class  SPI
 A SPI Master, used for communicating with SPI slave devices. More...
class  SPISlave
 A SPI slave, used for communicating with a SPI Master device. More...
class  Ticker
 A Ticker is used to call a function at a recurring interval. More...
class  Timeout
 A Timeout is used to call a function at a point in the future. More...
class  Timer
 A general purpose timer. More...
class  TimerEvent
 Base abstraction for timer interrupts. More...
class  Dir
 Dir class. More...
class  File
 File class. More...
class  FileSystem
 A filesystem object provides filesystem operations and file operations for the File and Dir classes on a block device. More...
class  Callback< R()>
 Callback class based on template specialization. More...
class  Callback< R(A0)>
 Callback class based on template specialization. More...
class  Callback< R(A0, A1)>
 Callback class based on template specialization. More...
class  Callback< R(A0, A1, A2)>
 Callback class based on template specialization. More...
class  Callback< R(A0, A1, A2, A3)>
 Callback class based on template specialization. More...
class  Callback< R(A0, A1, A2, A3, A4)>
 Callback class based on template specialization. More...
class  CircularBuffer
 Templated Circular buffer class. More...
class  CriticalSectionLock
 RAII object for disabling, then restoring, interrupt state Usage: More...
class  DeepSleepLock
 RAII object for disabling, then restoring the deep sleep mode Usage: More...
class  DirHandle
 Represents a directory stream. More...
class  FileHandle
 Class FileHandle. More...
class  FileSystemHandle
 A filesystem-like object is one that can be used to open file-like objects though it by fopen("/name/filename", mode) More...
class  FileSystemLike
 A filesystem-like object is one that can be used to open file-like objects though it by fopen("/name/filename", mode) More...
class  LocalFileSystem
 A filesystem for accessing the local mbed Microcontroller USB disk drive. More...
class  NonCopyable
 Inheriting from this class autogeneration of copy construction and copy assignement operations. More...
class  Stream
 File stream. More...
struct  transaction_t
 Transaction structure. More...
class  Transaction
 Transaction class defines a transaction. More...

Typedefs

typedef Callback< void()> * pFunctionPointer_t
 Group one or more functions in an instance of a CallChain, then call them in sequence using CallChain::call().

Functions

EventQueuembed_event_queue ()
 Return a pointer to an EventQueue, on which normal tasks can be queued.
EventQueuembed_highprio_event_queue ()
 Return a pointer to an EventQueue, on which small high-priority tasks can be queues, such as simple deferrals from interrupt.
err_t ppp_lwip_connect ()
 Connects to a PPP pipe.
err_t ppp_lwip_disconnect ()
 Disconnects from a PPP pipe.
nsapi_error_t ppp_lwip_if_init (struct netif *netif, const nsapi_ip_stack_t stack)
 Initializes LWIP PPP interface.
nsapi_error_t nsapi_ppp_connect (FileHandle *stream, Callback< void(nsapi_error_t)> status_cb=0, const char *uname=0, const char *pwd=0, const nsapi_ip_stack_t stack=DEFAULT_STACK)
 Connect to a PPP pipe.
nsapi_error_t nsapi_ppp_disconnect (FileHandle *stream)
 Close a PPP connection.
NetworkStack * nsapi_ppp_get_stack ()
 Provide access to the NetworkStack object.
const char * nsapi_ppp_get_ip_addr (FileHandle *stream)
 Get IP address.
const char * nsapi_ppp_get_netmask (FileHandle *stream)
 Get network mask.
const char * nsapi_ppp_get_gw_addr (FileHandle *stream)
 Get gateway address.
template<typename R >
Callback< R()> callback (R(*func)()=0)
 Create a callback class with type infered from the arguments.
template<typename R >
Callback< R()> callback (const Callback< R()> &func)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (U *obj, R(T::*method)())
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (const U *obj, R(T::*method)() const)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (volatile U *obj, R(T::*method)() volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (const volatile U *obj, R(T::*method)() const volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (R(*func)(T *), U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (R(*func)(const T *), const U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (R(*func)(volatile T *), volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
Callback< R()> callback (R(*func)(const volatile T *), const volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R >
 MBED_DEPRECATED_SINCE ("mbed-os-5.1","Arguments to callback have been reordered to callback(func, arg)") Callback< R()> callback(U *obj
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 >
Callback< R(A0)> callback (R(*func)(A0)=0)
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 >
Callback< R(A0)> callback (const Callback< R(A0)> &func)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (U *obj, R(T::*method)(A0))
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (const U *obj, R(T::*method)(A0) const)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (volatile U *obj, R(T::*method)(A0) volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (const volatile U *obj, R(T::*method)(A0) const volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (R(*func)(T *, A0), U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (R(*func)(const T *, A0), const U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (R(*func)(volatile T *, A0), volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
Callback< R(A0)> callback (R(*func)(const volatile T *, A0), const volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 >
 MBED_DEPRECATED_SINCE ("mbed-os-5.1","Arguments to callback have been reordered to callback(func, arg)") Callback< R(A0)> callback(U *obj
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (R(*func)(A0, A1)=0)
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (const Callback< R(A0, A1)> &func)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (U *obj, R(T::*method)(A0, A1))
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (const U *obj, R(T::*method)(A0, A1) const)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (volatile U *obj, R(T::*method)(A0, A1) volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (const volatile U *obj, R(T::*method)(A0, A1) const volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (R(*func)(T *, A0, A1), U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (R(*func)(const T *, A0, A1), const U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (R(*func)(volatile T *, A0, A1), volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
Callback< R(A0, A1)> callback (R(*func)(const volatile T *, A0, A1), const volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 >
 MBED_DEPRECATED_SINCE ("mbed-os-5.1","Arguments to callback have been reordered to callback(func, arg)") Callback< R(A0
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (R(*func)(A0, A1, A2)=0)
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (const Callback< R(A0, A1, A2)> &func)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (U *obj, R(T::*method)(A0, A1, A2))
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (const U *obj, R(T::*method)(A0, A1, A2) const)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (volatile U *obj, R(T::*method)(A0, A1, A2) volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (const volatile U *obj, R(T::*method)(A0, A1, A2) const volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (R(*func)(T *, A0, A1, A2), U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (R(*func)(const T *, A0, A1, A2), const U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (R(*func)(volatile T *, A0, A1, A2), volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
Callback< R(A0, A1, A2)> callback (R(*func)(const volatile T *, A0, A1, A2), const volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 >
 MBED_DEPRECATED_SINCE ("mbed-os-5.1","Arguments to callback have been reordered to callback(func, arg)") Callback< R(A0
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (R(*func)(A0, A1, A2, A3)=0)
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (const Callback< R(A0, A1, A2, A3)> &func)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (U *obj, R(T::*method)(A0, A1, A2, A3))
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (const U *obj, R(T::*method)(A0, A1, A2, A3) const)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (volatile U *obj, R(T::*method)(A0, A1, A2, A3) volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (const volatile U *obj, R(T::*method)(A0, A1, A2, A3) const volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (R(*func)(T *, A0, A1, A2, A3), U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (R(*func)(const T *, A0, A1, A2, A3), const U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (R(*func)(volatile T *, A0, A1, A2, A3), volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
Callback< R(A0, A1, A2, A3)> callback (R(*func)(const volatile T *, A0, A1, A2, A3), const volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 >
 MBED_DEPRECATED_SINCE ("mbed-os-5.1","Arguments to callback have been reordered to callback(func, arg)") Callback< R(A0
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (R(*func)(A0, A1, A2, A3, A4)=0)
 Create a callback class with type infered from the arguments.
template<typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (const Callback< R(A0, A1, A2, A3, A4)> &func)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (U *obj, R(T::*method)(A0, A1, A2, A3, A4))
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (const U *obj, R(T::*method)(A0, A1, A2, A3, A4) const)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (volatile U *obj, R(T::*method)(A0, A1, A2, A3, A4) volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (const volatile U *obj, R(T::*method)(A0, A1, A2, A3, A4) const volatile)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (R(*func)(T *, A0, A1, A2, A3, A4), U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (R(*func)(const T *, A0, A1, A2, A3, A4), const U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (R(*func)(volatile T *, A0, A1, A2, A3, A4), volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
Callback< R(A0, A1, A2, A3, A4)> callback (R(*func)(const volatile T *, A0, A1, A2, A3, A4), const volatile U *arg)
 Create a callback class with type infered from the arguments.
template<typename T , typename U , typename R , typename A0 , typename A1 , typename A2 , typename A3 , typename A4 >
 MBED_DEPRECATED_SINCE ("mbed-os-5.1","Arguments to callback have been reordered to callback(func, arg)") Callback< R(A0
 Create a callback class with type infered from the arguments.
std::FILE * fdopen (FileHandle *fh, const char *mode)
 Not a member function This call is equivalent to posix fdopen().
int poll (pollfh fhs[], unsigned nfhs, int timeout)
 A mechanism to multiplex input/output over a set of file handles(file descriptors).

Detailed Description

Parser class for parsing AT commands.

Here are some examples:

 UARTSerial serial = UARTSerial(D1, D0);
 ATCmdParser at = ATCmdParser(&serial, "\r\n");
 int value;
 char buffer[100];

 at.send("AT") && at.recv("OK");
 at.send("AT+CWMODE=%d", 3) && at.recv("OK");
 at.send("AT+CWMODE?") && at.recv("+CWMODE:%d\r\nOK", &value);
 at.recv("+IPD,%d:", &value);
 at.read(buffer, value);
 at.recv("OK");

Function Documentation

Callback<R()> mbed::callback ( R(*)()  func = 0 )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 3542 of file Callback.h.

Callback<R()> mbed::callback ( const Callback< R()> &  func )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 3552 of file Callback.h.

Callback<R(A0)> mbed::callback ( R(*)(A0)  func = 0 )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 3711 of file Callback.h.

Callback<R(A0)> mbed::callback ( const Callback< R(A0)> &  func )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 3721 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( R(*)(T *, A0, A1, A2)  func,
U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4114 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( R(*)(const T *, A0, A1, A2)  func,
const U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4125 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( R(*)(volatile T *, A0, A1, A2)  func,
volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4136 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( R(*)(const volatile T *, A0, A1, A2)  func,
const volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4147 of file Callback.h.

Callback<R(A0)> mbed::callback ( U *  obj,
R(T::*)(A0)  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3732 of file Callback.h.

Callback<R(A0)> mbed::callback ( const U *  obj,
R(T::*)(A0) const   method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3743 of file Callback.h.

Callback<R(A0)> mbed::callback ( volatile U *  obj,
R(T::*)(A0) volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3754 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( R(*)(const volatile T *, A0, A1, A2, A3, A4)  func,
const volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4485 of file Callback.h.

Callback<R(A0)> mbed::callback ( const volatile U *  obj,
R(T::*)(A0) const volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3765 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( R(*)(const T *, A0, A1, A2, A3, A4)  func,
const U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4463 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( R(*)(T *, A0, A1, A2, A3, A4)  func,
U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4452 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( const volatile U *  obj,
R(T::*)(A0, A1, A2, A3, A4) const volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4441 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( const U *  obj,
R(T::*)(A0, A1, A2, A3, A4) const   method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4419 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( R(*)(A0, A1, A2, A3)  func = 0 )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 4218 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( const Callback< R(A0, A1, A2, A3, A4)> &  func )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 4397 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( const Callback< R(A0, A1, A2, A3)> &  func )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 4228 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( U *  obj,
R(T::*)(A0, A1, A2, A3)  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4239 of file Callback.h.

Callback<R(A0)> mbed::callback ( R(*)(T *, A0)  func,
U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3776 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( const U *  obj,
R(T::*)(A0, A1, A2, A3) const   method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4250 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( volatile U *  obj,
R(T::*)(A0, A1, A2, A3) volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4261 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( R(*)(volatile T *, A0, A1, A2, A3)  func,
volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4305 of file Callback.h.

Callback<R(A0)> mbed::callback ( R(*)(const T *, A0)  func,
const U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3787 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( const volatile U *  obj,
R(T::*)(A0, A1, A2, A3) const volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4272 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( R(*)(T *, A0, A1, A2, A3)  func,
U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4283 of file Callback.h.

Callback<R()> mbed::callback ( U *  obj,
R(T::*)()  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3563 of file Callback.h.

Callback<R(A0)> mbed::callback ( R(*)(volatile T *, A0)  func,
volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3798 of file Callback.h.

Callback<R(A0)> mbed::callback ( R(*)(const volatile T *, A0)  func,
const volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3809 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( R(*)(const T *, A0, A1, A2, A3)  func,
const U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4294 of file Callback.h.

Callback<R(A0, A1, A2, A3)> mbed::callback ( R(*)(const volatile T *, A0, A1, A2, A3)  func,
const volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4316 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( R(*)(A0, A1)  func = 0 )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 3880 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( const Callback< R(A0, A1)> &  func )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 3890 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( U *  obj,
R(T::*)(A0, A1)  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3901 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( R(*)(A0, A1, A2, A3, A4)  func = 0 )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 4387 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( U *  obj,
R(T::*)(A0, A1, A2, A3, A4)  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4408 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( const U *  obj,
R(T::*)(A0, A1) const   method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3912 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( volatile U *  obj,
R(T::*)(A0, A1, A2, A3, A4) volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4430 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( const volatile U *  obj,
R(T::*)(A0, A1, A2) const volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4103 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( volatile U *  obj,
R(T::*)(A0, A1) volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3923 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( const U *  obj,
R(T::*)(A0, A1, A2) const   method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4081 of file Callback.h.

Callback<R()> mbed::callback ( const U *  obj,
R(T::*)() const   method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3574 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( const Callback< R(A0, A1, A2)> &  func )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 4059 of file Callback.h.

Callback<R()> mbed::callback ( volatile U *  obj,
R(T::*)() volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3585 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( const volatile U *  obj,
R(T::*)(A0, A1) const volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3934 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( R(*)(T *, A0, A1)  func,
U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3945 of file Callback.h.

Callback<R(A0, A1, A2, A3, A4)> mbed::callback ( R(*)(volatile T *, A0, A1, A2, A3, A4)  func,
volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 4474 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( R(*)(const T *, A0, A1)  func,
const U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3956 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( R(*)(volatile T *, A0, A1)  func,
volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3967 of file Callback.h.

Callback<R()> mbed::callback ( const volatile U *  obj,
R(T::*)() const volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 3596 of file Callback.h.

Callback<R(A0, A1)> mbed::callback ( R(*)(const volatile T *, A0, A1)  func,
const volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3978 of file Callback.h.

Callback<R()> mbed::callback ( R(*)(T *)  func,
U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3607 of file Callback.h.

Callback<R()> mbed::callback ( R(*)(const T *)  func,
const U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3618 of file Callback.h.

Callback<R()> mbed::callback ( R(*)(volatile T *)  func,
volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3629 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( R(*)(A0, A1, A2)  func = 0 )

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
Returns:
Callback with infered type

Definition at line 4049 of file Callback.h.

Callback<R()> mbed::callback ( R(*)(const volatile T *)  func,
const volatile U *  arg 
)

Create a callback class with type infered from the arguments.

Parameters:
funcStatic function to attach
argPointer argument to function
Returns:
Callback with infered type

Definition at line 3640 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( U *  obj,
R(T::*)(A0, A1, A2)  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4070 of file Callback.h.

Callback<R(A0, A1, A2)> mbed::callback ( volatile U *  obj,
R(T::*)(A0, A1, A2) volatile  method 
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
methodMember function to attach
Returns:
Callback with infered type

Definition at line 4092 of file Callback.h.

std::FILE * fdopen ( FileHandle *  fh,
const char *  mode 
)

Not a member function This call is equivalent to posix fdopen().

It associates a Stream to an already opened file descriptor (FileHandle)

Parameters:
fha pointer to an opened file descriptor
modeoperation upon the file descriptor, e.g., 'wb+'
Returns:
a pointer to std::FILE

Definition at line 36 of file FileHandle.cpp.

MBED_DEPRECATED_SINCE ( "mbed-os-5.1"  ,
"Arguments to callback have been reordered to callback(func, arg)"   
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
MBED_DEPRECATED_SINCE ( "mbed-os-5.1"  ,
"Arguments to callback have been reordered to callback(func, arg)"   
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
MBED_DEPRECATED_SINCE ( "mbed-os-5.1"  ,
"Arguments to callback have been reordered to callback(func, arg)"   
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
MBED_DEPRECATED_SINCE ( "mbed-os-5.1"  ,
"Arguments to callback have been reordered to callback(func, arg)"   
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
MBED_DEPRECATED_SINCE ( "mbed-os-5.1"  ,
"Arguments to callback have been reordered to callback(func, arg)"   
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
MBED_DEPRECATED_SINCE ( "mbed-os-5.1"  ,
"Arguments to callback have been reordered to callback(func, arg)"   
)

Create a callback class with type infered from the arguments.

Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
Parameters:
objOptional pointer to object to bind to function
funcStatic function to attach
Returns:
Callback with infered type
events::EventQueue * mbed_event_queue (  )

Return a pointer to an EventQueue, on which normal tasks can be queued.

All calls to this return the same EventQueue - it and its dispatch thread are created on the first call to this function. The dispatch thread runs at default priority (currently osPriorityNormal).

The EventQueue returned may be used to call() Events, or to chain() other EventQueues so that they are run in the same context.

Events (or chained EventQueues) executing on the normal event queue should normally take less than 10ms to execute, to avoid starving other users. As such, users can expect that event latency will typically be 10ms or less, but could occasionally be significantly higher if many events are queued.

If an RTOS is not present or the configuration option `events.shared-dispatch-from-application` is set to true, then this does not create a dedicated dispatch thread - instead the application is expected to run the EventQueue's dispatch, eg from main. This is necessary for the event loop to work without an RTOS, or an RTOS system can can save memory by reusing the main stack.

Returns:
pointer to event queue

Definition at line 52 of file mbed_shared_queues.cpp.

events::EventQueue * mbed_highprio_event_queue (  )

Return a pointer to an EventQueue, on which small high-priority tasks can be queues, such as simple deferrals from interrupt.

All calls to this return the same EventQueue - it and its thread are created on the first call to this function. The dispatch thread runs at a high priority (currently osPriorityHigh).

The EventQueue returned may be used to call() Events, or to chain() other EventQueues so that they are run in the same context.

Events (or chained EventQueues) executing on the high-priority event queue should normally take less than 100us to execute, to avoid starving other users. As such, users can expect that event latency will typically be 100us or less, but could occasionally be significantly higher if many events are queued.

Returns:
pointer to high-priority event queue

Definition at line 66 of file mbed_shared_queues.cpp.

nsapi_error_t nsapi_ppp_connect ( FileHandle *  stream,
Callback< void(nsapi_error_t)>  status_cb = 0,
const char *  uname = 0,
const char *  pwd = 0,
const nsapi_ip_stack_t  stack = DEFAULT_STACK 
)

Connect to a PPP pipe.

Parameters:
streamPointer to a device type file handle (descriptor)
status_cbOptional, user provided callback for connection status
unameOptional, username for the connection
pwdOptional, password for the connection
stackOptional, stack for the connection
Returns:
0 on success, negative error code on failure

Definition at line 354 of file ppp_lwip.cpp.

nsapi_error_t nsapi_ppp_disconnect ( FileHandle *  stream )

Close a PPP connection.

Parameters:
streamPointer to a device type file handle (descriptor)
Returns:
0 on success, negative error code on failure

Definition at line 376 of file ppp_lwip.cpp.

const char * nsapi_ppp_get_gw_addr ( FileHandle *  stream )

Get gateway address.

After a successful connection, this API can be used to retrieve IP address of the default gateway in case of an IPv4 network.

Parameters:
streamPointer to a device type file handle (descriptor)
Returns:
A string containing gateway IP address or NULL

Definition at line 414 of file ppp_lwip.cpp.

const char * nsapi_ppp_get_ip_addr ( FileHandle *  stream )

Get IP address.

After a successful connection, this API can be used to retrieve assigned IP address.

Parameters:
streamPointer to a device type file handle (descriptor)
Returns:
A string containing IP address or NULL

Definition at line 386 of file ppp_lwip.cpp.

const char * nsapi_ppp_get_netmask ( FileHandle *  stream )

Get network mask.

After a successful connection, this API can be used to retrieve network mask in case of an IPv4 network.

Parameters:
streamPointer to a device type file handle (descriptor)
Returns:
A string containing network mask or NULL

Definition at line 399 of file ppp_lwip.cpp.

NetworkStack * nsapi_ppp_get_stack (  )

Provide access to the NetworkStack object.

Returns:
The underlying NetworkStack object

Definition at line 381 of file ppp_lwip.cpp.

int poll ( pollfh  fhs[],
unsigned  nfhs,
int  timeout 
)

A mechanism to multiplex input/output over a set of file handles(file descriptors).

For every file handle provided, poll() examines it for any events registered for that particular file handle.

Parameters:
fhsan array of PollFh struct carrying a FileHandle and bitmasks of events
nfhsnumber of file handles
timeouttimer value to timeout or -1 for loop forever
Returns:
number of file handles selected (for which revents is non-zero). 0 if timed out with nothing selected. -1 for error.

TODO Proper wake-up mechanism. In order to correctly detect availability of read/write a FileHandle, we needed a select or poll mechanisms. We opted for poll as POSIX defines in http://pubs.opengroup.org/onlinepubs/009695399/functions/poll.html Currently, mbed::poll() just spins and scans filehandles looking for any events we are interested in. In future, his spinning behaviour will be replaced with condition variables.

Definition at line 26 of file mbed_poll.cpp.

err_t mbed::ppp_lwip_connect ( void   )

Connects to a PPP pipe.

Called during LWIP interface bringup

Returns:
0 for success and negative error codes for failure

Definition at line 282 of file ppp_lwip.cpp.

err_t mbed::ppp_lwip_disconnect ( void   )

Disconnects from a PPP pipe.

Can be called from multiple places. If LWIP bringup fails after initializing PPP interface, this API kicks in. Formal disconnection occurs when LWIP interface is brought down.

Returns:
0 for success and negative error codes for failure

Definition at line 298 of file ppp_lwip.cpp.

nsapi_error_t mbed::ppp_lwip_if_init ( struct netif netif,
const nsapi_ip_stack_t  stack 
)

Initializes LWIP PPP interface.

Starts a private thread for LWIP PPP and turns the PPP interface up.

Parameters:
netifLWIP netif struct
Returns:
0 for success and negative error codes for failure

Definition at line 316 of file ppp_lwip.cpp.