FM6124-QG Ramtron, FM6124-QG Datasheet - Page 46

FRAM, 24KB, EVENT DATA REC, QFP44

FM6124-QG

Manufacturer Part Number
FM6124-QG
Description
FRAM, 24KB, EVENT DATA REC, QFP44
Manufacturer
Ramtron
Datasheet

Specifications of FM6124-QG

Memory Size
24KB
Nvram Features
RTC
Supply Voltage Range
3V To 3.6V
Memory Case Style
QFP
No. Of Pins
44
Operating Temperature Range
-40°C To +85°C
Package / Case
QFP
Interface
I2C
Memory
RoHS Compliant
Interface Type
I2C, Serial, 2-Wire
Rohs Compliant
Yes
Access Time
100 KBPs
Operating Supply Voltage
3 V to 3.6 V
Mounting Style
SMD/SMT
Lead Free Status / Rohs Status
 Details

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
FM6124-QG
Manufacturer:
ABOV
Quantity:
3 000
////////////////////////////////////////////////////////////////////////////////
// Function:
// Description:
// Parameters:
//
// Return value:
// Remarks:
////////////////////////////////////////////////////////////////////////////////
rbool
FM6124ReadEventAtRP(struct SEvent *a_poEvent)
{
}
Rev. 4.0 (EOL)
July 2010
// First, we need to indicate the FM6124 that we want to read an Event
FM6124WriteReg(EDR_REG_BUFFER_CTRL, EDR_BC_CMD_GET);
// Make sure I2C is Idle
while(!(I2CSTATUS & 0x08));
// Wait for TX Buffer to be empty
while((I2CSTATUS & 0x01) == 0);
// Dummy Read, to clear the I2CRxAv flag.
a_poEvent->uiEventCode = I2CRXTX;
// "Fake" write operation to send the register address we want to read
I2CRXTX = I2C_ID_EDR | g_uiI2CDevSelect | IC2_WRITE;
// Wait for TX Buffer to be empty
while((I2CSTATUS & 0x01) == 0);
// Make sure we received an ACK and that there was no error during transfer
if (I2CSTATUS & 0xC0)
{
}
// Send Read Address
I2CRXTX = EDR_REG_EVT_CODE;
// Wait for I2C to be Idle and generate a STOP
while(!(I2CSTATUS & 0x08));
// Make sure we received an ACK and that there was no error during transfer
if (I2CSTATUS & 0xC0)
{
}
// READ EVENT
// Dummy Read to clear the I2CRXAVF
a_poEvent->uiEventCode = I2CRXTX;
// Make sure we will ACK the Data we will receive
I2CCONFIG &= 0xFD;
// Now, send the Read command to the Slave ER
I2CRXTX = I2C_ID_EDR | g_uiI2CDevSelect | IC2_READ;
while(!(I2CSTATUS & 0x02));
a_poEvent->uiEventCode
while(!(I2CSTATUS & 0x02));
a_poEvent->oBCDDate.uiSeconds
while(!(I2CSTATUS & 0x02));
a_poEvent->oBCDDate.uiMinutes
while(!(I2CSTATUS & 0x02));
a_poEvent->oBCDDate.uiHours
while(!(I2CSTATUS & 0x02));
a_poEvent->oBCDDate.uiDay
while(!(I2CSTATUS & 0x02));
a_poEvent->oBCDDate.uiDate
while(!(I2CSTATUS & 0x02));
a_poEvent->oBCDDate.uiMonth
while(!(I2CSTATUS & 0x02));
a_poEvent->oBCDDate.uiYear
// Stop the transaction
I2CCONFIG |= 0x02;
// Wait for I2C to be Idle and generate a STOP
while(!(I2CSTATUS & 0x08));
return RTRUE;
return RFALSE;
return RFALSE;
FM6124ReadEventAtRP
Read Event pointed by the current position of RP (Read Pointer)
struct SEvent *a_poEvent: Pointer to a SEvent, which
will receive the Event's values.
rbool: RTRUE = Read Ok.
None
= I2CRXTX;
= I2CRXTX;
= I2CRXTX;
= I2CRXTX;
= I2CRXTX;
= I2CRXTX;
= I2CRXTX;
= I2CRXTX;
Page 46 of 53

Related parts for FM6124-QG