Teacup_Firmware icon indicating copy to clipboard operation
Teacup_Firmware copied to clipboard

BANG_BANG Not defined

Open youssefaly97 opened this issue 9 years ago • 4 comments

In the master branch, BANG_BANG, BANG_BANG_ON, BANG_BANG_OFF are not defined. As a temporary fix I just added these to heater.h

#ifndef BANG_BANG #define BANG_BANG #endif

#define BANG_BANG_ON -2 #define BANG_BANG_OFF 2

I was only checking the binary size for a specific configuration, so the values I entered for bang bang on and off are probably wrong, considering I've always preferred PID.

youssefaly97 avatar Nov 15 '16 22:11 youssefaly97

These values should be part of your printer configuration file, config/printer.xxx.h. I just checked, they're there. Also, Configtool writes them.

Traumflug avatar Nov 15 '16 22:11 Traumflug

Well I checked, BANG_BANG is there, the On and Off are commented out. Still thought why does it not recognize it ?

On Nov 16, 2016, at 12:45 AM, Traumflug [email protected] wrote:

These values should be part of your printer configuration file, config/printer.xxx.h. I just checked, they're there. Also, Configtool writes them.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

youssefaly97 avatar Nov 16 '16 00:11 youssefaly97

Maybe it would help when activating BANG_BANG in configtool that there are some default values.

heater.c: In function 'heater_tick':
heater.c:186:17: error: 'BANG_BANG_OFF' undeclared (first use in this function)
    pid_output = BANG_BANG_OFF;
                 ^
heater.c:188:17: error: 'BANG_BANG_ON' undeclared (first use in this function)
    pid_output = BANG_BANG_ON;

tonnico avatar Nov 16 '16 10:11 tonnico

Well, I haven't given it much thought. I just thought it's a small bug, report it.

On Nov 16, 2016, at 12:14 PM, Nico Tonnhofer [email protected] wrote:

Maybe it would help when activating BANG_BANG in configtool that there are some default values.

heater.c: In function 'heater_tick': heater.c:186:17: error: 'BANG_BANG_OFF' undeclared (first use in this function) pid_output = BANG_BANG_OFF; ^ heater.c:188:17: error: 'BANG_BANG_ON' undeclared (first use in this function) pid_output = BANG_BANG_ON; — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

youssefaly97 avatar Nov 16 '16 17:11 youssefaly97