Renesas APIs ***
一个线程,强行结束另外一个线程,并将其挂起:
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 ***的更多相关文章
- (转载)构建public APIs与CORS
from: https://segmentfault.com/a/1190000000709909 理由:在操作层面详细的讲解了跨域的操作.尤其是对于option请求的详解.收藏. 在构建Public ...
- ECMAScript Web APIs node.js
https://hacks.mozilla.org/2015/04/es6-in-depth-an-introduction/ What falls under the scope of ECMASc ...
- 【墙内备份】Android 6.0 APIs
Android 6.0 APIs In this documentSHOW MORE Fingerprint Authentication Confirm Credential App Linking ...
- swagger:The World's Most Popular Framework for APIs.
swagger官网:http://swagger.io/ swagger ui demo:http://petstore.swagger.io 让API文档总是与API定义同步更新,是一件非常有价值的 ...
- [译]Node.js : Building RESTful APIs using Loopback and MySQL
国庆后可能就要使用StrongLoop那套东西来做项目了 原文:http://www.javabeat.net/loopback-mysql/ Loopback是什么? Loopback是一个开源的N ...
- URLRedirector 解决网页上无法访问 google CDN 的问题(fonts、ajax、themes、apis等)
URLRedirector 解决网页上无法访问 google CDN 的问题(fonts.ajax.themes.apis等) 由于某些原因,在访问国外的网站时有时候会特别慢,像 stackoverf ...
- 谷歌正式发布Google APIs Client Library for .NET
好消息,特大好消息! 英文原文:Google API library for .NET paves the way for Google services on Windows phone 本月 17 ...
- POSTMAN and HTTPie to test APIs
http://blog.mashape.com/postman-httpie-test-apis/ We love working with APIs at Mashape, and we love ...
- Android SDK Manager Google Apis 下载
本意是想利用google的gcm来实装android推送功能的,很遗憾, google貌似已经停止提供啥服务给国内了,或者说国内想继续使用google 服务暂时变得几乎不可能了.找了个代理来进行goo ...
随机推荐
- 007-对象—— static静态方法属性内存构成及使用方法讲解
<?php /* 7 对象 static静态方法属性内存构成及使用方法讲解 */ /*class a{ public $uname=11; static public function _a() ...
- C#运算符笔记
C# 原来也可以进行向量运算,这里解决了一个为时已久的疑惑. operator struct Vector { public double x, y, z; public Vector(double ...
- hdu4115
题解: 2-sat 对于bob出的每一张牌,alice显然只有两种选择 然后对于每一个限制,连边 判断是否可行 代码: #include<cstdio> #include<cmath ...
- zoj3656
题解: 按照位展开,然后一位一位判断 注意判断给出数据是否有问题 代码: #include<cstdio> #include<cmath> #include<algori ...
- 1D mesauring
The Basics of Measure Objects 2.1 the process of 1D Edge extraction Then, the mean ...
- CMDB配置资源管理数据库(理解)
CMDB是运维自动化的基础,它为日志系统,发布系统,监控系统等运维系统(ELK,zabbix,open-falcon)提供接口函数, 第一种方式:Agent方法实现,agent不能直接访问数据库,因为 ...
- Win10启动盘制作工具
Rufus https://rufus.akeo.ie/ http://www.iplaysoft.com/windows-10-udisk-install.html
- CUDA Samples: Calculate Histogram(atomicAdd)
以下CUDA sample是分别用C++和CUDA实现的计算一维直方图,并对其中使用到的CUDA函数进行了解说,code参考了<GPU高性能编程CUDA实战>一书的第九章,各个文件内容如下 ...
- Azure 软件架构选择
1. 传统的分层结构+message broker + worker传统的层结构老生常谈了: UI 层,service,业务逻辑,数据层.就不赘述了与worker形成producer-consumer ...
- 【剑指offer】06从尾到头打印链表,C++实现
本文是原创文章,转载请注明出处! 0.前言 # 本文为牛客网<剑指offer>刷题笔记 1.题目 # 输入一个链表,从尾到头打印链表每个节点的值 2.思路 # 不改变链表结构的情况下,首先 ...