Commit eb0dd6f6 authored by Øystein Smith's avatar Øystein Smith

Changed range of offtime table, and added comments on witch hex switch is witch

parent 460af3dd
......@@ -19,7 +19,7 @@
#define GPIO_SIGNAL_INPUT_PIN0 0
// Hex 0
#define GPIO_ONTIME_HEX_0_PORT (PORTD)
#define GPIO_ONTIME_HEX_0_PIN (PIND)
#define GPIO_ONTIME_HEX_1_PORT (PORTD)
......@@ -34,7 +34,7 @@
#define GPIO_ONTIME_HEX_PIN2 2
#define GPIO_ONTIME_HEX_PIN3 3
// Hex 1
#define GPIO_OFFTIME_HEX_0_PORT (PORTC)
#define GPIO_OFFTIME_HEX_0_PIN (PINC)
#define GPIO_OFFTIME_HEX_1_PORT (PORTC)
......
......@@ -11,6 +11,7 @@
#include <inttypes.h>
// Hex 0
uint16_t ontime_table[16] = { // 256/255 of max value. (in 1/2 microseconds) max value ~2^14 ~=16k
2, // almost nothing
100, // 50us
......@@ -30,23 +31,24 @@ uint16_t ontime_table[16] = { // 256/255 of max value. (in 1/2 microseconds) max
2000 // 1000us
};
// Hex 1
uint16_t offtime_table[16] = {
100, // 50us
200, // ...
400,
600,
800,
1000,
1200,
1400,
1600,
1800,
2000,
2200,
2400,
2600,
2800,
3000 //1.5 ms
10, // 50us
20, // ...
40,
60,
80,
100,
120,
140,
160,
180,
200,
220,
240,
260,
280,
300 //1.5 ms
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment