TOP Contributors

  1. MIKROE (2762 codes)
  2. Alcides Ramos (374 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 (139248 times)
  2. FAT32 Library (71743 times)
  3. Network Ethernet Library (57115 times)
  4. USB Device Library (47429 times)
  5. Network WiFi Library (43082 times)
  6. FT800 Library (42403 times)
  7. GSM click (29835 times)
  8. mikroSDK (28073 times)
  9. PID Library (26885 times)
  10. microSD click (26198 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: 3047 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

DIGI POT 14 Click

0

DIGI POT 14 Click is a compact add-on board that contains a digitally controlled potentiometer. This board features the TPL0102, a dual-channel digital potentiometer with non-volatile memory from Texas Instruments. It is a 100K resistance end-to-end potentiometer with a 256-position resolution, where the wiper position can be stored in EEPROM. It can operate from both 3.3V and 5V power supplies and provides a typical 92ppm/ºC end-to-end nominal resistance temperature coefficient and only 4ppm/ºC ratiometric.

[Learn More]

6DOF IMU 15 Click

5

6DOF IMU 15 Click is a compact add-on board that contains a 6-axis MEMS motion tracking device combining a 3-axis gyroscope and a 3-axis accelerometer. This board features the ASM330LHH, automotive 6-axis MEMS motion tracking device, from STMicroelectronics.

[Learn More]

AC Current click

6

AC Current click can measure alternating currents up to 30A and it features the MCP3201 ADC (analog to digital) converter and the MCP607 CMOS Op Amp, both from Microchip. The click is designed to run on either 3.3V or 5V power supply. It communicates with the target MCU over an SPI interface, and the AN pin on the mikroBUS line.

[Learn More]