Compare commits
3
Commits
ee72092a3a
...
v0.1.0
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b51cce709a | ||
|
|
09aff91b31 | ||
|
|
36fd363d67 |
No files matched your search
Vendored
+7
-7
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
// See http://go.microsoft.com/fwlink/?LinkId=827846
|
// See http://go.microsoft.com/fwlink/?LinkId=827846
|
||||||
// for the documentation about the extensions.json format
|
// for the documentation about the extensions.json format
|
||||||
"recommendations": [
|
"recommendations": [
|
||||||
"platformio.platformio-ide"
|
"platformio.platformio-ide"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -23,9 +23,13 @@
|
|||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="pwm">
|
<div class="pwm">
|
||||||
<label id="l_pwm"></label>
|
<label id="label_pwm"></label>
|
||||||
<input type="range" min="1" max="100" value="50" class="rangeslider" id="range1">
|
<input type="range" min="1" max="100" value="50" class="rangeslider" id="range1">
|
||||||
</div>
|
</div>
|
||||||
|
<div class="timer">
|
||||||
|
<label id="label_timer"></label>
|
||||||
|
<input type="range" min="1" max="100" value="50" class="rangeslider" id="timer_range">
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+18
-12
@@ -2,14 +2,18 @@
|
|||||||
#include <Wire.h>
|
#include <Wire.h>
|
||||||
|
|
||||||
#include "PCA9685.h"
|
#include "PCA9685.h"
|
||||||
|
#include <GDBStub.h>
|
||||||
|
|
||||||
|
#define ESP12_LED 2
|
||||||
|
#define NODEMCU_LED 16
|
||||||
|
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#include "user_interface.h"
|
#include "user_interface.h"
|
||||||
}
|
}
|
||||||
os_timer_t Timer1; // Verwaltungsstruktur des Timers
|
os_timer_t Timer1; // Verwaltungsstruktur des Timers
|
||||||
|
|
||||||
uint32_t c;
|
int c;
|
||||||
|
bool toggle = false;
|
||||||
uint32_t m=0;
|
uint32_t m=0;
|
||||||
|
|
||||||
uint32_t dimmtimer = 0;
|
uint32_t dimmtimer = 0;
|
||||||
@@ -24,14 +28,13 @@ void timerCallback(void *pArg)
|
|||||||
{
|
{
|
||||||
*((int *) pArg) += 1;
|
*((int *) pArg) += 1;
|
||||||
|
|
||||||
//Serial.print("hallo\n");
|
|
||||||
//Serial.println(micros()-m);
|
|
||||||
//m = micros();
|
|
||||||
ledsequence(direction, onoff, 4);
|
ledsequence(direction, onoff, 4);
|
||||||
}
|
// Serial.print("[");
|
||||||
|
// Serial.print(micros()-m);
|
||||||
|
// Serial.print("] timerCallback\n");
|
||||||
|
// m = micros();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// Änderung
|
|
||||||
// OTA & WEB
|
// OTA & WEB
|
||||||
#include "wifi_credentials.h"
|
#include "wifi_credentials.h"
|
||||||
#include <ESP8266WiFi.h>
|
#include <ESP8266WiFi.h>
|
||||||
@@ -172,15 +175,18 @@ void setup_pwm_pca9685() {
|
|||||||
pwmController.init(B000000); // Address pins A5-A0 set to B000000
|
pwmController.init(B000000); // Address pins A5-A0 set to B000000
|
||||||
pwmController.setPWMFrequency(200); // Default is 200Hz, supports 24Hz to 1526Hz
|
pwmController.setPWMFrequency(200); // Default is 200Hz, supports 24Hz to 1526Hz
|
||||||
|
|
||||||
pwmController.setChannelPWM(0, 128 << 4); // Set PWM to 128/255, but in 4096 land
|
|
||||||
|
|
||||||
Serial.println(pwmController.getChannelPWM(0)); // Should output 2048, which is 128 << 4
|
Serial.println(pwmController.getChannelPWM(0)); // Should output 2048, which is 128 << 4
|
||||||
}
|
}
|
||||||
|
|
||||||
void setup() {
|
void setup() {
|
||||||
Serial.begin(115200);
|
Serial.begin(460800);
|
||||||
|
gdbstub_init();
|
||||||
|
|
||||||
Serial.println(F("Booting ...."));
|
Serial.println(F("Booting ...."));
|
||||||
|
|
||||||
|
pinMode(NODEMCU_LED, OUTPUT);
|
||||||
|
pinMode(ESP12_LED, OUTPUT);
|
||||||
|
|
||||||
Wire.begin(); // Wire must be started first
|
Wire.begin(); // Wire must be started first
|
||||||
Wire.setClock(400000); // Supported baud rates are 100kHz, 400kHz, and 1000kHz
|
Wire.setClock(400000); // Supported baud rates are 100kHz, 400kHz, and 1000kHz
|
||||||
|
|
||||||
@@ -235,7 +241,7 @@ uint8_t softstart_led(uint8_t led, uint16_t startval, uint16_t stopval, uint8_t
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
#define LEDCOUNT 13
|
#define LEDCOUNT 16
|
||||||
|
|
||||||
void ledsequence(uint8_t direction, uint8_t onoff, uint8_t factor){
|
void ledsequence(uint8_t direction, uint8_t onoff, uint8_t factor){
|
||||||
static int8_t led = 0;
|
static int8_t led = 0;
|
||||||
|
|||||||
Whitespace-only changes.
Reference in new issue
Block a user