C8051xxx Examples.rar


Silicon C8051系列 官方例程源码,需要的可以下载,不方便下载可私聊。
资源截图
代码片段和文件信息
//-----------------------------------------------------------------------------
// F00x_ADC0_ExternalInput.c
//-----------------------------------------------------------------------------
// Copyright 2006 Silicon Laboratories Inc.
// http://www.silabs.com
//
// Program Description:
//
// This program measures the voltage on an external ADC input and prints the
// result to a terminal window via the UART.
//
// The system is clocked using an external 22.1184 MHz crystal oscillator.
// Results are printed to the UART from a loop with the rate set by a delay
// based on Timer 2.  This loop periodically reads the ADC value from a
// global variable Result.
//
// The ADC makes repeated measurements at a rate determined by SAMPLE_RATE using
// Timer 3.  The end of each ADC conversion initiates an interrupt which calls an
// averaging function.   samples are averaged then the Result value updated.
//
// For each power of 4 of  you gain 1 bit of effective resolution.
// For example  = 256 gain you 4 bits of resolution: 4^4 = 256.
//
// The ADC input multiplexer is set for a single-ended input at AIN0.  The input
// amplifier is set for unity gain so a voltage range of 0 to Vref (2.43V) may
// be measured.  Although voltages up to Vdd may be applied without damaging the
// device only the range 0 to Vref may be measured by the ADC.
// The input is available at the 8-position board-edge connector J20 on the
// C8051F005-TB.
//
// A 100kohm potentiometer may be connected as a voltage divider between
// VREF and AGND as shown below:
//
// ---------
//          |
//       8 o| AGND ----|
//         o| VREF ----|<-|
//         o| AIN0     |  |
//         o|    |        |
//         o|     --------
//         o|
//         o|
//       1 o|
//          |
//----------
//
// How To Test:
//
// 1) Download code to a ‘F005 device that is connected to a UART transceiver
// 2) Connect serial cable from the transceiver to a PC
// 3) On the PC open HyperTerminal (or any other terminal program) and connect
//    to the COM port at  and 8-N-1
// 4) Connect a variable voltage source (between 0 and Vref)
//    to AIN0 or a potentiometer voltage divider as shown above.
// 5) HyperTerminal will print the voltage measured by the device if
//    everything is working properly
//
// Target:         C8051F005
// Tool chain:     Keil C51 7.50 / Keil EVAL C51
// Command Line:   None
//
//
// Release 1.0
//    -Initial Revision (PD)
//    -27-Jul-06
//
//-----------------------------------------------------------------------------
// Includes
//-----------------------------------------------------------------------------

#include                  // SFR declarations
#include 

//-----------------------------------------------------------------------------
// 16-bit SFR Definitions for ‘F00x
//-----------------------------------------------

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

     文件      15026  2013-07-29 10:32  ExamplesC8051F00x_01xADCF00x_ADC0_ExternalInput.c

     文件      20303  2013-07-29 10:32  ExamplesC8051F00x_01xADCF00x_ADC0_ExternalInput_Mux.c

     文件       9971  2013-07-29 10:32  ExamplesC8051F00x_01xADCF00x_ADC0_TempSensor.asm

     文件      14646  2013-07-29 10:34  ExamplesC8051F00x_01xlinkyc8051F000.h

     文件       9646  2013-07-29 10:34  ExamplesC8051F00x_01xlinkyC8051F000.INC

     文件      16144  2013-07-29 10:34  ExamplesC8051F00x_01xlinkyc8051F000_defs.h

     文件       2713  2013-07-29 10:32  ExamplesC8051F00x_01xlinkyF00x_blinky.asm

     文件       2884  2013-07-29 10:32  ExamplesC8051F00x_01xlinkyF00x_blinky.c

     文件      32127  2013-07-29 10:32  ExamplesC8051F00x_01xlinkyF00x_blinky_Asm.wsp

     文件      32121  2013-07-29 10:32  ExamplesC8051F00x_01xlinkyF00x_blinky_C.wsp

     文件       8235  2013-07-29 10:32  ExamplesC8051F00x_01xComparatorsF00x_Comparator0_ResetSource.c

     文件      12438  2013-07-29 10:32  ExamplesC8051F00x_01xDACF0xx_DACs_SineCosine.c

     文件      14646  2013-07-29 10:34  ExamplesC8051F00x_01xHeader_Filesc8051F000.h

     文件       9646  2013-07-29 10:34  ExamplesC8051F00x_01xHeader_FilesC8051F000.INC

     文件      16144  2013-07-29 10:34  ExamplesC8051F00x_01xHeader_Filesc8051F000_defs.h

     文件       6691  2013-07-29 10:32  ExamplesC8051F00x_01xInterruptsF00x_External_Interrupts.c

     文件      11149  2013-07-29 10:32  ExamplesC8051F00x_01xOscillatorsF0xx_Oscillator_Capacitor.c

     文件       8715  2013-07-29 10:32  ExamplesC8051F00x_01xOscillatorsF0xx_Oscillator_CMOS.c

     文件       9517  2013-07-29 10:32  ExamplesC8051F00x_01xOscillatorsF0xx_Oscillator_Crystal.c

     文件      10587  2013-07-29 10:32  ExamplesC8051F00x_01xOscillatorsF0xx_Oscillator_RC.c

     文件       8628  2013-07-29 10:32  ExamplesC8051F00x_01xPCAF00x_PCA0_8Bit_PWM_Output.c

     文件      11472  2013-07-29 10:32  ExamplesC8051F00x_01xPCAF00x_PCA0_Capture_Input.c

     文件       9864  2013-07-29 10:32  ExamplesC8051F00x_01xPCAF0xx_PCA0_High_Speed_Output.c

     文件      10558  2013-07-29 10:32  ExamplesC8051F00x_01xPCAF0xx_PCA0_Software_Timer_blinky.c

     文件       5313  2013-07-29 10:32  ExamplesC8051F00x_01xPortIOF00x_Ports_SwitchLED.c

     文件      32267  2013-07-29 10:32  ExamplesC8051F00x_01xSMBusF0xx_SMBus_EEPROM.c

     文件      20129  2013-07-29 10:32  ExamplesC8051F00x_01xSMBusF0xx_SMBus_Master.c

     文件      22306  2013-07-29 10:32  ExamplesC8051F00x_01xSMBusF0xx_SMBus_Master_Multibyte.c

     文件      27288  2013-07-29 10:32  ExamplesC8051F00x_01xSMBusF0xx_SMBus_Multimaster.c

     文件      13627  2013-07-29 10:32  ExamplesC8051F00x_01xSMBusF0xx_SMBus_Slave.c

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

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

发表评论

评论列表(条)