亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來(lái)到蟲(chóng)蟲(chóng)下載站! | ?? 資源下載 ?? 資源專(zhuān)輯 ?? 關(guān)于我們
? 蟲(chóng)蟲(chóng)下載站

?? stm32f10x_spi.c

?? 基于STM32的數(shù)碼相冊(cè).rar
?? C
?? 第 1 頁(yè) / 共 3 頁(yè)
字號(hào):
  SPI_InitStruct->SPI_FirstBit = SPI_FirstBit_MSB;

  /* Initialize the SPI_CRCPolynomial member */
  SPI_InitStruct->SPI_CRCPolynomial = 7;
}

/*******************************************************************************
* Function Name  : I2S_StructInit
* Description    : Fills each I2S_InitStruct member with its default value.
* Input          : - I2S_InitStruct : pointer to a I2S_InitTypeDef structure
*                    which will be initialized.
* Output         : None
* Return         : None
*******************************************************************************/
void I2S_StructInit(I2S_InitTypeDef* I2S_InitStruct)
{
/*--------------- Reset I2S init structure parameters values -----------------*/
  /* Initialize the I2S_Mode member */
  I2S_InitStruct->I2S_Mode = I2S_Mode_SlaveTx;
  
  /* Initialize the I2S_Standard member */
  I2S_InitStruct->I2S_Standard = I2S_Standard_Phillips;
  
  /* Initialize the I2S_DataFormat member */
  I2S_InitStruct->I2S_DataFormat = I2S_DataFormat_16b;
  
  /* Initialize the I2S_MCLKOutput member */
  I2S_InitStruct->I2S_MCLKOutput = I2S_MCLKOutput_Disable;
  
  /* Initialize the I2S_AudioFreq member */
  I2S_InitStruct->I2S_AudioFreq = I2S_AudioFreq_Default;
  
  /* Initialize the I2S_CPOL member */
  I2S_InitStruct->I2S_CPOL = I2S_CPOL_Low;
}

/*******************************************************************************
* Function Name  : SPI_Cmd
* Description    : Enables or disables the specified SPI peripheral.
* Input          : - SPIx: where x can be 1, 2 or 3 to select the SPI peripheral.
*                  - NewState: new state of the SPIx peripheral. 
*                    This parameter can be: ENABLE or DISABLE.
* Output         : None
* Return         : None
*******************************************************************************/
void SPI_Cmd(SPI_TypeDef* SPIx, FunctionalState NewState)
{
  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  assert_param(IS_FUNCTIONAL_STATE(NewState));

  if (NewState != DISABLE)
  {
    /* Enable the selected SPI peripheral */
    SPIx->CR1 |= CR1_SPE_Set;
  }
  else
  {
    /* Disable the selected SPI peripheral */
    SPIx->CR1 &= CR1_SPE_Reset;
  }
}

/*******************************************************************************
* Function Name  : I2S_Cmd
* Description    : Enables or disables the specified SPI peripheral (in I2S mode).
* Input          : - SPIx: where x can be 2 or 3 to select the SPI peripheral.
*                  - NewState: new state of the SPIx peripheral. 
*                    This parameter can be: ENABLE or DISABLE.
* Output         : None
* Return         : None
*******************************************************************************/
void I2S_Cmd(SPI_TypeDef* SPIx, FunctionalState NewState)
{
  /* Check the parameters */
  assert_param(IS_SPI_23_PERIPH(SPIx));
  assert_param(IS_FUNCTIONAL_STATE(NewState));

  if (NewState != DISABLE)
  {
    /* Enable the selected SPI peripheral (in I2S mode) */
    SPIx->I2SCFGR |= I2SCFGR_I2SE_Set;
  }
  else
  {
    /* Disable the selected SPI peripheral (in I2S mode) */
    SPIx->I2SCFGR &= I2SCFGR_I2SE_Reset;
  }
}

/*******************************************************************************
* Function Name  : SPI_I2S_ITConfig
* Description    : Enables or disables the specified SPI/I2S interrupts.
* Input          : - SPIx: where x can be :
*                         - 1, 2 or 3 in SPI mode 
*                         - 2 or 3 in I2S mode
*                  - SPI_I2S_IT: specifies the SPI/I2S interrupt source to be 
*                    enabled or disabled. 
*                    This parameter can be one of the following values:
*                       - SPI_I2S_IT_TXE: Tx buffer empty interrupt mask
*                       - SPI_I2S_IT_RXNE: Rx buffer not empty interrupt mask
*                       - SPI_I2S_IT_ERR: Error interrupt mask
*                  - NewState: new state of the specified SPI/I2S interrupt.
*                    This parameter can be: ENABLE or DISABLE.
* Output         : None
* Return         : None
*******************************************************************************/
void SPI_I2S_ITConfig(SPI_TypeDef* SPIx, u8 SPI_I2S_IT, FunctionalState NewState)
{
  u16 itpos = 0, itmask = 0 ;

  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  assert_param(IS_FUNCTIONAL_STATE(NewState));
  assert_param(IS_SPI_I2S_CONFIG_IT(SPI_I2S_IT));

  /* Get the SPI/I2S IT index */
  itpos = SPI_I2S_IT >> 4;
  /* Set the IT mask */
  itmask = (u16)((u16)1 << itpos);

  if (NewState != DISABLE)
  {
    /* Enable the selected SPI/I2S interrupt */
    SPIx->CR2 |= itmask;
  }
  else
  {
    /* Disable the selected SPI/I2S interrupt */
    SPIx->CR2 &= (u16)~itmask;
  }
}

/*******************************************************************************
* Function Name  : SPI_I2S_DMACmd
* Description    : Enables or disables the SPIx/I2Sx DMA interface.
* Input          : - SPIx: where x can be :
*                         - 1, 2 or 3 in SPI mode 
*                         - 2 or 3 in I2S mode
*                  - SPI_I2S_DMAReq: specifies the SPI/I2S DMA transfer request 
*                    to be enabled or disabled. 
*                    This parameter can be any combination of the following values:
*                       - SPI_I2S_DMAReq_Tx: Tx buffer DMA transfer request
*                       - SPI_I2S_DMAReq_Rx: Rx buffer DMA transfer request
*                  - NewState: new state of the selected SPI/I2S DMA transfer 
*                    request.
*                    This parameter can be: ENABLE or DISABLE.
* Output         : None
* Return         : None
*******************************************************************************/
void SPI_I2S_DMACmd(SPI_TypeDef* SPIx, u16 SPI_I2S_DMAReq, FunctionalState NewState)
{
  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  assert_param(IS_FUNCTIONAL_STATE(NewState));
  assert_param(IS_SPI_I2S_DMAREQ(SPI_I2S_DMAReq));

  if (NewState != DISABLE)
  {
    /* Enable the selected SPI/I2S DMA requests */
    SPIx->CR2 |= SPI_I2S_DMAReq;
  }
  else
  {
    /* Disable the selected SPI/I2S DMA requests */
    SPIx->CR2 &= (u16)~SPI_I2S_DMAReq;
  }
}

/*******************************************************************************
* Function Name  : SPI_I2S_SendData
* Description    : Transmits a Data through the SPIx/I2Sx peripheral.
* Input          : - SPIx: where x can be :
*                         - 1, 2 or 3 in SPI mode 
*                         - 2 or 3 in I2S mode
*                  - Data : Data to be transmitted..
* Output         : None
* Return         : None
*******************************************************************************/
void SPI_I2S_SendData(SPI_TypeDef* SPIx, u16 Data)
{
  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  
  /* Write in the DR register the data to be sent */
  SPIx->DR = Data;
}

/*******************************************************************************
* Function Name  : SPI_I2S_ReceiveData
* Description    : Returns the most recent received data by the SPIx/I2Sx peripheral. 
* Input          : - SPIx: where x can be :
*                         - 1, 2 or 3 in SPI mode 
*                         - 2 or 3 in I2S mode
* Output         : None
* Return         : The value of the received data.
*******************************************************************************/
u16 SPI_I2S_ReceiveData(SPI_TypeDef* SPIx)
{
  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  
  /* Return the data in the DR register */
  return SPIx->DR;
}

/*******************************************************************************
* Function Name  : SPI_NSSInternalSoftwareConfig
* Description    : Configures internally by software the NSS pin for the selected 
*                  SPI.
* Input          : - SPIx: where x can be 1, 2 or 3 to select the SPI peripheral.
*                  - SPI_NSSInternalSoft: specifies the SPI NSS internal state.
*                    This parameter can be one of the following values:
*                       - SPI_NSSInternalSoft_Set: Set NSS pin internally
*                       - SPI_NSSInternalSoft_Reset: Reset NSS pin internally
* Output         : None
* Return         : None
*******************************************************************************/
void SPI_NSSInternalSoftwareConfig(SPI_TypeDef* SPIx, u16 SPI_NSSInternalSoft)
{
  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  assert_param(IS_SPI_NSS_INTERNAL(SPI_NSSInternalSoft));

  if (SPI_NSSInternalSoft != SPI_NSSInternalSoft_Reset)
  {
    /* Set NSS pin internally by software */
    SPIx->CR1 |= SPI_NSSInternalSoft_Set;
  }
  else
  {
    /* Reset NSS pin internally by software */
    SPIx->CR1 &= SPI_NSSInternalSoft_Reset;
  }
}

/*******************************************************************************
* Function Name  : SPI_SSOutputCmd
* Description    : Enables or disables the SS output for the selected SPI.
* Input          : - SPIx: where x can be 1, 2 or 3 to select the SPI peripheral.
*                  - NewState: new state of the SPIx SS output. 
*                    This parameter can be: ENABLE or DISABLE.
* Output         : None
* Return         : None
*******************************************************************************/
void SPI_SSOutputCmd(SPI_TypeDef* SPIx, FunctionalState NewState)
{
  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  assert_param(IS_FUNCTIONAL_STATE(NewState));

  if (NewState != DISABLE)
  {
    /* Enable the selected SPI SS output */
    SPIx->CR2 |= CR2_SSOE_Set;
  }
  else
  {
    /* Disable the selected SPI SS output */
    SPIx->CR2 &= CR2_SSOE_Reset;
  }
}

/*******************************************************************************
* Function Name  : SPI_DataSizeConfig
* Description    : Configures the data size for the selected SPI.
* Input          : - SPIx: where x can be 1, 2 or 3 to select the SPI peripheral.
*                  - SPI_DataSize: specifies the SPI data size.
*                    This parameter can be one of the following values:
*                       - SPI_DataSize_16b: Set data frame format to 16bit
*                       - SPI_DataSize_8b: Set data frame format to 8bit
* Output         : None
* Return         : None
*******************************************************************************/
void SPI_DataSizeConfig(SPI_TypeDef* SPIx, u16 SPI_DataSize)
{
  /* Check the parameters */
  assert_param(IS_SPI_ALL_PERIPH(SPIx));
  assert_param(IS_SPI_DATASIZE(SPI_DataSize));

  /* Clear DFF bit */
  SPIx->CR1 &= (u16)~SPI_DataSize_16b;
  /* Set new DFF bit value */
  SPIx->CR1 |= SPI_DataSize;
}

/*******************************************************************************
* Function Name  : SPI_TransmitCRC

?? 快捷鍵說(shuō)明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號(hào) Ctrl + =
減小字號(hào) Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲午夜精品一区二区三区他趣| 久久欧美中文字幕| 卡一卡二国产精品| 欧美国产丝袜视频| 欧美欧美午夜aⅴ在线观看| 久久 天天综合| 自拍偷在线精品自拍偷无码专区| 91视频观看视频| 久久精品久久精品| 亚洲欧美日韩国产手机在线| 欧美哺乳videos| 一本色道**综合亚洲精品蜜桃冫| 亚洲男人的天堂在线aⅴ视频| 日韩欧美国产不卡| 日本二三区不卡| 免费观看在线色综合| 亚洲欧美日韩人成在线播放| 精品国偷自产国产一区| 狠狠色丁香婷综合久久| 国产精品美日韩| 日韩欧美一级二级三级| 色综合久久88色综合天天 | 欧美视频一区二区在线观看| 久久夜色精品国产噜噜av| 国产成人午夜电影网| 五月天一区二区三区| 最新中文字幕一区二区三区 | 日本乱人伦一区| 国产一区二区成人久久免费影院| 午夜精品久久久久久久久久久| 国产精品第13页| 国产精品五月天| 欧美激情一区二区三区蜜桃视频 | 91麻豆精品一区二区三区| 国产酒店精品激情| 久久精品久久综合| 美女网站色91| 日本麻豆一区二区三区视频| 日韩国产在线观看| 日本不卡视频在线| 老色鬼精品视频在线观看播放| 亚洲成人在线免费| 天天综合网天天综合色| 亚洲大片一区二区三区| 亚洲一区二区三区激情| 天堂久久一区二区三区| 三级欧美在线一区| 麻豆一区二区99久久久久| 蜜臀av性久久久久蜜臀aⅴ| 青青草91视频| 捆绑调教一区二区三区| 国产在线乱码一区二区三区| 国产伦精品一区二区三区在线观看| 精品一二三四在线| 国产精品中文字幕一区二区三区| 国产美女一区二区三区| 国产a久久麻豆| 色婷婷综合久久久中文字幕| 欧美色大人视频| 日韩一区二区三区高清免费看看| 欧美tk—视频vk| 日本一区二区在线不卡| 亚洲激情av在线| 日本麻豆一区二区三区视频| 国产一区二区精品在线观看| 成人h精品动漫一区二区三区| 91片黄在线观看| 欧美日韩精品电影| 26uuu国产一区二区三区 | 亚洲国产综合91精品麻豆| 偷拍一区二区三区四区| 国产在线不卡一卡二卡三卡四卡| 成人精品视频一区二区三区 | 日日嗨av一区二区三区四区| 国产一区二三区| 一本大道久久a久久综合婷婷| 欧美又粗又大又爽| 日韩欧美精品三级| 中文字幕一区日韩精品欧美| 性做久久久久久免费观看 | av成人老司机| 欧美一区二区久久久| 精品成人免费观看| 亚洲欧美影音先锋| 免费xxxx性欧美18vr| jvid福利写真一区二区三区| 欧美精品乱码久久久久久| 欧美一区二区福利视频| 亚洲婷婷国产精品电影人久久| 视频一区二区不卡| 99r国产精品| 日韩欧美国产午夜精品| 亚洲精品一二三| 精品一二三四在线| 欧美日韩国产中文| 国产精品少妇自拍| 蜜臀av一区二区三区| 一本色道久久综合亚洲aⅴ蜜桃| 欧美一级视频精品观看| 一区二区三区四区国产精品| 国产在线精品一区二区三区不卡 | 国产视频一区在线观看| 亚洲超碰精品一区二区| jlzzjlzz亚洲日本少妇| 久久综合色之久久综合| 亚洲国产精品嫩草影院| 99麻豆久久久国产精品免费优播| 日韩欧美激情四射| 午夜视频一区二区三区| 91在线视频观看| 国产欧美日韩另类一区| 久久精品99国产精品| 欧美日韩一区二区在线观看| 国产精品国产成人国产三级 | 亚洲乱码中文字幕综合| 国产成人免费网站| 欧美成人官网二区| 日本一不卡视频| 欧美精品色综合| 亚洲成人一二三| 在线视频国产一区| 亚洲欧美激情在线| 99精品国产热久久91蜜凸| 久久人人爽爽爽人久久久| 毛片不卡一区二区| 91精品国产一区二区人妖| 亚洲成a人在线观看| 色诱视频网站一区| 亚洲欧美激情插| 色综合天天性综合| 亚洲乱码中文字幕| 91浏览器在线视频| 亚洲黄网站在线观看| 日本高清成人免费播放| 樱桃视频在线观看一区| 欧美做爰猛烈大尺度电影无法无天| 国产精品久久久久影院色老大| 国产一区二区精品久久99| 欧美精品一区二区三区很污很色的 | 欧美日本一区二区在线观看| 亚洲一级片在线观看| 欧美综合一区二区| 亚洲国产一二三| 欧美日韩视频专区在线播放| 日日夜夜精品视频免费| 在线综合亚洲欧美在线视频| 免费成人美女在线观看| 精品99一区二区| 国产精品1区2区| 国产精品亲子伦对白| 成人精品免费视频| 一区二区三区不卡视频在线观看| 在线亚洲精品福利网址导航| 亚洲妇熟xx妇色黄| 欧美大片一区二区三区| 国产盗摄视频一区二区三区| 中文字幕在线一区二区三区| 91蜜桃免费观看视频| 日日噜噜夜夜狠狠视频欧美人 | 欧美日韩卡一卡二| 蜜桃av一区二区三区| 久久久久88色偷偷免费| 99国产欧美久久久精品| 亚洲一区二区三区四区在线观看| 91精品在线麻豆| 国产成人免费在线视频| 一区二区在线观看免费视频播放 | 亚洲色图制服诱惑| 欧美巨大另类极品videosbest| 九色综合国产一区二区三区| 国产欧美日韩在线观看| 欧美天堂亚洲电影院在线播放 | 色呦呦一区二区三区| 性久久久久久久久久久久| 久久精品亚洲一区二区三区浴池| 色香色香欲天天天影视综合网 | 91色九色蝌蚪| 美女免费视频一区| 国产精品剧情在线亚洲| 91精品一区二区三区久久久久久| 国产乱妇无码大片在线观看| 亚洲在线中文字幕| 久久久国产精品午夜一区ai换脸| 色88888久久久久久影院按摩| 狠狠色伊人亚洲综合成人| 亚洲免费观看高清完整版在线观看熊| 91精品免费在线| 不卡视频免费播放| 麻豆精品在线播放| 亚洲裸体xxx| 精品国产91久久久久久久妲己| 99久久精品国产网站| 美腿丝袜亚洲色图| 亚洲综合自拍偷拍| 国产色婷婷亚洲99精品小说| 制服丝袜中文字幕亚洲| 色婷婷精品久久二区二区蜜臂av| 国产一区二区三区观看| 天天综合日日夜夜精品| 亚洲男帅同性gay1069|