TOP Contributors

  1. MIKROE (2662 codes)
  2. Alcides Ramos (357 codes)
  3. Shawon Shahryiar (307 codes)
  4. jm_palomino (112 codes)
  5. Chisanga Mumba (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 (137033 times)
  2. FAT32 Library (70166 times)
  3. Network Ethernet Library (56035 times)
  4. USB Device Library (46357 times)
  5. Network WiFi Library (41973 times)
  6. FT800 Library (41302 times)
  7. GSM click (29079 times)
  8. mikroSDK (26519 times)
  9. PID Library (26452 times)
  10. microSD click (25449 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

MRAM 2 click

Rating:

5

Author: MIKROE

Last Updated: 2020-08-26

Package Version: 1.0.0.0

mikroSDK Library: 1.0.0.0

Category: MRAM

Downloaded: 1606 times

Not followed.

License: MIT license  

MRAM 2 Click is a compact add-on board for applications that must store and retrieve data and programs quickly using a small number of pins. This board features the MR10Q010, 1Mb Quad Output High-Speed Serial SPI MRAM memory solution from Everspin Technologies.

No Abuse Reported

Do you want to subscribe in order to receive notifications regarding "MRAM 2 click" changes.

Do you want to unsubscribe in order to stop receiving notifications regarding "MRAM 2 click" changes.

Do you want to report abuse regarding "MRAM 2 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

MRAM 2 Click

MRAM 2 Click

Native view of the MRAM 2 Click board.

View full image
MRAM 2 Click

MRAM 2 Click

Front and back view of the MRAM 2 Click board.

View full image

Library Description

The library covers all the necessary functions that enables the usage of the MRAM 2 Click board. It initializes and defines the SPI bus driver and drivers that offer a full functionality of the click board. User has Read Status Register, Write Enable, Write Disable, Write Status Register, Read Data Bytes, Fast Read Data Bytes, Write Data Bytes, Enter Sleep Mode, Exit Sleep, Tamper Detect, Tamper Detect Exit and Read IDfunctions at his disposal.

Key functions:

  • void mram2_write ( uint32_t mem_adr, uint8_t *wr_data, uint8_t n_bytes ); - The Write Data Bytes function allows data bytes to be written sequentially.
  • void mram2_read ( uint32_t mem_adr, uint8_t *rd_data, uint8_t n_bytes ); - The Read Data Bytes function allows data bytes to be continuously read starting at an initial address.
  • void mram2_wren ( ); - Function is used to enable write operation.

Examples description

The application is composed of three sections :

  • System Initialization - Initializes SPI module, LOG structure, sets CS, RTS and INT pins as output.
  • Application Initialization - Initalizes SPI driver and sets up the device.
  • Application Task - This example shows capabilities of MRAM 2 Click board by writting "MikroE" into first 6 memory locations, and then reading it back.
void application_task ( )
{
    mikrobus_logWrite( "Write enable!", _LOG_LINE );
    mram2_wren( );
    Delay_ms( 100 );
    mikrobus_logWrite( "Writing : ", _LOG_TEXT );
    mikrobus_logWrite( val_in, _LOG_TEXT );
    mram2_write( 0x000000, &val_in[ 0 ], 9 );
    Delay_ms( 100 );
    mikrobus_logWrite( "Write disable!", _LOG_LINE );
    mram2_wrdi ( );
    Delay_ms( 100 );
    mikrobus_logWrite( "Reading : ", _LOG_TEXT );
    mram2_read ( 0x000000, &val_out[ 0 ], 9 );
    mikrobus_logWrite( val_out, _LOG_TEXT );
    
    mikrobus_logWrite( "-------------------", _LOG_LINE );
    Delay_ms( 5000 );
}

Other mikroE Libraries used in the example:

  • SPI
  • UART

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

EnOcean 2 click

5

EnOcean 2 click carries the TCM 515Z transceiver, based on the 2.4 GHz IEEE 802.15.4 radio standard. The click is designed to run on a 3.3V power supply. It communicates with the target microcontroller over UART interface.

[Learn More]

Bluetooth2 click

0

Bluetooth 2 Click features WT41u, a long range class 1, Bluetooth® 2.1 + EDR module. WT41u is a highly integrated and sophisticated Bluetooth® module, containing all the necessary elements from Bluetooth® radio and a fully implemented protocol stack. Therefore WT41u provides an ideal solution for developers who want to integrate Bluetooth® wireless technology into their design with limited knowledge of Bluetooth® and RF technologies. WT41u optimized for long range applications is available with an integrated chip antenna. By default, the WT41u module is equipped with powerful and easy-to-use iWRAP firmware which enables users to access Bluetooth® functionality with simple ASCII commands delivered to the module over serial interface - it's just like a Bluetooth® modem.

[Learn More]

Opto Encoder 5 click

0

Opto Encoder 5 Click is a compact add-on board that offers non-contact switching with unparalleled accuracy and precision. This board features the OPB666N, a Photologic® slotted optical switch from TT Electronics, ensuring top-notch performance and reliability. It integrates an 890nm infrared LED and a monolithic integrated circuit with a photodiode, linear amplifier, and Schmitt trigger, all powered effectively by a 5V supply from the mikroBUS™ power rail. The board features an NPN open-collector output configuration and is TTI/LST TL compatible, highlighting its ease of use and versatility.

[Learn More]