#include <Controller.h>
Controller.h の 36 行目に定義があります。
◆ Controller()
Controller::Controller |
( |
| ) |
|
◆ buttonIsPressedBack()
bool Controller::buttonIsPressedBack |
( |
| ) |
|
◆ buttonIsPressedDown()
bool Controller::buttonIsPressedDown |
( |
| ) |
|
◆ buttonIsPressedEnter()
bool Controller::buttonIsPressedEnter |
( |
| ) |
|
◆ buttonIsPressedLeft()
bool Controller::buttonIsPressedLeft |
( |
| ) |
|
◆ buttonIsPressedRight()
bool Controller::buttonIsPressedRight |
( |
| ) |
|
◆ buttonIsPressedUp()
bool Controller::buttonIsPressedUp |
( |
| ) |
|
◆ convertHsv()
void Controller::convertHsv |
( |
int & |
r, |
|
|
int & |
g, |
|
|
int & |
b |
|
) |
| |
Controller.cpp の 213 行目に定義があります。
228 if(r == g && r == b) hsv.
hue = 0;
233 if(max - min != 0) max += 1;
234 hsv.
hue = 60 * ((g - b) / (max - min));
239 if(max - min != 0) max += 1;
240 hsv.
hue = 60 * ((b - r) / (max - min)) + 120;
245 if(max - min != 0) max += 1;
246 hsv.
hue = 60 * ((r - g) / (max - min)) + 240;
249 if(hsv.
hue < 0) hsv.
hue += 360;
252 if(max - min != 0) max += 1;
258 hsv.
value = max / 255 * 100;
◆ getAngleOfRotation()
int Controller::getAngleOfRotation |
( |
| ) |
|
◆ getBatteryVoltage()
float Controller::getBatteryVoltage |
( |
| ) |
|
|
static |
◆ getBrightness()
int Controller::getBrightness |
( |
| ) |
|
Controller.cpp の 71 行目に定義があります。
74 int luminance = 0.298912 * rgb.r + 0.586611 * rgb.g + 0.114478 * rgb.b;
◆ getHsv()
◆ getLeftMotorCount()
int Controller::getLeftMotorCount |
( |
| ) |
|
◆ getRawColor()
void Controller::getRawColor |
( |
int & |
r, |
|
|
int & |
g, |
|
|
int & |
b |
|
) |
| |
◆ getRightMotorCount()
int Controller::getRightMotorCount |
( |
| ) |
|
◆ hsvToColor()
Controller.cpp の 86 行目に定義があります。
88 if(status.
value <= 33.5294){
89 if(status.
value <= 18.4314){
92 if(status.
hue <= 159.5357){
93 if(status.
hue <= 83.739){
94 if(status.
hue <= 40.8904){
103 if(status.
value <= 32.9412){
106 if(status.
hue <= 299.6104){
115 if(status.
value <= 45.2941){
116 if(status.
hue <= 263.0811){
117 if(status.
hue <= 32.8235){
120 if(status.
hue <= 76.7547){
121 if(status.
hue <= 44.8367){
122 if(status.
hue <= 40.5263){
131 if(status.
value <= 40.1961){
132 if(status.
value <= 35.4902){
146 if(status.
hue <= 283.6016){
147 if(status.
hue <= 99.2199){
148 if(status.
value <= 51.1765){
◆ lcdDrawString()
void Controller::lcdDrawString |
( |
const char * |
str, |
|
|
int |
x, |
|
|
int |
y |
|
) |
| |
|
static |
◆ lcdFillRect()
void Controller::lcdFillRect |
( |
int |
x, |
|
|
int |
y, |
|
|
int |
h |
|
) |
| |
|
static |
Controller.cpp の 168 行目に定義があります。
170 ev3_lcd_fill_rect(x, y, EV3_LCD_WIDTH, h, EV3_LCD_WHITE);
◆ lcdSetFont()
void Controller::lcdSetFont |
( |
| ) |
|
|
static |
◆ ledSetColorGreen()
void Controller::ledSetColorGreen |
( |
| ) |
|
◆ ledSetColorOrange()
void Controller::ledSetColorOrange |
( |
| ) |
|
◆ limitAngle()
int Controller::limitAngle |
( |
int |
angle | ) |
|
◆ resetMotorCount()
void Controller::resetMotorCount |
( |
| ) |
|
◆ setLeftMotorPwm()
void Controller::setLeftMotorPwm |
( |
const int |
pwm | ) |
|
◆ setRightMotorPwm()
void Controller::setRightMotorPwm |
( |
const int |
pwm | ) |
|
◆ speakerPlayToneFS6()
void Controller::speakerPlayToneFS6 |
( |
int |
duration | ) |
|
|
static |
◆ speakerSetVolume()
void Controller::speakerSetVolume |
( |
int |
volume | ) |
|
◆ stopMotor()
void Controller::stopMotor |
( |
| ) |
|
◆ tslpTsk()
void Controller::tslpTsk |
( |
int |
time | ) |
|
|
static |
◆ clock
◆ colorSensor
ColorSensor Controller::colorSensor |
◆ gyroSensor
GyroSensor Controller::gyroSensor |
◆ MOTOR_PWM_MAX
constexpr int Controller::MOTOR_PWM_MAX = 100 |
|
static |
◆ MOTOR_PWM_MIN
constexpr int Controller::MOTOR_PWM_MIN = -100 |
|
static |
◆ touchSensor
TouchSensor Controller::touchSensor |
このクラス詳解は次のファイルから抽出されました: