STM32F103RBT6.rar


包含STM32F103RBT6 8个基本例程(点灯 按键 TIM定时器 USART收发 读芯片ID SysTick(系统滴答定时器)ADC操作 ) 1个高级例程(基于STM32 USB 虚拟串口 采集ADC)
资源截图
代码片段和文件信息
/**
  ******************************************************************************
  * @file    fatfs_drv.c
  * @author  MCD Application Team
  * @version V1.2.0
  * @date    11-April-2014
  * @brief   diskio interface
  ******************************************************************************
  * @attention
  *
  * 

© COPYRIGHT 2014 STMicroelectronics


  *
  * Licensed under MCD-ST Liberty SW License Agreement V2 (the “License“);
  * You may not use this file except in compliance with the License.
  * You may obtain a copy of the License at:
  *
  *        http://www.st.com/software_license_agreement_liberty_v2
  *
  * Unless required by applicable law or agreed to in writing software 
  * distributed under the License is distributed on an “AS IS“ BASIS 
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
  *
  ******************************************************************************
  */

/* Includes ------------------------------------------------------------------*/
#include “ff.h“
#include “diskio.h“
#include “stm32_adafruit_spi_usd.h“

/* Private typedef -----------------------------------------------------------*/
/* Private define ------------------------------------------------------------*/
#define BLOCK_SIZE 512 /* Block Size in Bytes */

/* Private macro -------------------------------------------------------------*/
/* Private variables ---------------------------------------------------------*/
static volatile DSTATUS Stat = STA_NOINIT; /* Disk status */

/* Private function prototypes -----------------------------------------------*/
/* Private functions ---------------------------------------------------------*/

/**
  * @brief  Initializes a Disk
  * @param  pdrv: Physical drive number
  * @retval DSTATUS: Operation status
  */
DSTATUS disk_initialize(BYTE pdrv)
{
  Stat = STA_NOINIT;
  
  if (pdrv == 0)
  {
    if (SD_ADAFRUIT_Init() == SD_RESPONSE_NO_ERROR)
    {
      Stat &= ~STA_NOINIT;
    }
  }
  
  return Stat;
}

/**
  * @brief  Gets Disk Status
  * @param  pdrv: Physical drive number
  * @retval DSTATUS: Operation status
  */
DSTATUS disk_status (BYTE pdrv)
{
  if (pdrv == 0) /* Supports only single drive */
  {
    Stat = STA_NOINIT;
    
    if(SD_GetStatus() == 0xFF)
    {
      Stat &= ~STA_NOINIT;
    }
  }
  
  return Stat;
}

/**
  * @brief  Reads Sector
  * @param  pdrv: Physical drive number
  * @param  *buff: Data buffer to store read data
  * @param  sector: Sector address (LBA)
  * @param  count: Number of sectors to read
  * @retval DRESULT: Operation result
  */
DRESULT disk_read (BYTE pdrv BYTE*buff DWORD sector UINT count)
{
  if (pdrv == 0)
  {
    if(SD_GetStatus() != 0xFF)
    {
      return(RES_NOTRDY);
    }
    
    SD_ReadB

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件     764996  2020-04-30 19:10  基本例程-按键(查询方式).zip

     文件     795438  2020-04-30 19:10  基本例程-按键(中断方式).zip

     文件     905140  2020-04-30 19:10  基本例程-TIM定时器操作.zip

     文件     704884  2020-04-30 19:10  基本例程-USART收发.zip

     文件     682717  2020-04-30 19:09  基本例程—SysTick(系统滴答定时器)操作.zip

     文件     995076  2020-04-30 19:09  基本例程-ADC操作.zip

     文件     631653  2020-04-30 19:09  基本例程-I0操作_LED流水灯.zip

     文件    3997866  2020-04-30 19:09  高级例程-基于STM32 USB 虚拟串口 采集ADC.zip

     文件     810501  2020-04-30 19:09  基本例程-读芯片ID.zip

     文件       2066  2014-04-16 21:58  NUCLEO-F103RBDemonstrationBinary
eadme.txt

     文件      54411  2014-04-16 21:58  NUCLEO-F103RBDemonstrationBinarySTM32F103_Nucleo_Demo.hex

     文件       1344  2014-04-16 21:58  NUCLEO-F103RBDemonstrationEWARMstm32f103xx_flash.icf

     文件      36889  2014-04-16 21:58  NUCLEO-F103RBDemonstrationEWARMSTM32F103_Nucleo_Demo.ewd

     文件      30640  2014-04-16 21:58  NUCLEO-F103RBDemonstrationEWARMSTM32F103_Nucleo_Demo.ewp

     文件        175  2014-04-16 21:58  NUCLEO-F103RBDemonstrationEWARMSTM32F103_Nucleo_Demo.eww

     文件       5756  2014-04-16 21:58  NUCLEO-F103RBDemonstrationfatfs_drv.c

     文件       7350  2014-04-16 21:58  NUCLEO-F103RBDemonstrationfatfs_storage.c

     文件       2454  2014-04-16 21:58  NUCLEO-F103RBDemonstrationfatfs_storage.h

     文件       8688  2014-04-16 21:58  NUCLEO-F103RBDemonstrationffconf.h

     文件      17960  2014-04-16 21:58  NUCLEO-F103RBDemonstrationmain.c

     文件       2014  2014-04-16 21:58  NUCLEO-F103RBDemonstrationmain.h

     文件      25977  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMDK-ARMSTM32F103_Nucleo_Demo.uvopt

     文件      23141  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMDK-ARMSTM32F103_Nucleo_Demo.uvproj

     文件      41026  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMedia10_16.bmp

     文件      41026  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMedia12_16.bmp

     文件      41026  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMedia1_16.bmp

     文件      41026  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMedia2_16.bmp

     文件      41026  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMedia3_16.bmp

     文件      41026  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMedia4_16.bmp

     文件      41026  2014-04-16 21:58  NUCLEO-F103RBDemonstrationMedia5_16.bmp

............此处省略590个文件信息

版权声明:本文内容由互联网用户自发贡献,该文观点仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容, 请发送邮件举报,一经查实,本站将立刻删除。

发表评论

评论列表(条)