久久久久久久999_99精品久久精品一区二区爱城_成人欧美一区二区三区在线播放_国产精品日本一区二区不卡视频_国产午夜视频_欧美精品在线观看免费

標題: STM32 Labview USB通信源碼 [打印本頁]

作者: gaosong12    時間: 2018-4-27 21:03
標題: STM32 Labview USB通信源碼
labview 的usb通信


單片機源程序如下:
  1. /**
  2.   ******************************************************************************
  3.   * @file    main.c
  4.   * @author  MCD Application Team
  5.   * @version V4.0.0
  6.   * @date    21-January-2013
  7.   * @brief   Virtual Com Port Demo main file
  8.   ******************************************************************************
  9.   * @attention
  10.   *
  11.   * <h2><center>© COPYRIGHT 2013 STMicroelectronics</center></h2>
  12.   *
  13.   * Licensed under MCD-ST Liberty SW License Agreement V2, (the "License");
  14.   * You may not use this file except in compliance with the License.
  15.   * You may obtain a copy of the License at:
  16.   *
  17.   *
  18.   * Unless required by applicable law or agreed to in writing, software
  19.   * distributed under the License is distributed on an "AS IS" BASIS,
  20.   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  21.   * See the License for the specific language governing permissions and
  22.   * limitations under the License.
  23.   *
  24.   ******************************************************************************
  25.   */


  26. /* Includes ------------------------------------------------------------------*/
  27. #include "hw_config.h"
  28. #include "usb_lib.h"
  29. #include "usb_desc.h"
  30. #include "usb_pwr.h"
  31. #include <string.h>
  32. #include <stdio.h>
  33. #include <stdlib.h>
  34. /* Private typedef -----------------------------------------------------------*/
  35. /* Private define ------------------------------------------------------------*/
  36. /* Private macro -------------------------------------------------------------*/
  37. /* Private variables ---------------------------------------------------------*/
  38. /* Extern variables ----------------------------------------------------------*/
  39. /* Private function prototypes -----------------------------------------------*/
  40. /* Private functions ---------------------------------------------------------*/

  41. /*******************************************************************************
  42. * Function Name  : main.
  43. * Description    : Main routine.
  44. * Input          : None.
  45. * Output         : None.
  46. * Return         : None.
  47. *******************************************************************************/
  48. extern uint32_t USB_SIL_WriteEDP1Dbbuf( uint8_t* pBufferPointer, uint32_t wBufferSize);
  49. u8 t;
  50. char usbsndbuf[64];

  51. void  snddata(void)
  52. {
  53. static        int i=0;
  54. int len;        
  55. i++;

  56. USB_SIL_WriteEDP1Dbbuf(usbsndbuf, 64);
  57.         

  58. }

  59. int main(void)
  60. {
  61.         for(t=0;t<64;t++)
  62.         usbsndbuf[t]=t;
  63.   Set_System();
  64.   Set_USBClock();
  65.   USB_Interrupts_Config();
  66.   USB_Init();
  67.   
  68.   while (1)
  69.   {

  70.                 snddata();
  71.                
  72.   }
  73. }
  74. #ifdef USE_FULL_ASSERT
  75. /*******************************************************************************
  76. * Function Name  : assert_failed
  77. * Description    : Reports the name of the source file and the source line number
  78. *                  where the assert_param error has occurred.
  79. * Input          : - file: pointer to the source file name
  80. *                  - line: assert_param error line source number
  81. * Output         : None
  82. * Return         : None
  83. *******************************************************************************/
  84. void assert_failed(uint8_t* file, uint32_t line)
  85. {
  86.   /* User can add his own implementation to report the file name and line number,
  87.      ex: printf("Wrong parameters value: file %s on line %d\r\n", file, line) */

  88.   /* Infinite loop */
  89.   while (1)
  90.   {}
  91. }
  92. #endif

  93. /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/
復制代碼

所有資料51hei提供下載:
STM32 Labview USB通信.rar (625.47 KB, 下載次數: 81)





作者: zpwang    時間: 2018-9-27 12:09
謝謝分享!




歡迎光臨 (http://m.zg4o1577.cn/bbs/) Powered by Discuz! X3.1
主站蜘蛛池模板: av不卡在线播放 | 成人三级视频在线观看 | 中文字幕三区 | 伊人精品在线 | 51成人做爰www免费看网站 | 亚洲性色av | 玖玖在线观看 | a级片免费在线观看 | av在线资源| 成人免费毛片aaaaaa片 | 在线观看二区 | 亚洲国产精品久久久久 | 六月丁香综合 | 亚洲精品一区二三区不卡 | 色综合天天综合网国产成人网 | 一区二区在线免费观看 | 一区二区视频在线播放 | 欧美性久久 | txvlog.com| www.爱爱 | 午夜aaa| 亚洲第一第二区 | 三级黄网站 | 日韩精品少妇 | 日韩中文字幕一区 | 亚洲天堂第一页 | 中文在线观看免费高清 | 黄色三级在线 | 欧美一级网站 | 欧美日韩国产在线播放 | 亚洲天堂免费 | 欧美精品一区二区在线观看 | 少妇免费视频 | 国产精品美女久久久久av爽 | 日本成人免费网站 | 午夜精品999 | 奇米网888| 日本精品视频在线 | 欧美一级网站 | 国产精品一区二区久久 | 中国黄色1级片 |