Select one of the symbols to view example projects that use it.
 
Outline
...
...
...
...
...
...
#define UX_NETWORK_DRIVER_H
#include "tx_api.h"
#include "nx_api.h"
#define USB_NETWORK_DEVICE_MAX_INSTANCES
#define USB_NETWORK_DRIVER_SUCCESS
#define USB_NETWORK_DRIVER_FAILURE
#define USB_NETWORK_DEVICE_MAC_HEADER_SIZE
#define NX_ETHERNET_SIZE
#define NX_ETHERNET_ARP
#define NX_ETHERNET_RARP
#define NX_ETHERNET_IP
#define NX_ETHERNET_IPV6
#define NX_ETHERNET_MTU
USB_NETWORK_DEVICE_STRUCT
_ux_network_driver_init();
_ux_network_driver_activate(void *, UINT (*)(void *, NX_PACKET *), void **, ULONG, ULONG);
_ux_network_driver_deactivate(void *, void *);
_ux_network_driver_entry(NX_IP_DRIVER *);
_ux_network_driver_link_up(void *);
_ux_network_driver_link_down(void *);
_ux_network_driver_packet_received(void *, NX_PACKET *);
Files
loading...
SourceVuSTM32 Libraries and Samplesusbxcommon/usbx_network/inc/ux_network_driver.h
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
/**************************************************************************/ /* */ /* Copyright (c) Microsoft Corporation. All rights reserved. */ /* */ /* This software is licensed under the Microsoft Software License */ /* Terms for Microsoft Azure RTOS. Full text of the license can be */ /* found in the LICENSE file at https://aka.ms/AzureRTOS_EULA */ /* and in the root directory of this software. */ /* */... /**************************************************************************/ ... /**************************************************************************/ /**************************************************************************/ /** */ /** USBX Component */ /** */ /** USBX Network Driver for NETX 5.3 and above */ /** */... /**************************************************************************/ /**************************************************************************/ ... /**************************************************************************/ /* */ /* COMPONENT DEFINITION RELEASE */ /* */ /* ux_network_driver.h PORTABLE C */ /* 6.1.8 */ /* AUTHOR */ /* */ /* Chaoqiong Xiao, Microsoft Corporation */ /* */ /* DESCRIPTION */ /* */ /* This file contains all the header and extern functions used by the */ /* USBX Network driver. */ /* */ /* RELEASE HISTORY */ /* */ /* DATE NAME DESCRIPTION */ /* */ /* 05-19-2020 Chaoqiong Xiao Initial Version 6.0 */ /* 09-30-2020 Chaoqiong Xiao Modified comment(s), */ /* resulting in version 6.1 */ /* 08-02-2021 Wen Wang Modified comment(s), */ /* fixed spelling error, */ /* added extern "C" keyword */ /* for compatibility with C++, */ /* resulting in version 6.1.8 */ /* */... /**************************************************************************/ #ifndef UX_NETWORK_DRIVER_H #define UX_NETWORK_DRIVER_H /* Determine if a C++ compiler is being used. If so, ensure that standard C is used to process the API information. *//* ... */ #ifdef __cplusplus /* Yes, C++ compiler is present. Use standard C. */ extern "C" { #endif #include "tx_api.h" #include "nx_api.h" #define USB_NETWORK_DEVICE_MAX_INSTANCES 8 #define USB_NETWORK_DRIVER_SUCCESS UX_SUCCESS #define USB_NETWORK_DRIVER_FAILURE UX_ERROR #define USB_NETWORK_DEVICE_MAC_HEADER_SIZE 14 #define NX_ETHERNET_SIZE 14 #define NX_ETHERNET_ARP 0x0806 #define NX_ETHERNET_RARP 0x0835 #define NX_ETHERNET_IP 0x0800 #define NX_ETHERNET_IPV6 0x08DD #define NX_ETHERNET_MTU 1514 10 defines typedef struct USB_NETWORK_DEVICE_STRUCT { /* ip_instance is populated by NetX, as part of the interface attachment. */ NX_IP *ux_network_device_ip_instance; /* interface_ptr is populated by NetX, as part of the interface attachment. */ NX_INTERFACE *ux_network_device_interface_ptr; /* Define synchronization objects for deactivation. Note that these are only used if the activation/deactivation functions are not called under interrupt. *//* ... */ UCHAR ux_network_device_activated_by_thread; TX_MUTEX ux_network_device_deactivate_mutex; TX_SEMAPHORE ux_network_device_deactivate_semaphore; UCHAR ux_network_device_deactivate_thread_waiting; UINT ux_network_device_num_threads_inside; /* usb_instance is populated by USB instance activation. */ VOID *ux_network_device_usb_instance_ptr; /* The write_function is populated by USB instance activation. */ UINT (*ux_network_device_write_function)(VOID *ux_instance, NX_PACKET *packet_ptr); USHORT ux_network_device_usb_link_up; USHORT ux_network_device_link_status; ULONG ux_network_physical_address_msw; ULONG ux_network_physical_address_lsw; ...} USB_NETWORK_DEVICE_TYPE; UINT _ux_network_driver_init(VOID); UINT _ux_network_driver_activate(VOID *ux_instance, UINT(*ux_network_device_write_function)(VOID *, NX_PACKET *), VOID **ux_network_handle, ULONG physical_address_msw, ULONG physical_address_lsw); UINT _ux_network_driver_deactivate(VOID *ux_instance, VOID *ux_network_handle); VOID _ux_network_driver_entry(NX_IP_DRIVER *nx_ip_driver); VOID _ux_network_driver_link_up(VOID *ux_network_handle); VOID _ux_network_driver_link_down(VOID *ux_network_handle); VOID _ux_network_driver_packet_received(VOID *ux_network_handle, NX_PACKET *packet_ptr); /* Determine if a C++ compiler is being used. If so, complete the standard C conditional started above. *//* ... */ #ifdef __cplusplus }extern "C" { ... } #endif /* ... */ ...#endif
Details
Show:
from
Types: Columns:
This file uses the notable symbols shown below. Click anywhere in the file to view more details.