#ifndef BITSTRUCT_H
#define BITSTRUCT_H
#include "include.h"
#include "typedef.h"

#define LED_SET(led, field, value) \
    (led)->l = ((led)->l & LED_MASK_##field) | \
               (((uint64_t)(value) & ((1ULL << LED_SIZE_##field) - 1)) << LED_PADD_##field)

RGB_LED* create_led(uint16_t temp,uint8_t brg,uint8_t r,uint8_t g,uint8_t b);
char modify_led(RGB_LED* led,LED_WICH wh,uint16_t num);
void set_leds(MATRIX* m,LED_WICH wh, uint16_t num);
void del_leds(MATRIX* m);

#endif
