Skip to content

Fix typos in Features/Netsocket #8560

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 30, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions features/netsocket/CellularBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class CellularBase: public NetworkInterface {
/** Get the default cellular interface.
*
* This is provided as a weak method so applications can override.
* Default behaviour is to get the target's default interface, if
* Default behavior is to get the target's default interface, if
* any.
*
* @return pointer to interface, if any.
Expand All @@ -36,7 +36,7 @@ class CellularBase: public NetworkInterface {

/** Set the cellular network credentials.
*
* Please check documentation of connect() for default behaviour of APN settings.
* Please check documentation of connect() for default behavior of APN settings.
*
* @param apn Access point name.
* @param uname Username (optional).
Expand Down
12 changes: 6 additions & 6 deletions features/netsocket/EMAC.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

/**
* This interface should be used to abstract low level access to networking hardware
* All operations receive a `void *` hw pointer which an emac device provides when
* All operations receive a `void *` hardware pointer which an EMAC device provides when
* it is registered with a stack.
*/
class EMAC {
Expand All @@ -40,15 +40,15 @@ class EMAC {
static EMAC &get_default_instance();

/**
* Callback to be register with Emac interface and to be called for received packets
* Callback to be register with EMAC interface and to be called for received packets
*
* @param buf Received data
*/
//typedef void (*emac_link_input_fn)(void *data, emac_mem_buf_t *buf);
typedef mbed::Callback<void (emac_mem_buf_t *buf)> emac_link_input_cb_t;

/**
* Callback to be register with Emac interface and to be called for link status changes
* Callback to be register with EMAC interface and to be called for link status changes
*
* @param up Link status
*/
Expand All @@ -65,7 +65,7 @@ class EMAC {
/**
* Gets memory buffer alignment preference
*
* Gets preferred memory buffer alignment of the Emac device. IP stack may or may not
* Gets preferred memory buffer alignment of the EMAC device. IP stack may or may not
* align link out memory buffer chains using the alignment.
*
* @return Memory alignment requirement in bytes
Expand Down Expand Up @@ -107,7 +107,7 @@ class EMAC {
* Provided address has to be of correct size, see @a get_hwaddr_size
*
* Called to set the MAC address to actually use - if @a get_hwaddr is provided
* the stack would normally use that, but it could be overridden, eg for test
* the stack would normally use that, but it could be overridden, for example for test
* purposes.
*
* @param addr Address to be set
Expand Down Expand Up @@ -179,7 +179,7 @@ class EMAC {


/** These need to be defined by targets wishing to provide an Ethernet driver using EMAC interface. It will
* be used by the EMACInterface class's default constructor to initialise the networking subsystem.
* be used by the EMACInterface class's default constructor to initialize the networking subsystem.
*/
//extern const emac_interface_ops_t mbed_emac_eth_ops_default;
//extern void *mbed_emac_eth_hw_default;
Expand Down
8 changes: 4 additions & 4 deletions features/netsocket/EMACInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
* Drivers derived from EMACInterface should be constructed so that their
* EMAC is functional without the need to call `connect()`. For example
* a Wi-Fi driver should permit `WiFi::get_emac().power_up()` as soon as
* the credentials have been set. This is necessary to support specialised
* the credentials have been set. This is necessary to support specialized
* applications such as 6LoWPAN mesh border routers.
*/
class EMACInterface : public virtual NetworkInterface {
Expand Down Expand Up @@ -99,21 +99,21 @@ class EMACInterface : public virtual NetworkInterface {
/** Get the local IP address
*
* @return Null-terminated representation of the local IP address
* or null if no IP address has been recieved
* or null if no IP address has been received
*/
virtual const char *get_ip_address();

/** Get the local network mask
*
* @return Null-terminated representation of the local network mask
* or null if no network mask has been recieved
* or null if no network mask has been received
*/
virtual const char *get_netmask();

/** Get the local gateways
*
* @return Null-terminated representation of the local gateway
* or null if no network mask has been recieved
* or null if no network mask has been received
*/
virtual const char *get_gateway();

Expand Down
2 changes: 1 addition & 1 deletion features/netsocket/EthInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class EthInterface : public virtual NetworkInterface {
/** Get the default Ethernet interface.
*
* This is provided as a weak method so applications can override.
* Default behaviour is to get the target's default interface, if
* Default behavior is to get the target's default interface, if
* any.
*
* @return Pointer to interface, if one exists.
Expand Down
2 changes: 1 addition & 1 deletion features/netsocket/MeshInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class MeshInterface : public virtual NetworkInterface {
/** Get the default Mesh interface.
*
* This is provided as a weak method so applications can override.
* Default behaviour is to get the target's default interface, if
* Default behavior is to get the target's default interface, if
* any.
*
* @return pointer to interface, if any.
Expand Down
4 changes: 2 additions & 2 deletions features/netsocket/NetworkInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class NetworkInterface: public DNS {
* wifiInterface(), meshInterface(), cellularBase(), emacInterface() and checking
* for NULL pointers.
*
* The default behaviour is to return the default interface for the
* The default behavior is to return the default interface for the
* interface type specified by target.network-default-interface-type. Targets
* should set this in their targets.json to guide default selection,
* and applications may override.
Expand Down Expand Up @@ -306,7 +306,7 @@ class NetworkInterface: public DNS {
* need to override in simple cases.
*
* If a target has more elaborate interface selection, it can completely
* override this behaviour by implementing
* override this behavior by implementing
* NetworkInterface::get_target_default_instance() themselves, either
* unconditionally, or for a specific network-default-interface-type setting
*
Expand Down
6 changes: 3 additions & 3 deletions features/netsocket/Socket.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class Socket {
* Also connectionless protocols use the connected address to filter
* incoming packets for recv() and recvfrom() calls.
*
* To reset the peer address, zero initialised(default constructor) SocketAddress
* To reset the peer address, zero initialized(default constructor) SocketAddress
* object have to be in the address parameter.
*
* @param address The SocketAddress of the remote peer
Expand Down Expand Up @@ -234,9 +234,9 @@ class Socket {
* The server socket must be bound and set to listen for connections.
* On a new connection, returns connected network socket which user is expected to call close()
* and that deallocates the resources. Referencing a returned pointer after a close()
* call is not allowed and leads to undefined behaviour.
* call is not allowed and leads to undefined behavior.
*
* By default, accept blocks until incomming connection occurs. If socket is set to
* By default, accept blocks until incoming connection occurs. If socket is set to
* non-blocking or times out, error is set to NSAPI_ERROR_WOULD_BLOCK.
*
* @param error pointer to storage of the error value or NULL
Expand Down
4 changes: 2 additions & 2 deletions features/netsocket/TCPSocket.h
Original file line number Diff line number Diff line change
Expand Up @@ -158,9 +158,9 @@ class TCPSocket : public InternetSocket {
* The server socket must be bound and set to listen for connections.
* On a new connection, returns connected network socket which user is expected to call close()
* and that deallocates the resources. Referencing a returned pointer after a close()
* call is not allowed and leads to undefined behaviour.
* call is not allowed and leads to undefined behavior.
*
* By default, accept blocks until incomming connection occurs. If socket is set to
* By default, accept blocks until incoming connection occurs. If socket is set to
* non-blocking or times out, error is set to NSAPI_ERROR_WOULD_BLOCK.
*
* @param error pointer to storage of the error value or NULL
Expand Down
2 changes: 1 addition & 1 deletion features/netsocket/TLSSocketWrapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ class TLSSocketWrapper : public Socket {

/** Initiates TLS Handshake
*
* Initiates a TLS hanshake to a remote speer
* Initiates a TLS handshake to a remote peer
* Underlying transport socket should already be connected
*
* Root CA certification must be set by set_ssl_ca_pem() before
Expand Down
2 changes: 1 addition & 1 deletion features/netsocket/WiFiInterface.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class WiFiInterface: public virtual NetworkInterface {
/** Get the default Wi-Fi interface.
*
* This is provided as a weak method so applications can override.
* Default behaviour is to get the target's default interface, if
* Default behavior is to get the target's default interface, if
* any.
*
* @return pointer to interface, if any.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ class PPPCellularInterface : public CellularBase {
*
* @deprecated This API will be deprecated in mbed-os-5.9. Use mbed-os/features/cellular/easy_cellular/EasyCellularConnection.h instead.
*
* Please check documentation of connect() for default behaviour of APN settings.
* Please check documentation of connect() for default behavior of APN settings.
*
* @param apn Access point name
* @param uname optionally, Username
Expand Down Expand Up @@ -176,7 +176,7 @@ class PPPCellularInterface : public CellularBase {
* by the cellular modem over PPP interface.
*
* If the SIM requires a PIN, and it is not set/invalid, NSAPI_ERROR_AUTH_ERROR is returned.
* For APN setup, default behaviour is to use 'internet' as APN string and assuming no authentication
* For APN setup, default behavior is to use 'internet' as APN string and assuming no authentication
* is required, i.e., username and password are not set. Optionally, a database lookup can be requested
* by turning on the APN database lookup feature. In order to do so, add 'MBED_CONF_PPP_CELL_IFACE_APN_LOOKUP'
* in your mbed_app.json. APN database is by no means exhaustive. It contains a short list of some public
Expand Down
4 changes: 2 additions & 2 deletions features/netsocket/cellular/onboard_modem_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
#ifndef ONBOARD_MODEM_API_H_
#define ONBOARD_MODEM_API_H_

/** onboard_modem_api is a standardizing API for Modem type devices under mbed-os.
/** onboard_modem_api is a standardizing API for Modem type devices under Mbed OS.
* It provides a simple hardware abstraction layer on top of the modem drivers
* written for mbed-os.
* written for Mbed OS.
*
* It is required from the engineers porting any modem type device (e.g., Cellular)
* to provide an implementation of this API in their respective target folder as well as
Expand Down
2 changes: 1 addition & 1 deletion features/netsocket/nsapi_types.h
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ typedef signed int nsapi_error_t;
*/
typedef unsigned int nsapi_size_t;

/** Type used to represent either a size or error pased through sockets
/** Type used to represent either a size or error passed through sockets
*
* A valid nsapi_size_or_error_t is either a non-negative size or a
* negative error code from the nsapi_error_t
Expand Down