/*
 * LampFactory.h
 *
 *  Created on: December 28, 2019
 *      Author: Andreas Schneider, Johannes Wendel, Jonas Zeunert
 */

#ifndef FLIPPR_DRIVER_LAMPFACTORY_H
#define FLIPPR_DRIVER_LAMPFACTORY_H

#include "output/DriverBoardPinController.h"
#include "ItemFactory.h"
#include "output/items/Lamp.h"

namespace flippR_driver
{
namespace output
{

class LampFactory : ItemFactory
{
public:
  LampFactory(nlohmann::json & object, std::shared_ptr<DriverBoardPinController> pin_controller);
  std::map<std::string, std::shared_ptr<items::Lamp>> getItemMap();

private:
  void set_address_pins();
  void set_mux_pins();

  uint8_t get_address_pin(nlohmann::json & pin_object);
};

}
}

#endif //FLIPPR_DRIVER_LAMPFACTORY_H
