Arduino Mega 2560

Registers are memory blocks containing essential data for controlling or setting up microcontrollers. ATmega328P and ATmega2560 contain 8 bit registers. You can reach registers by knowing their address, which you can find by reading your microcontroller's datasheet. Learn more about register functionalities from the datasheet. You will be able to get and set register data using the serial monitor on your computer.

Required hardware

  • Arduino Mega 2560

Source code to install on controller


Before you upload this code to your Arduino, please format the EEPROM...
#include <OzIDManager.h>
#include <OzRegisterManipulation.h>
 
OzIDManager* manager;
OzRegisterManipulation* registerController;
 
void setup()
{
    Serial.begin(115200);
 
    manager = new OzIDManager;
    manager->_sendACK = true;
    manager->_checksum = true;
    
    OzCommunication::setIDManager(manager);
    
    registerController = new OzRegisterManipulation();

    int x = 1;
    manager->sendLinkSetup();
    manager->PrintWelcomeLine(registerController, x++);
}

void loop()
{
    OzCommunication::communicate();
}