MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / sys_device_read

Function sys_device_read

components/lwp/lwp_syscall.c:5016–5019  ·  view source on GitHub ↗

* @brief Reads data from an open device. * * This system call reads data from the specified device, starting at the given position and * storing the data in the provided buffer. The device must be open before this function can be called. * The amount of data to read is determined by the `size` parameter. * * @param[in] dev A pointer to the device structure representing the device to rea

Source from the content-addressed store, hash-verified

5014 * Providing an insufficient buffer may result in undefined behavior.
5015 */
5016rt_ssize_t sys_device_read(rt_device_t dev, rt_off_t pos, void *buffer, rt_size_t size)
5017{
5018 return rt_device_read(dev, pos, buffer, size);
5019}
5020
5021/**
5022 * @brief Writes data to an open device.

Callers

nothing calls this directly

Calls 1

rt_device_readFunction · 0.85

Tested by

no test coverage detected