Skip to content

Commit

Permalink
Upstream PR #11073 review request changes (#11135)
Browse files Browse the repository at this point in the history
* Modify Doxygen grouping of `drivers` Public/Internal APIs
* Correct classification of `mbed_events.h`
* Amend name of Doxygen group containing Device Key API
* Classify `CallChain.h` as public API and relocate file
* Remove Doxygen group from `equeue_platform.h` as it has no Doxygen compliant documentation
* Move USB target specific code back to `usb/device/targets`
  • Loading branch information
hugueskamba authored and evedon committed Aug 1, 2019
1 parent c40d086 commit 8fb395b
Show file tree
Hide file tree
Showing 47 changed files with 79 additions and 73 deletions.
6 changes: 1 addition & 5 deletions drivers/BusIn.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,9 @@
#include "platform/NonCopyable.h"

namespace mbed {
/** \defgroup drivers-public-api-bus Bus
* \ingroup drivers-public-api
*/

/**
* \defgroup drivers_BusIn BusIn class
* \ingroup drivers-public-api-bus
* \ingroup drivers-public-api-gpio
* @{
*/

Expand Down
2 changes: 1 addition & 1 deletion drivers/BusInOut.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
namespace mbed {
/**
* \defgroup drivers_BusInOut BusInOut class
* \ingroup drivers-public-api-bus
* \ingroup drivers-public-api-gpio
* @{
*/

Expand Down
2 changes: 1 addition & 1 deletion drivers/BusOut.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
namespace mbed {
/**
* \defgroup drivers_BusOut BusOut class
* \ingroup drivers-public-api-bus
* \ingroup drivers-public-api-gpio
* @{
*/

Expand Down
14 changes: 14 additions & 0 deletions drivers/Ethernet.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@ namespace mbed {
*/

/** An ethernet interface, to use with the ethernet pins.
*
* @deprecated
* EthInterface is now the preferred way to get an Ethernet object.
* Alternatively, use NetworkInterface to get an instance of an appropriate network
* interface (WiFi or Ethernet).
*
* @note Synchronization level: Not protected
*
Expand Down Expand Up @@ -72,10 +77,12 @@ class

/** Initialize the ethernet interface.
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
Ethernet();

/** Powers the hardware down.
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
virtual ~Ethernet();

enum Mode {
Expand All @@ -96,6 +103,7 @@ class
* @returns
* The number of written bytes.
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
int write(const char *data, int size);

/** Send an outgoing ethernet packet.
Expand All @@ -107,6 +115,7 @@ class
* 0 if the sending was failed,
* or the size of the packet successfully sent.
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
int send();

/** Receives an arrived ethernet packet.
Expand All @@ -119,6 +128,7 @@ class
* 0 if no ethernet packet is arrived,
* or the size of the arrived packet.
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
int receive();

/** Read from an received ethernet packet.
Expand All @@ -134,12 +144,14 @@ class
* Each time read will start reading after the last read byte before.
*
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
int read(char *data, int size);

/** Gives the ethernet address of the mbed.
*
* @param mac Must be a pointer to a 6 byte char array to copy the ethernet address in.
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
void address(char *mac);

/** Returns if an ethernet link is present or not. It takes a while after Ethernet initialization to show up.
Expand All @@ -165,6 +177,7 @@ class
* }
* @endcode
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
int link();

/** Sets the speed and duplex parameters of an ethernet link
Expand All @@ -177,6 +190,7 @@ class
*
* @param mode the speed and duplex mode to set the link to:
*/
MBED_DEPRECATED("The class has been deprecated and will be removed in the future.")
void set_link(Mode mode);
};

Expand Down
6 changes: 1 addition & 5 deletions drivers/InterruptIn.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,9 @@
#include "platform/NonCopyable.h"

namespace mbed {
/** \defgroup drivers-public-api-interrupt Interrupt
* \ingroup drivers-public-api
*/

/**
* \defgroup drivers_InterruptIn InterruptIn class
* \ingroup drivers-public-api-interrupt
* \ingroup drivers-public-api-gpio
* @{
*/

Expand Down
4 changes: 2 additions & 2 deletions drivers/InterruptManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@
#define MBED_INTERRUPTMANAGER_H

#include "cmsis.h"
#include "platform/internal/CallChain.h"
#include "platform/CallChain.h"
#include "platform/PlatformMutex.h"
#include "platform/NonCopyable.h"
#include <string.h>

namespace mbed {
/**
* \defgroup drivers_InterruptManager InterruptManager class
* \ingroup drivers-public-api-interrupt
* \ingroup drivers-public-api-gpio
* @{
*/

Expand Down
2 changes: 1 addition & 1 deletion drivers/SerialWireOutput.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
namespace mbed {
/**
* \defgroup drivers_SerialWireOutput SerialWireOutput class
* \ingroup drivers-public-api-uart
* \ingroup drivers-public-api
* @{
*/

Expand Down
5 changes: 1 addition & 4 deletions drivers/Watchdog.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,9 @@
#include <cstdio>

namespace mbed {
/** \ingroup mbed-os-public */
/** \addtogroup drivers-public-api */
/** @{*/
/**
* \defgroup drivers_Watchdog Watchdog class
* \ingroup drivers-public-api
* @{
*/

Expand Down Expand Up @@ -154,7 +152,6 @@ class Watchdog : private NonCopyable<Watchdog> {
bool _running;
};

/** @}*/
/** @}*/

} // namespace mbed
Expand Down
6 changes: 5 additions & 1 deletion drivers/internal/AsyncOp.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,13 @@
* \ingroup mbed-os-internal
*/

/** \defgroup drivers-internal-api-usb USB
* \ingroup drivers-internal-api
*/

/**
* \defgroup drivers_AsyncOp AsyncOp class
* \ingroup drivers-internal-api
* \ingroup drivers-internal-api-usb
* @{
*/
class AsyncOp: public LinkEntry {
Expand Down
2 changes: 1 addition & 1 deletion drivers/internal/ByteBuffer.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

/**
* \defgroup drivers_ByteBuffer ByteBuffer class
* \ingroup drivers-internal-api
* \ingroup drivers-internal-api-usb
* @{
*/
class ByteBuffer {
Expand Down
2 changes: 1 addition & 1 deletion drivers/internal/EndpointResolver.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

/**
* \defgroup drivers_EndpointResolver EndpointResolver class
* \ingroup drivers-internal-api
* \ingroup drivers-internal-api-usb
* @{
*/

Expand Down
2 changes: 1 addition & 1 deletion drivers/internal/LinkEntry.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

/**
* \defgroup drivers_LinkEntry LinkEntry class
* \ingroup drivers-internal-api-list
* \ingroup drivers-internal-api-usb
* @{
*/
class LinkEntry {
Expand Down
6 changes: 1 addition & 5 deletions drivers/internal/LinkedList.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,9 @@
#include "LinkEntry.h"
#include "LinkedListBase.h"

/** \defgroup drivers-internal-api-list List
* \ingroup drivers-internal-api
*/

/**
* \defgroup drivers_LinkedList LinkedList class
* \ingroup drivers-internal-api-list
* \ingroup drivers-internal-api-usb
* @{
*/
template<class T>
Expand Down
2 changes: 1 addition & 1 deletion drivers/internal/LinkedListBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

/**
* \defgroup drivers_LinkedListBase LinkedListBase class
* \ingroup drivers-internal-api-list
* \ingroup drivers-internal-api-usb
* @{
*/
class LinkedListBase {
Expand Down
2 changes: 1 addition & 1 deletion drivers/internal/MIDIMessage.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@

/**
* \defgroup drivers_MIDIMessage MIDIMessage class
* \ingroup drivers-internal-api
* \ingroup drivers-internal-usb
* @{
*/

Expand Down
7 changes: 7 additions & 0 deletions drivers/internal/OperationList.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@
#include "OperationListBase.h"
#include "AsyncOp.h"

/**
* \defgroup drivers_OperationList OperationList class
* \ingroup drivers-internal-api-usb
* @{
*/
template<class T>
class OperationList: public OperationListBase {
public:
Expand Down Expand Up @@ -84,4 +89,6 @@ class OperationList: public OperationListBase {

};

/** @}*/

#endif
7 changes: 7 additions & 0 deletions drivers/internal/OperationListBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@

class AsyncOp;

/**
* \defgroup drivers_OperationListBase OperationListBase class
* \ingroup drivers-internal-api-usb
* @{
*/
class OperationListBase {
public:

Expand Down Expand Up @@ -93,4 +98,6 @@ class OperationListBase {
LinkedListBase _list;
};

/** @}*/

#endif
11 changes: 2 additions & 9 deletions drivers/internal/PolledQueue.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,9 @@
#include "platform/Callback.h"
#include "LinkedList.h"
namespace events {
/** \addtogroup events-internal-api Events
* \ingroup mbed-os-internal
* @{
*/


/**
* \defgroup events_PolledQueue PolledQueue class
* \ingroup events-internal-api
* \defgroup drivers_PolledQueue PolledQueue class
* \ingroup drivers-internal-api-usb
* @{
*/

Expand Down Expand Up @@ -75,7 +69,6 @@ class PolledQueue: public TaskQueue {

};

/** @}*/
/** @}*/

}
Expand Down
3 changes: 1 addition & 2 deletions drivers/internal/Task.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@
#include "platform/Callback.h"

namespace events {
/** \addtogroup events-internal-api
* \ingroup mbed-os-internal
/** \addtogroup drivers-internal-api-usb
* @{
*/

Expand Down
4 changes: 2 additions & 2 deletions drivers/internal/TaskBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ namespace events {
class TaskQueue;

/**
* \defgroup events_TaskBase TaskBase class
* \ingroup events-internal-api
* \defgroup drivers_TaskBase TaskBase class
* \ingroup drivers-internal-api-usb
* @{
*/

Expand Down
4 changes: 2 additions & 2 deletions drivers/internal/TaskQueue.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@
namespace events {

/**
* \defgroup events_TaskQueue TaskQueue class
* \ingroup events-internal-api
* \defgroup drivers_TaskQueue TaskQueue class
* \ingroup drivers-internal-api-usb
* @{
*/

Expand Down
5 changes: 1 addition & 4 deletions drivers/internal/USBDevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,9 @@
#include "USBPhy.h"
#include "mbed_critical.h"

/** \ingroup drivers */
/** \addtogroup drivers-internal-api */
/** @{*/
/**
* \defgroup drivers_USBDevice USBDevice class
* \ingroup drivers-internal-api-usb
* @{
*/

Expand Down Expand Up @@ -612,7 +610,6 @@ class USBDevice: public USBPhyEvents {
uint32_t _locked;
};

/** @}*/
/** @}*/

#endif
2 changes: 1 addition & 1 deletion drivers/source/usb/mbed_lib.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"name": "usb"
"name": "drivers-usb"
}
8 changes: 0 additions & 8 deletions events/internal/equeue_platform.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,6 @@ extern "C" {
#include <stdbool.h>
#include <stdint.h>

/**
* \addtogroup events-internal-api Events
* \ingroup mbed-os-internal
* @{
*/

// Currently supported platforms
//
// Uncomment to select a supported platform or reimplement this file
Expand Down Expand Up @@ -153,8 +147,6 @@ void equeue_sema_destroy(equeue_sema_t *sema);
void equeue_sema_signal(equeue_sema_t *sema);
bool equeue_sema_wait(equeue_sema_t *sema, int ms);

/** @}*/

#ifdef __cplusplus
}
#endif
Expand Down
Loading

0 comments on commit 8fb395b

Please sign in to comment.