C# 클래스 Controller.DS1307

This class implements a complete driver for the Dallas Semiconductors / Maxim DS1307 I2C real-time clock: http://pdfserv.maxim-ic.com/en/ds/DS1307.pdf
상속: IDisposable
파일 보기 프로젝트 열기: h07r0d/Netduino-Aquarium-Controller

공개 메소드들

메소드 설명
DS1307 ( ) : System
DS1307 ( Microsoft.SPOT.Hardware.I2CDevice device ) : System
Dispose ( ) : void

Releases clock resources

GetRAM ( ) : byte[]

Reads the clock's user RAM registers as a block.

ReadRegister ( byte address, int length = 1 ) : byte[]

Reads an arbitrary RTC or RAM register

SetRAM ( byte buffer ) : void

Writes to the clock's user RAM registers as a block

SetSquareWave ( SQWFreq Freq, SQWDisabledOutputControl OutCtrl = SQWDisabledOutputControl.Zero ) : void

Enables / Disables the square wave generation function of the clock. Requires a pull-up resistor on the clock's SQW pin.

WriteRegister ( byte address, byte data ) : void

Writes an arbitrary RTC or RAM register

this ( byte address ) : byte

비공개 메소드들

메소드 설명
EncodeDate ( System.DateTime value, bool clockHalt, bool hourMode ) : byte[]
ParseDate ( byte clockData ) : System.DateTime

메소드 상세

DS1307() 공개 메소드

public DS1307 ( ) : System
리턴 System

DS1307() 공개 메소드

public DS1307 ( Microsoft.SPOT.Hardware.I2CDevice device ) : System
device Microsoft.SPOT.Hardware.I2CDevice
리턴 System

Dispose() 공개 메소드

Releases clock resources
public Dispose ( ) : void
리턴 void

GetRAM() 공개 메소드

Reads the clock's user RAM registers as a block.
public GetRAM ( ) : byte[]
리턴 byte[]

ReadRegister() 공개 메소드

Reads an arbitrary RTC or RAM register
public ReadRegister ( byte address, int length = 1 ) : byte[]
address byte Register address between 0x00 and 0x3f
length int The number of bytes to read
리턴 byte[]

SetRAM() 공개 메소드

Writes to the clock's user RAM registers as a block
public SetRAM ( byte buffer ) : void
buffer byte A byte buffer of size DS1307_RAM_SIZE
리턴 void

SetSquareWave() 공개 메소드

Enables / Disables the square wave generation function of the clock. Requires a pull-up resistor on the clock's SQW pin.
public SetSquareWave ( SQWFreq Freq, SQWDisabledOutputControl OutCtrl = SQWDisabledOutputControl.Zero ) : void
Freq SQWFreq Desired frequency or disabled
OutCtrl SQWDisabledOutputControl Logical level of output pin when the frequency is disabled (zero by default)
리턴 void

WriteRegister() 공개 메소드

Writes an arbitrary RTC or RAM register
public WriteRegister ( byte address, byte data ) : void
address byte Register address between 0x00 and 0x3f
data byte
리턴 void

this() 공개 메소드

public this ( byte address ) : byte
address byte
리턴 byte