⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sys_cfg.h

📁 picoos源码。The RTOS and the TCP/IP stack will be built automatically.
💻 H
字号:
/*
 *  Copyright (c) 2004-2005, Dennis Kuschel.
 *  All rights reserved. 
 *
 *  Redistribution and use in source and binary forms, with or without
 *  modification, are permitted provided that the following conditions
 *  are met:
 *
 *   1. Redistributions of source code must retain the above copyright
 *      notice, this list of conditions and the following disclaimer.
 *   2. Redistributions in binary form must reproduce the above copyright
 *      notice, this list of conditions and the following disclaimer in the
 *      documentation and/or other materials provided with the distribution.
 *   3. The name of the author may not be used to endorse or promote
 *      products derived from this software without specific prior written
 *      permission. 
 *
 *  THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
 *  OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
 *  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 *  ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT,
 *  INDIRECT,  INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
 *  (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
 *  SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 *  HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
 *  STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
 *  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
 *  OF THE POSSIBILITY OF SUCH DAMAGE.
 *
 */

#include "lwip/opt.h"


/** Maximum number of mailboxes.
 */
#define SYS_MBOX_MAX        ((3 * MEMP_NUM_NETCONN) + 2)


/** Maximum number of messages.
 */
#define SYS_MSG_MAX         ( MEMP_NUM_API_MSG + MEMP_NUM_TCPIP_MSG + \
                              MEMP_NUM_NETCONN + MEMP_NUM_NETBUF    + \
                              MEMP_NUM_PBUF                         + \
                              4 * (MEM_SIZE / TCP_MSS)                )


/** Set the offset (in bytes) into the pic]OS task user space memory.
 *  Note: This value is only of interest if lwIP is not the only one
 *        that uses the pico]OS function posTaskGetUserspace().
 */
#define SYS_USRSPACE_OFS    0


/** Stack size (in bytes) for new created tasks.
 *  Note: Please check if you have set the define NOSCFG_DEFAULT_STACKSIZE
 *        in the pico]OS port file port.h correctly.
 */
#define SYS_STACK_SIZE      NOSCFG_DEFAULT_STACKSIZE


/** Set the direction the processor stack grows:
 *   0 = from top to bottom (most usual)
 *   1 = from bottom to top
 *  Note: Please check if you have set the define NOSCFG_STACK_GROWS_UP
 *        in the pico]OS port file port.h correctly.
 */
#define SYS_STACK_GROWUP    NOSCFG_STACK_GROWS_UP


/** Maximum number of tasks that can be created with
 *  the function sys_thread_new().
 *  Note: This value is only of interest if you do not use the
 *        pico]OS nano layer and you have set POSCFG_TASKSTACKTYPE = 0
 */
#define SYS_THREAD_MAX      4


/** Enable the TCP/IP mailbox fix.
 *  On some systems, the lwIP receive throughput may increase when
 *  this define is set to 1. But note: This mailbox fix assumes that
 *  the first mailbox created is the tcpip-thread mailbox. Enable this
 *  fix only when you are really sure what you are doing.
 *  Details:  This fix gives API messages a higher priority than
 *            the IP input messages. This fix was discussed in the
 *            lwip mailing list.
 */
#define SYS_TCPIPMBOXFIX    0

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -