一个线程,强行结束另外一个线程,并将其挂起:

static void SuspendTask(TX_THREAD *thread)
{
UINT status = ;
UINT state; status = tx_thread_terminate(thread);
if(status != TX_SUCCESS)
return ;
do
{
tx_thread_sleep();
status = tx_thread_info_get(thread, NULL, &state, NULL, NULL, NULL, NULL, NULL, NULL);
if (status != TX_SUCCESS)
{
xp_log("can not get clean thread status (0x%02x)\r\n", status);
break;
}
} while (!(state & (TX_COMPLETED | TX_TERMINATED)));
tx_thread_reset(thread);
}

启动

static void StartRawTask(void)
{
UINT status = ;
UINT state; status = tx_thread_info_get(&rawThread, NULL, &state, NULL, NULL, NULL, NULL, NULL, NULL);
if(status == TX_SUCCESS)
{
if(state == TX_SUSPENDED)
tx_thread_resume(&rawThread);
}
else
tx_thread_create(&rawThread, (CHAR *) "raw thread", RawThreadCallback, (ULONG)(&MaterialBoxTempT3), &raw_stack, COMMON_THREAD_STACK, , , , TX_AUTO_START);
}

nx_api.h

nx_ip_address_get

nx_packet_pool_create

nx_packet_pool_info_get

nx_tcp_socket_bytes_available

nx_tcp_socket_info_get

nx_tcp_socket_mss_get

系统重启

NVIC_SystemReset

static ULONG _get_time(void)
{
ULONG seconds, milliseconds;
UINT status; /* Get local time as set by SNTP client */
status = nx_sntp_client_get_local_time(&g_sntp_client, &seconds, &milliseconds, NX_NULL);
if (status != NX_SUCCESS)
return ; /* Convert to Unix epoch */
seconds -= UNIX_TO_NTP_EPOCH_SECS; return seconds;
}

TCP/UDP

nx_tcp_client_socket_bind
nx_tcp_server_socket_accept
nx_tcp_server_socket_listen
nx_tcp_socket_create
/* APIs for packet pool. */ 
/* APIs for packet pool. */
#define nx_packet_allocate _nxe_packet_allocate
#define nx_packet_copy _nxe_packet_copy
#define nx_packet_data_append _nxe_packet_data_append
#define nx_packet_data_extract_offset _nxe_packet_data_extract_offset
#define nx_packet_data_retrieve _nxe_packet_data_retrieve
#define nx_packet_length_get _nxe_packet_length_get
#define nx_packet_pool_create(p, n, l, m, s) _nxe_packet_pool_create(p, n, l, m, s, sizeof(NX_PACKET_POOL))
#define nx_packet_pool_delete _nxe_packet_pool_delete
#define nx_packet_pool_info_get _nxe_packet_pool_info_get
#define nx_packet_pool_low_watermark_set _nxe_packet_pool_low_watermark_set
#define nx_packet_release(p) _nxe_packet_release(&p)
#define nx_packet_transmit_release(p) _nxe_packet_transmit_release(&p)

Renesas APIs ***的更多相关文章

  1. (转载)构建public APIs与CORS

    from: https://segmentfault.com/a/1190000000709909 理由:在操作层面详细的讲解了跨域的操作.尤其是对于option请求的详解.收藏. 在构建Public ...

  2. ECMAScript Web APIs node.js

    https://hacks.mozilla.org/2015/04/es6-in-depth-an-introduction/ What falls under the scope of ECMASc ...

  3. 【墙内备份】Android 6.0 APIs

    Android 6.0 APIs In this documentSHOW MORE Fingerprint Authentication Confirm Credential App Linking ...

  4. swagger:The World's Most Popular Framework for APIs.

    swagger官网:http://swagger.io/ swagger ui demo:http://petstore.swagger.io 让API文档总是与API定义同步更新,是一件非常有价值的 ...

  5. [译]Node.js : Building RESTful APIs using Loopback and MySQL

    国庆后可能就要使用StrongLoop那套东西来做项目了 原文:http://www.javabeat.net/loopback-mysql/ Loopback是什么? Loopback是一个开源的N ...

  6. URLRedirector 解决网页上无法访问 google CDN 的问题(fonts、ajax、themes、apis等)

    URLRedirector 解决网页上无法访问 google CDN 的问题(fonts.ajax.themes.apis等) 由于某些原因,在访问国外的网站时有时候会特别慢,像 stackoverf ...

  7. 谷歌正式发布Google APIs Client Library for .NET

    好消息,特大好消息! 英文原文:Google API library for .NET paves the way for Google services on Windows phone 本月 17 ...

  8. POSTMAN and HTTPie to test APIs

    http://blog.mashape.com/postman-httpie-test-apis/ We love working with APIs at Mashape, and we love ...

  9. Android SDK Manager Google Apis 下载

    本意是想利用google的gcm来实装android推送功能的,很遗憾, google貌似已经停止提供啥服务给国内了,或者说国内想继续使用google 服务暂时变得几乎不可能了.找了个代理来进行goo ...

随机推荐

  1. hdu 5818 Joint Stacks (优先队列)

    Joint Stacks Time Limit: 8000/4000 MS (Java/Others)    Memory Limit: 65536/65536 K (Java/Others)Tota ...

  2. LeetCode OJ:Min Stack(最小栈问题)

    Design a stack that supports push, pop, top, and retrieving the minimum element in constant time. pu ...

  3. 虚拟机下的centos断电(非正常关机)后mysql启动不了

    在windows2003安装了vbox来部署centos. 但无法完美设置开机启动虚拟机里的系统. 只能把启动脚本放到用户的启动项里. server.bat "C:\Program File ...

  4. EFM32 ARM+ KEIl program

    1Hardware connection When using the EFM32 starter kit to make a JLINK burn, you must connect the con ...

  5. Spring警告: Could not load driverClass com.mysql.jdbc.Driver(待解决)

    在一个Spring项目中,新建了一个外部属性文件db.properties,在xml文件中利用${}来引用db.properties文件里面的属性. beans-properties.xml: < ...

  6. oracle管道函数的用法

    oracle管道函数是一类特殊的函数,oracle管道函数返回值类型必须为集合,下面将介绍oracle管道函数的语法. 在普通的函数中,使用dbms_output输出的信息,需要在服务器执行完整个函数 ...

  7. 看完前任三,想起我的前任java女程序员,她曾教会我……

    前任三最近非常火了,票房蹭蹭往上升,昨天也去电影院看了,想起了我的前任,她是一名女程序员,为了让我学好java,她曾经亲自教我Java的算法,学算法是件非常重要的事,在这忍住回忆的悲伤,分享给你们. ...

  8. 掌握Git撤销操作,随心所欲控制文件状态

    本文主要讨论和撤销有关的 git 操作.目的是让读者在遇到关于撤销问题时能够方便迅速对照执行解决问题,而不用去翻阅参数繁多的 git 使用说明. 一开始你只需了解大致功能即可,不必记住所有命令和具体参 ...

  9. windows命令行工具

    winver 检查Windows版本 wmimgmt.msc 打开Windows管理体系结构(wmi) wupdmgr Windows更新程序 wscript Windows脚本宿主设置 write ...

  10. Apache下配置Openstack Horizon (转)

    非常详尽的Horizon配置介绍,转自 dev.cloudwatt.com Deploy Horizon from source with Apache and SSL Some companies ...