TOP Contributors

  1. MIKROE (2745 codes)
  2. Alcides Ramos (371 codes)
  3. Shawon Shahryiar (307 codes)
  4. jm_palomino (118 codes)
  5. Bugz Bensce (90 codes)
  6. S P (73 codes)
  7. dany (71 codes)
  8. MikroBUS.NET Team (35 codes)
  9. NART SCHINACKOW (34 codes)
  10. Armstrong Subero (27 codes)

Most Downloaded

  1. Timer Calculator (138914 times)
  2. FAT32 Library (71500 times)
  3. Network Ethernet Library (56914 times)
  4. USB Device Library (47269 times)
  5. Network WiFi Library (42993 times)
  6. FT800 Library (42282 times)
  7. GSM click (29724 times)
  8. mikroSDK (27668 times)
  9. PID Library (26828 times)
  10. microSD click (26087 times)
Libstock prefers package manager

Package Manager

We strongly encourage users to use Package manager for sharing their code on Libstock website, because it boosts your efficiency and leaves the end user with no room for error. [more info]

< Back
mikroSDK Library

Dual EE click

Rating:

5

Author: MIKROE

Last Updated: 2019-09-23

Package Version: 1.0.0.0

mikroSDK Library: 1.0.0.0

Category: EEPROM

Downloaded: 2975 times

Not followed.

License: MIT license  

Dual EE Click contains two AT24CM02 EEPROM ICs onboard which gives total of 4MB of memory. Each memory IC can be addressed through the I2C interface with the transfer speed of 400KHz.

No Abuse Reported

Do you want to subscribe in order to receive notifications regarding "Dual EE click" changes.

Do you want to unsubscribe in order to stop receiving notifications regarding "Dual EE click" changes.

Do you want to report abuse regarding "Dual EE click".

  • mikroSDK Library 2.0.0.0
  • Comments (0)
DOWNLOAD LINK RELATED COMPILER CONTAINS
mikroBasic PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc

mikroSDK Library Blog

Dual EE click

Dual EE click

Native view of the Dual EE click board.

View full image
Dual EE click

Dual EE click

Front and back view of the Dual EE click board.

View full image

Library Description

The library includes functions to write data to memory and read data from memory.

Key functions:

  • uint8_t dualee_read(uint32_t regAddress, uint8_t *dataBuff, uint8_t nBytes) - Reading data from memory
  • uint8_t dualee_write(uint32_t regAddress, uint8_t *dataBuff, uint8_t nBytes) - Writing data to memory

Examples description

The application is composed of three sections :

  • System Initialization - Initializes I2C module
  • Application Initialization - Initializes driver init
  • Application Task - Reads your command and then execute i
  • Commands : '+' - increment current address '-' - decrement current address 'r' - read from current address 'w' - write from current address and then read it
void applicationTask()
{
    uint8_t dataReady_;
    uint16_t addressTemp;
    char receivedData_;
    char addressStr[10];

    
    if (inputDone == 1)
    {
        mikrobus_logWrite( "", _LOG_LINE);
        mikrobus_logWrite("Current page address is 0x", _LOG_TEXT);
        
        addressTemp = (pageAddress >> 16) & 0x00FF;
        IntToHex(addressTemp, addressStr);
        mikrobus_logWrite( addressStr, _LOG_TEXT);

        IntToHex(pageAddress, addressStr);
        mikrobus_logWrite( addressStr, _LOG_LINE);
        
        mikrobus_logWrite( "", _LOG_LINE);
        mikrobus_logWrite( "Enter '+' if you want to increment current address or '-' if you want to decrement current address", _LOG_LINE);
        mikrobus_logWrite( "Enter 'w' write text in current address or 'r' to read from current address:", _LOG_LINE);
        mikrobus_logWrite( "", _LOG_LINE);
        inputDone = 0;
    }

    dataReady_ = UART_Rdy_Ptr( );

    if (dataReady_ != 0)
    {
        receivedData_ = UART_Rd_Ptr( );

        switch (receivedData_)
        {
            case '+' :
            {
                if(pageAddress < _DUALEE_ADDRESS_END)
                {
                    pageAddress ++;
                }
                else
                {
                    mikrobus_logWrite( "Can't increment address, this is last address!", _LOG_LINE);
                }
                inputDone = 1;
                break;
            }
            case '-' :
            {
                if(pageAddress > _DUALEE_ADDRESS_START)
                {
                    pageAddress --;
                }
                else
                {
                    mikrobus_logWrite( "Can't decrement address, this is first address!", _LOG_LINE);
                }
                inputDone = 1;
                break;
            }
            case 'w' :
            {
                dualee_textWrite();
                inputDone = 1;
                break;
            }
            case 'r' :
            {
                dualee_textRead();
                inputDone = 1;
                break;
            }
        }
    }

    Delay_ms(1000);
}

Additional Functions :

  • void dualee_textRead() - Reads current address and logs that data to USBUART
  • void dualee_textWrite() - Writes on current address, reads that and then logs that data to USBUART

Note :

  • When you want to stop writing, you need to send '|'
  • After you read or write something you should set slight delay

Other mikroE Libraries used in the example:

  • I2C
  • Conversions

Additional notes and informations

Depending on the development board you are using, you may need USB UART clickUSB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.

ALSO FROM THIS AUTHOR

Rotary W 2 click

0

Rotary W 2 Click is a compact add-on board that allows you to add a precision input knob to your design. This board features the TLC5925, a low-power 16-channel constant-current LED sink driver from Texas Instruments that, combined with a high-quality rotary encoder from ALPS, the EC12D1564402, allows you to add a precision input knob to your design. It also features an LED ring composed of 16 individual white LEDs that can be used to represent the encoder position more visually.

[Learn More]

CAN FD click

5

CAN FD Click is a transceiver designed for HS CAN networks up to 5 Mbit/s in automotive and industrial applications. As an interface between the physical bus layer and the CAN protocol controller, the TLE9252V drives the signals to the bus and protects the microcontroller against interferences generated within the network.

[Learn More]

ISO ADC 6 click

0

ISO ADC 6 Click is a compact add-on board that contains an eight-channel isolated ADC. This board features the AD7124-8, an 8-channel, low noise, low power, 24-bit, sigma-delta ADC from Analog Devices. The ADC has a programmable gain array (PGA) that allows gains of 1, 2, 4, 8, 16, 32, 64, and 128. Additionally, the ADC contains a 2.5V reference, which can be used with reference buffers, along with the externally applied references. The host MCU is isolated from the ADC by the ADuM341E, a 5kVrms quad digital isolator from Analog Devices.

[Learn More]