You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
#include <eez/gui/gui.h>
|
|
|
|
#include "../firmware.h"
|
|
|
|
#include "main.h"
|
|
|
|
|
|
|
|
namespace eez {
|
|
|
|
namespace gui {
|
|
|
|
|
|
|
|
const EnumItem *g_enumDefinitions[] = { nullptr };
|
|
|
|
volatile int g_set_pin_status = 0;
|
|
|
|
|
|
|
|
void data_arduino_pwm_d3_pin_status(DataOperationEnum operation, const WidgetCursor &widgetCursor, Value &value) {
|
|
|
|
if (operation == DATA_OPERATION_GET) {
|
|
|
|
value = g_set_pin_status;
|
|
|
|
} else if (operation == DATA_OPERATION_SET) {
|
|
|
|
g_set_pin_status = value.getInt();
|
|
|
|
if(g_set_pin_status){
|
|
|
|
HAL_GPIO_WritePin(ARDUINO_PWM_D3_GPIO_Port, ARDUINO_PWM_D3_Pin, GPIO_PIN_SET);
|
|
|
|
}
|
|
|
|
else{
|
|
|
|
HAL_GPIO_WritePin(ARDUINO_PWM_D3_GPIO_Port, ARDUINO_PWM_D3_Pin, GPIO_PIN_RESET);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
} // namespace gui
|
|
|
|
} // namespace eez
|