Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
RIOT
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
cm-projects
RIOT
Commits
dad883c7
Commit
dad883c7
authored
9 years ago
by
Martine Lenders
Browse files
Options
Downloads
Patches
Plain Diff
netdev2: provide capability to pass up packet status information
parent
65caa15d
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
drivers/include/net/netdev2.h
+14
-1
14 additions, 1 deletion
drivers/include/net/netdev2.h
with
14 additions
and
1 deletion
drivers/include/net/netdev2.h
+
14
−
1
View file @
dad883c7
...
...
@@ -71,6 +71,16 @@ typedef enum {
/* expand this list if needed */
}
netdev2_event_t
;
/**
* @brief Received packet status information for most radios
*
* May be different for certain radios.
*/
struct
netdev2_radio_rx_info
{
uint8_t
rssi
;
/**< RSSI of a received packet */
uint8_t
lqi
;
/**< LQI of a received packet */
};
/**
* @brief Forward declaration for netdev2 struct
*/
...
...
@@ -122,12 +132,15 @@ typedef struct netdev2_driver {
* @param[in] dev network device descriptor
* @param[out] buf buffer to write into or NULL
* @param[in] len maximum nr. of bytes to read
* @param[out] info status information for the received packet. Might
* be of different type for different netdev2 devices.
* May be NULL if not needed or applicable.
*
* @return <=0 on error
* @return nr of bytes read if buf != NULL
* @return packet size if buf == NULL
*/
int
(
*
recv
)(
netdev2_t
*
dev
,
char
*
buf
,
int
len
);
int
(
*
recv
)(
netdev2_t
*
dev
,
char
*
buf
,
int
len
,
void
*
info
);
/**
* @brief the driver's initialization function
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment