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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? bits_drivemosfet.c

?? 基于56F8346的異步電機(jī)VVVF控制程序。
?? C
字號:
/** ###################################################################
**     THIS BEAN MODULE IS GENERATED BY THE TOOL. DO NOT MODIFY IT.
**     Filename  : Bits_Drivemosfet.C
**     Project   : vvvf_56F8346
**     Processor : 56F8346
**     Beantype  : BitsIO
**     Version   : Bean 02.091, Driver 01.15, CPU db: 2.87.097
**     Compiler  : Metrowerks DSP C Compiler
**     Date/Time : 2008-3-7, 9:38
**     Abstract  :
**         This bean "BitsIO" implements a multi-bit input/output.
**         It uses selected pins of one 1-bit to 8-bit port.
**     Settings  :
**         Port name                   : GPIOE_High
**
**         Bit mask of the port        : 3072
**         Number of bits/pins         : 2
**         Single bit numbers          : 0 to 1
**         Values range                : 0 to 3
**
**         Initial direction           : Output (direction can be changed)
**         Safe mode                   : yes
**         Initial output value        : 0 = 000H
**         Initial pull option         : off
**
**         Port data register          : GPIO_E_DR [62257]
**         Port control register       : GPIO_E_DDR [62258]
**         Port function register      : GPIO_E_PER [62259]
**
**             ----------------------------------------------------
**                   Bit     |   Pin   |   Name
**             ----------------------------------------------------
**                    0      |    116  |   GPIOE10_TD0
**                    1      |    117  |   GPIOE11_TD1
**             ----------------------------------------------------
**
**         Optimization for            : speed
**     Contents  :
**         GetDir - bool Bits_Drivemosfet_GetDir(void);
**         SetDir - void Bits_Drivemosfet_SetDir(bool Dir);
**         GetVal - byte Bits_Drivemosfet_GetVal(void);
**         PutVal - void Bits_Drivemosfet_PutVal(byte Val);
**         GetBit - bool Bits_Drivemosfet_GetBit(byte Bit);
**         PutBit - void Bits_Drivemosfet_PutBit(byte Bit,bool Val);
**         SetBit - void Bits_Drivemosfet_SetBit(byte Bit);
**         ClrBit - void Bits_Drivemosfet_ClrBit(byte Bit);
**         NegBit - void Bits_Drivemosfet_NegBit(byte Bit);
**
**     (c) Copyright UNIS, spol. s r.o. 1997-2005
**     UNIS, spol. s r.o.
**     Jundrovska 33
**     624 00 Brno
**     Czech Republic
**     http      : www.processorexpert.com
**     mail      : info@processorexpert.com
** ###################################################################*/

/* MODULE Bits_Drivemosfet. */

#include "Bits_Drivemosfet.h"

/*Include shared modules, which are used for whole project*/
#include "PE_Types.h"
#include "PE_Error.h"
#include "PE_Const.h"
#include "IO_Map.h"

#include "Cpu.h"


static const word Bits_Drivemosfet_Table[2]={ 
1024,2048};                                     /* Table of mask constants */
/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_GetMsk (bean BitsIO)
**
**     Description :
**         Returns pin mask. The method is called automatically as a part 
**         of bit method.
**         This method is internal. It is used by Processor Expert only.
** ===================================================================
*/
static word Bits_Drivemosfet_GetMsk(byte Value)
{
  return((Value<2)?Bits_Drivemosfet_Table[Value]:(word)0); /* Return appropriate bit mask */
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_GetVal (bean BitsIO)
**
**     Description :
**         This method returns an input value.
**           a) direction = Input  : reads the input value from the
**                                   pins and returns it
**           b) direction = Output : returns the last written value
**     Parameters  : None
**     Returns     :
**         ---        - Input value (0 to 3)
** ===================================================================
*/
/*
byte Bits_Drivemosfet_GetVal(void)

**  This method is implemented as a macro. See Bits_Drivemosfet.h file.  **
*/

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_PutVal (bean BitsIO)
**
**     Description :
**         This method writes the new output value.
**           a) direction = Input  : sets the new output value;
**                                   this operation will be shown on
**                                   output after the direction has
**                                   been switched to output
**                                   (SetDir(TRUE);)
**           b) direction = Output : directly writes the value to the
**                                   appropriate pins
**     Parameters  :
**         NAME       - DESCRIPTION
**         Val        - Output value (0 to 3)
**     Returns     : Nothing
** ===================================================================
*/
void Bits_Drivemosfet_PutVal(byte Val)
{
  register word Temp;                  /* Temporary variable */

  Temp = (((word)Val)<<10) & Bits_Drivemosfet_PIN_MASK; /* Prepare value for output */
  Shadow_GPIO_E_DR = Shadow_GPIO_E_DR & ~Bits_Drivemosfet_PIN_MASK | Temp; /* Set-up bits in shadow variable */
  setReg(GPIO_E_DR,(getReg(GPIO_E_DR)) & ~Bits_Drivemosfet_PIN_MASK | Temp); /* Set-up bits on port */
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_GetBit (bean BitsIO)
**
**     Description :
**         This method returns the specified bit of the input value.
**           a) direction = Input  : reads the input value from pins
**                                   and returns the specified bit
**           b) direction = Output : returns the specified bit
**                                   of the last written value
**     Parameters  :
**         NAME       - DESCRIPTION
**         Bit        - Number of the bit to read (0 to 1)
**     Returns     :
**         ---        - Value of the specified bit (FALSE or TRUE)
**                      FALSE = "0" or "Low", TRUE = "1" or "High"
** ===================================================================
*/
bool Bits_Drivemosfet_GetBit(byte Bit)
{
  register word Mask=Bits_Drivemosfet_GetMsk(Bit); /* Temporary variable - bit mask */

  return((bool)((Mask)?((getReg(GPIO_E_DR)) & Mask) == Mask:(bool)0)); /* Return input value */
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_PutBit (bean BitsIO)
**
**     Description :
**         This method writes the new value to the specified bit
**         of the output value.
**           a) direction = Input  : sets the value of the specified
**                                   bit; this operation will be
**                                   shown on output after the
**                                   direction has been switched to
**                                   output (SetDir(TRUE);)
**           b) direction = Output : directly writes the value of the
**                                   bit to the appropriate pin
**     Parameters  :
**         NAME       - DESCRIPTION
**         Bit        - Number of the bit (0 to 1)
**         Val        - New value of the bit (FALSE or TRUE)
**                      FALSE = "0" or "Low", TRUE = "1" or "High"
**     Returns     : Nothing
** ===================================================================
*/
void Bits_Drivemosfet_PutBit(byte Bit, bool Val)
{
  register word Mask=Bits_Drivemosfet_GetMsk(Bit); /* Temporary variable - bit mask */

  if (Mask)                            /* Is bit mask correct? */
    if (Val) {                         /* Is it one to be written? */
      Shadow_GPIO_E_DR |= Mask;        /* Set appropriate bit in shadow variable */
      setRegBits(GPIO_E_DR,Mask);      /* Set appropriate bit on port */
    }
    else {                             /* Is it zero to be written? */
      Shadow_GPIO_E_DR &= ~Mask;       /* Clear appropriate bit in shadow variable */
      clrRegBits(GPIO_E_DR,Mask);      /* Clear appropriate bit on port */
    }
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_SetBit (bean BitsIO)
**
**     Description :
**         This method sets (sets to one) the specified bit of the
**         output value.
**         [ It is the same as "PutBit(Bit,TRUE);" ]
**           a) direction = Input  : sets the specified bit to "1";
**                                   this operation will be shown on
**                                   output after the direction has
**                                   been switched to output
**                                   (SetDir(TRUE);)
**           b) direction = Output : directly writes "1" to the
**                                   appropriate pin
**     Parameters  :
**         NAME       - DESCRIPTION
**         Bit        - Number of the bit to set (0 to 1)
**     Returns     : Nothing
** ===================================================================
*/
void Bits_Drivemosfet_SetBit(byte Bit)
{
  register word Mask=Bits_Drivemosfet_GetMsk(Bit); /* Temporary variable - bit mask */

  if (Mask) {                          /* Is bit mask correct? */
    Shadow_GPIO_E_DR |= Mask;          /* Set appropriate bit in shadow variable */
    setRegBits(GPIO_E_DR,Mask);        /* Set appropriate bit on port */
  }
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_ClrBit (bean BitsIO)
**
**     Description :
**         This method clears (sets to zero) the specified bit
**         of the output value.
**         [ It is the same as "PutBit(Bit,FALSE);" ]
**           a) direction = Input  : sets the specified bit to "0";
**                                   this operation will be shown on
**                                   output after the direction has
**                                   beenswitched to output
**                                   (SetDir(TRUE);)
**           b) direction = Output : directly writes "0" to the
**                                   appropriate pin
**     Parameters  :
**         NAME       - DESCRIPTION
**         Bit        - Number of the bit to clear (0 to 1)
**     Returns     : Nothing
** ===================================================================
*/
void Bits_Drivemosfet_ClrBit(byte Bit)
{
  register word Mask=Bits_Drivemosfet_GetMsk(Bit); /* Temporary variable - bit mask */

  if (Mask) {                          /* Is bit mask correct? */
    Shadow_GPIO_E_DR &= ~Mask;         /* Clear appropriate bit in shadow variable */
    clrRegBits(GPIO_E_DR,Mask);        /* Clear appropriate bit on port */
  }
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_NegBit (bean BitsIO)
**
**     Description :
**         This method negates (inverts) the specified bit of the
**         output value.
**           a) direction = Input  : inverts the specified bit;
**                                   this operation will be shown on
**                                   output after the direction has
**                                   been switched to output
**                                   (SetDir(TRUE);)
**           b) direction = Output : directly inverts the value
**                                   of the appropriate pin
**     Parameters  :
**         NAME       - DESCRIPTION
**         Bit        - Number of the bit to invert (0 to 31)
**     Returns     : Nothing
** ===================================================================
*/
void Bits_Drivemosfet_NegBit(byte Bit)
{
  register word Mask=Bits_Drivemosfet_GetMsk(Bit); /* Temporary variable - bit mask */

  if (Mask) {                          /* Is bit mask correct? */
    Shadow_GPIO_E_DR ^= Mask;          /* Negate appropriate bit in shadow variable */
    changeRegBits(GPIO_E_DR,Mask);     /* Negate appropriate bit on port */
  }
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_SetDir (bean BitsIO)
**
**     Description :
**         This method sets direction of the bean.
**     Parameters  :
**         NAME       - DESCRIPTION
**         Dir        - Direction to set (FALSE or TRUE)
**                      FALSE = Input, TRUE = Output
**     Returns     : Nothing
** ===================================================================
*/
void Bits_Drivemosfet_SetDir(bool Dir)
{
  if (Dir) {                           /* Is given direction output? */
    setReg(GPIO_E_DR,((getReg(GPIO_E_DR)) & ~Bits_Drivemosfet_PIN_MASK)|(Shadow_GPIO_E_DR & Bits_Drivemosfet_PIN_MASK)); /* Restore correct value of output from shadow variable */
    setRegBits(GPIO_E_DDR,Bits_Drivemosfet_PIN_MASK); /* Set direction to output */
  }
  else {                               /* Is direction input? */
    clrRegBits(GPIO_E_DDR,Bits_Drivemosfet_PIN_MASK); /* Set direction to input */
  }
}

/*
** ===================================================================
**     Method      :  Bits_Drivemosfet_GetDir (bean BitsIO)
**
**     Description :
**         This method returns direction of the bean.
**     Parameters  : None
**     Returns     :
**         ---        - Direction of the bean (FALSE or TRUE)
**                      FALSE = Input, TRUE = Output
** ===================================================================
*/
/*
bool Bits_Drivemosfet_GetDir(void)

**  This method is implemented as a macro. See Bits_Drivemosfet.h file.  **
*/

/* END Bits_Drivemosfet. */

/*
** ###################################################################
**
**     This file was created by UNIS Processor Expert 2.97 [03.74]
**     for the Freescale 56800 series of microcontrollers.
**
** ###################################################################
*/

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品99999| 69久久夜色精品国产69蝌蚪网| 成人晚上爱看视频| 亚洲一区二区视频在线观看| 国产日韩欧美高清在线| 欧美久久久久免费| 99精品视频一区| 国产在线不卡视频| 人人精品人人爱| 亚洲制服丝袜av| 中文字幕一区二区日韩精品绯色 | 在线中文字幕一区| 国产美女久久久久| 美国三级日本三级久久99 | 国产盗摄一区二区三区| 日韩av不卡一区二区| 亚洲视频狠狠干| 亚洲国产高清不卡| 精品电影一区二区| 国产亲近乱来精品视频| 91精品久久久久久久91蜜桃| 日本高清不卡aⅴ免费网站| 成人小视频免费观看| 国产一区二区三区日韩 | 91麻豆免费视频| 国产不卡视频一区| 国产伦精一区二区三区| 久久99蜜桃精品| 麻豆精品一二三| 老司机免费视频一区二区| 日本va欧美va瓶| 日韩不卡手机在线v区| 午夜av电影一区| 日韩高清在线不卡| 美女网站色91| 国产在线不卡一区| 成人性生交大片免费看在线播放 | 久久久久久毛片| 日韩精品一区二区三区中文不卡| 91精品国产乱| 欧美本精品男人aⅴ天堂| 51午夜精品国产| 欧美成人午夜电影| 2021久久国产精品不只是精品| 精品国产污污免费网站入口 | 久久亚洲一级片| 久久久九九九九| 国产视频一区二区在线观看| 国产网站一区二区三区| 国产精品午夜电影| 日韩理论片网站| 亚洲3atv精品一区二区三区| 日韩av成人高清| 国产经典欧美精品| 成人永久aaa| 欧洲精品一区二区| 6080午夜不卡| 久久九九99视频| 国产精品久久久久精k8| 一区二区三区免费网站| 日韩在线卡一卡二| 国产呦萝稀缺另类资源| 99精品桃花视频在线观看| 欧美影院一区二区三区| 欧美成人video| 国产精品你懂的在线欣赏| 亚洲韩国一区二区三区| 久久国产成人午夜av影院| 成人午夜激情在线| 欧美日韩另类一区| 精品国产一区二区精华 | 寂寞少妇一区二区三区| 成人a级免费电影| 欧美午夜精品久久久久久超碰| 日韩一区二区免费在线电影| 国产偷v国产偷v亚洲高清| 亚洲美女屁股眼交| 蜜臀av性久久久久蜜臀aⅴ流畅 | 久久99久久精品欧美| 91精品综合久久久久久| 久久理论电影网| 亚洲午夜视频在线| 国产一区二区三区黄视频| 91麻豆精品在线观看| 精品国产sm最大网站| 亚洲免费观看高清完整| 国产在线乱码一区二区三区| 91麻豆视频网站| 国产亚洲精久久久久久| 图片区日韩欧美亚洲| 成人午夜精品在线| 欧美成人艳星乳罩| 亚洲地区一二三色| 成人国产精品视频| 欧美大片拔萝卜| 亚洲成人免费视频| 成人白浆超碰人人人人| 欧美tickling网站挠脚心| 亚洲狠狠丁香婷婷综合久久久| 国内不卡的二区三区中文字幕| 欧洲另类一二三四区| 国产欧美日韩在线看| 另类小说色综合网站| 欧美日韩一区二区欧美激情| 国产精品女同互慰在线看| 久久国产婷婷国产香蕉| 欧美吞精做爰啪啪高潮| 中文字幕色av一区二区三区| 国产制服丝袜一区| 精品毛片乱码1区2区3区| 亚洲第一激情av| 欧美少妇xxx| 一区二区三区四区精品在线视频| 国产成人精品免费一区二区| 欧美电影免费观看完整版| 亚洲午夜免费电影| 欧美亚日韩国产aⅴ精品中极品| 日本一区二区不卡视频| 国产乱码精品一区二区三区五月婷| 在线综合亚洲欧美在线视频 | 国产传媒一区在线| 日韩欧美亚洲国产精品字幕久久久| 午夜影院在线观看欧美| 欧美色网站导航| 亚洲风情在线资源站| 91久久精品一区二区三区| 亚洲欧洲综合另类| 色婷婷一区二区三区四区| 亚洲色图自拍偷拍美腿丝袜制服诱惑麻豆| 成人小视频在线| 国产精品你懂的| av在线综合网| 亚洲图片你懂的| 日本乱人伦aⅴ精品| 亚洲综合区在线| 欧美日韩在线直播| 亚洲成人在线观看视频| 欧美精品在线视频| 日本中文字幕不卡| 欧美mv日韩mv亚洲| 国产69精品久久久久毛片| 国产精品久久综合| 色狠狠综合天天综合综合| 一级精品视频在线观看宜春院 | eeuss鲁片一区二区三区在线看| 国产精品无人区| 91在线观看免费视频| 一区二区三区免费在线观看| 欧美日韩国产综合一区二区 | 91蝌蚪porny九色| 亚洲精品成人a在线观看| 欧美三级蜜桃2在线观看| 日本午夜精品一区二区三区电影| 91精品国产手机| 国产精品中文字幕欧美| 国产精品免费aⅴ片在线观看| 91蜜桃婷婷狠狠久久综合9色| 一区二区三区免费看视频| 日韩一区二区视频| 国产98色在线|日韩| 亚洲欧美另类小说视频| 3d成人动漫网站| 国产精品69毛片高清亚洲| 亚洲人成伊人成综合网小说| 欧美日韩久久一区二区| 国产在线国偷精品免费看| 亚洲人成精品久久久久| 91麻豆精品91久久久久同性| 韩国精品免费视频| 亚洲色图清纯唯美| 日韩欧美国产电影| 91在线国产福利| 久久精品久久综合| 成人欧美一区二区三区黑人麻豆| 欧美酷刑日本凌虐凌虐| 丁香六月久久综合狠狠色| 亚洲精品成人天堂一二三| 亚洲精品一区二区三区在线观看| jiyouzz国产精品久久| 日韩精品电影在线观看| 国产精品大尺度| 日韩欧美一级二级三级久久久| 成人黄色免费短视频| 日韩电影在线免费看| 国产精品久久夜| 欧美成人性战久久| 欧美亚洲日本国产| 成人在线视频一区| 久久精工是国产品牌吗| 亚洲欧洲综合另类在线| 久久久亚洲午夜电影| 欧美精品v国产精品v日韩精品| 成人av资源在线观看| 精品中文字幕一区二区小辣椒| 亚洲一区视频在线| 亚洲国产精品二十页| 日韩午夜精品电影| 欧美日韩精品一区二区| 色综合天天性综合| 国产精品1区2区3区在线观看|