* @brief This function finds a device driver by specified name. * * @param name is the device driver's name. * * @return the registered device driver on successful, or RT_NULL on failure. */
| 120 | * @return the registered device driver on successful, or RT_NULL on failure. |
| 121 | */ |
| 122 | rt_device_t rt_device_find(const char *name) |
| 123 | { |
| 124 | return (rt_device_t)rt_object_find(name, RT_Object_Class_Device); |
| 125 | } |
| 126 | RTM_EXPORT(rt_device_find); |
| 127 | |
| 128 | #ifdef RT_USING_HEAP |