Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/master' into pio
Browse files Browse the repository at this point in the history
  • Loading branch information
p-h-a-i-l committed Sep 20, 2018
2 parents 765f890 + 1a49e2c commit 9e38f2b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion inc/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@

// Battery voltage calibration: connect power source. see <How to calibrate>. write value nr 5 to BAT_CALIB_ADC. make and flash firmware. then you can verify voltage on value 6 (devide it by 100.0 to get calibrated voltage).
#define BAT_CALIB_REAL_VOLTAGE 43.0 // input voltage measured by multimeter
#define BAT_CALIB_ADC 1704 // adc-value measured by mainboard (value nr 4 on UART debug output)
#define BAT_CALIB_ADC 1704 // adc-value measured by mainboard (value nr 5 on UART debug output)

#define BAT_NUMBER_OF_CELLS 10 // normal Hoverboard battery: 10s
#define BAT_LOW_LVL1_ENABLE 0 // to beep or not to beep, 1 or 0
Expand Down
4 changes: 2 additions & 2 deletions src/comms.c
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ void setScopeChannel(uint8_t ch, int16_t val) {
}

void consoleScope() {
#if defined DEBUG_SERIAL_SERVOTERM && defined DEBUG_SERIAL_USART3
#if defined DEBUG_SERIAL_SERVOTERM && (defined DEBUG_SERIAL_USART2 || defined DEBUG_SERIAL_USART3)
uart_buf[0] = 0xff;
uart_buf[1] = CLAMP(ch_buf[0]+127, 0, 255);
uart_buf[2] = CLAMP(ch_buf[1]+127, 0, 255);
Expand All @@ -45,7 +45,7 @@ void consoleScope() {
}
#endif

#if defined DEBUG_SERIAL_ASCII && defined DEBUG_SERIAL_USART3
#if defined DEBUG_SERIAL_ASCII && (defined DEBUG_SERIAL_USART2 || defined DEBUG_SERIAL_USART3)
memset(uart_buf, 0, sizeof(uart_buf));
sprintf(uart_buf, "1:%i 2:%i 3:%i 4:%i 5:%i 6:%i 7:%i 8:%i\r\n", ch_buf[0], ch_buf[1], ch_buf[2], ch_buf[3], ch_buf[4], ch_buf[5], ch_buf[6], ch_buf[7]);

Expand Down

0 comments on commit 9e38f2b

Please sign in to comment.