Option for lwip link status poll interval.
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@5047 35acf78f-673a-0410-8e92-d51de3d6d3f4master
parent
fe7aa77ae0
commit
9754c3a6ce
|
@ -177,7 +177,7 @@ typedef struct MACDriver MACDriver;
|
|||
*
|
||||
* @api
|
||||
*/
|
||||
#define magGetNextReceiveBuffer(rdp, sizep) \
|
||||
#define macGetNextReceiveBuffer(rdp, sizep) \
|
||||
mac_lld_get_next_receive_buffer(rdp, sizep)
|
||||
#endif /* MAC_USE_ZERO_COPY */
|
||||
/** @} */
|
||||
|
|
|
@ -262,7 +262,7 @@ msg_t lwip_thread(void *p) {
|
|||
netif_set_up(&thisif);
|
||||
|
||||
/* Setup event sources.*/
|
||||
evtInit(&evt, S2ST(5));
|
||||
evtInit(&evt, LWIP_LINK_POLL_INTERVAL);
|
||||
evtStart(&evt);
|
||||
chEvtRegisterMask(&evt.et_es, &el0, PERIODIC_TIMER_ID);
|
||||
chEvtRegisterMask(macGetReceiveEventSource(ÐD1), &el1, FRAME_RECEIVED_ID);
|
||||
|
|
|
@ -33,6 +33,16 @@
|
|||
#define LWIP_THREAD_PRIORITY LOWPRIO
|
||||
#endif
|
||||
|
||||
/** @brief MAC thread stack size. */
|
||||
#if !defined(LWIP_THREAD_STACK_SIZE) || defined(__DOXYGEN__)
|
||||
#define LWIP_THREAD_STACK_SIZE 512
|
||||
#endif
|
||||
|
||||
/** @brief Link poll interval. */
|
||||
#if !defined(LWIP_LINK_POLL_INTERVAL) || defined(__DOXYGEN__)
|
||||
#define LWIP_LINK_POLL_INTERVAL S2ST(5)
|
||||
#endif
|
||||
|
||||
/** @brief IP Address. */
|
||||
#if !defined(LWIP_IPADDR) || defined(__DOXYGEN__)
|
||||
#define LWIP_IPADDR(p) IP4_ADDR(p, 192, 168, 1, 20)
|
||||
|
@ -48,11 +58,6 @@
|
|||
#define LWIP_NETMASK(p) IP4_ADDR(p, 255, 255, 255, 0)
|
||||
#endif
|
||||
|
||||
/** @brief MAC thread stack size. */
|
||||
#if !defined(LWIP_THREAD_STACK_SIZE) || defined(__DOXYGEN__)
|
||||
#define LWIP_THREAD_STACK_SIZE 512
|
||||
#endif
|
||||
|
||||
/** @brief Transmission timeout. */
|
||||
#if !defined(LWIP_SEND_TIMEOUT) || defined(__DOXYGEN__)
|
||||
#define LWIP_SEND_TIMEOUT 50
|
||||
|
|
|
@ -98,6 +98,7 @@
|
|||
TODO: Create a FatFS wrapper implementing the interface and using a server
|
||||
thread for synchronization.
|
||||
TODO: Create an implementation over a read-only file system in code space.
|
||||
- NEW: Added an option to lwipthread to change the link status poll interval.
|
||||
- NEW: Added new C++ demo for the STM32F4-Discovery.
|
||||
- NEW: Updated C++ wrapper with a much more logical classes structure.
|
||||
TODO: Opdate older C++ demos.
|
||||
|
|
Loading…
Reference in New Issue