您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ xSerialPutChar函数代码示例

51自学网 2021-06-03 10:14:34
  C++
这篇教程C++ xSerialPutChar函数代码示例写得很实用,希望能帮到您。

本文整理汇总了C++中xSerialPutChar函数的典型用法代码示例。如果您正苦于以下问题:C++ xSerialPutChar函数的具体用法?C++ xSerialPutChar怎么用?C++ xSerialPutChar使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。

在下文中一共展示了xSerialPutChar函数的16个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: vSerialPutString

void vSerialPutString( xComPortHandle pxPort, const signed char * const pcString, unsigned short usStringLength ){signed char *pxNext;	/* A couple of parameters that this port does not use. */	( void ) usStringLength;	( void ) pxPort;	/* NOTE: This implementation does not handle the queue being full as no block time is used! */	/* The port handle is not required as this driver only supports UART0. */	( void ) pxPort;	/* Send each character in the string, one at a time. */	pxNext = ( signed char * ) pcString;	while( *pxNext )	{		xSerialPutChar( pxPort, *pxNext, serNO_BLOCK );		pxNext++;	}}
开发者ID:BirdBare,项目名称:STM32F4-Discovery_FW_V1.1.0_Makefiles,代码行数:21,


示例2: portTASK_FUNCTION

static portTASK_FUNCTION( vComTxTask, pvParameters ){signed char cByteToSend;portTickType xTimeToWait;	/* Just to stop compiler warnings. */	( void ) pvParameters;	for( ;; )	{		/* Simply transmit a sequence of characters from comFIRST_BYTE to		comLAST_BYTE. */		for( cByteToSend = comFIRST_BYTE; cByteToSend <= comLAST_BYTE; cByteToSend++ )		{			if( xSerialPutChar( xPort, cByteToSend, comNO_BLOCK ) == pdPASS )			{				vParTestToggleLED( uxBaseLED + comTX_LED_OFFSET );			}		}		/* Turn the LED off while we are not doing anything. */		vParTestSetLED( uxBaseLED + comTX_LED_OFFSET, pdFALSE );		/* We have posted all the characters in the string - wait before		re-sending.  Wait a pseudo-random time as this will provide a better		test. */		xTimeToWait = xTaskGetTickCount() + comOFFSET_TIME;		/* Make sure we don't wait too long... */		xTimeToWait %= comTX_MAX_BLOCK_TIME;		/* ...but we do want to wait. */		if( xTimeToWait < comTX_MIN_BLOCK_TIME )		{			xTimeToWait = comTX_MIN_BLOCK_TIME;		}		vTaskDelay( xTimeToWait );	}} /*lint !e715 !e818 pvParameters is required for a task function even if it is not referenced. */
开发者ID:LinuxJohannes,项目名称:FreeRTOS,代码行数:40,


示例3: prvUSARTEchoTask

/* Described at the top of this file. */static void prvUSARTEchoTask( void *pvParameters ){signed char cChar;/* String declared static to ensure it does not end up on the stack, no matterwhat the optimisation level. */static const char *pcLongishString = "ABBA was a Swedish pop music group formed in Stockholm in 1972, consisting of Anni-Frid Frida Lyngstad, ""Bj
C++ xT函数代码示例
C++ xSemaphoreTakeRecursive函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。