THW-Funk-Audio-Switch/Programm/Audio-Switch/io/ports/portb.hpp
2020-10-19 18:16:51 +02:00

40 lines
570 B
C++

/*
* portb.cpp
*
* Created: 19.10.2020 17:46:58
* Author: netz
*/
#ifndef BLUBBLIB_PORTB_HPP
#define BLUBBLIB_PORTB_HPP
#include <avr/io.h>
namespace blubblib {
struct portb {
static uint8_t Port() {
return PORTB;
}
static void Port(uint8_t v) {
PORTB = v;
}
static uint8_t Pin() {
return PINB;
}
static void Pin(uint8_t v) {
PINB = v;
}
static uint8_t Dir() {
return DDRB;
}
static void Dir(uint8_t v) {
DDRB = v;
}
};
}
#endif