I was trying to configure Marlin ( as per Chris Warkocki, https://www.youtube.com/watch?v=EWjKpgYp5wQ) for a PRUSA i3 MK3s BEAR Upgrade. After modifying Configure.h and Configure_adv.h, Marlin wouldn't compile. I traced down the following #defines as the issue:
Configuration.h
#define Z_MIN_PROBE_REPEATABILITY_TEST
#define FILAMENT_RUNOUT_SENSOR
#define LCD_INFO_SCREEN_STYLE 1
#define SPEAKER
#define REPRAP_DISCOUNT_SMART_CONTROLLER
Configuration_adv.h
#define FAN_MIN_PWM 80
#define NUM_Z_STEPPER_DRIVERS 2
There are others, but these appear to be the Main issues. I have a bunch of questions, but if we can figure out these issues, I'll follow up with more.
Thanks!
Thanks for feedback those questions. and I am debugging and fix those one by one.
I just found this compile error in Pi4, and now is fixed and uploaded to github,you can update this by click the button of "Update Raspbian" in the raspberryPi_ip:8181 page.
how to wire filament runout sensor:
https://github.com/markniu/PandaPi/wiki/How-to-wiring-filament-runout-sensor
Thanks Mark, This still fails if #define FILAMENT_RUNOUT_DISTANCE_MM 2 is defined in Config.h:
./src/feature/runout.h: In static member function ‘static void TFilamentMonitor<RESPONSE_T, SENSOR_T>::run()’:
./src/feature/runout.h:110:15: error: ‘cli’ cannot be used as a function
cli(); // Prevent RunoutResponseDelayed::block_completed from accumulating here
^
./src/feature/runout.h:116:11: error: there are no arguments to ‘sei’ that depend on a template parameter, so a declaration of ‘sei’ must be available [-fpermissive]
sei();
^~~
./src/feature/runout.h:116:11: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)
Took some digging to find out why your version would compile and not mine.
error message
error: #error "Z_MIN_PROBE_REPEATABILITY_TEST requires a probe: FIX_MOUNTED_PROBE, NOZZLE_AS_PROBE, BLTOUCH, SOLENOID_PROBE, Z_PROBE_ALLEN_KEY, Z_PROBE_SLED, or Z Servo.
Mark, I do have a mounted probe and it's defined as supposed, it is even working correctly but when I enable z min probe repeatability test it wont compile. It's there a compile log somewhere so I can try to help you with some of these issues?
@Ramon Luis Ramos Yep, I am seeing the following when I try to compile:
In file included from src/gcode/calibrate/../../inc/../HAL/HAL.h:26,
from src/gcode/calibrate/../../inc/MarlinConfig.h:30,
from src/gcode/calibrate/M48.cpp:23:
src/gcode/calibrate/../../inc/../HAL/./HAL_PANDAPI/HAL.h:211:1: warning: multi-line comment [-Wcomment]
//#define HAL_STEP_TIMER_ISR() \
^
src/gcode/calibrate/M48.cpp: In static member function ‘static void GcodeSuite::M48()’:
src/gcode/calibrate/M48.cpp:127:5: error: ‘randomSeed’ was not declared in this scope
randomSeed(millis());
^~~~~~~~~~
src/gcode/calibrate/M48.cpp:127:5: note: suggested alternative: ‘random_r’
randomSeed(millis());
^~~~~~~~~~
random_r
src/gcode/calibrate/M48.cpp:135:38: error: too many arguments to function ‘long int random()’
const int dir = (random(0, 10) > 5.0) ? -1 : 1; // clockwise or counter clockwise
^
In file included from /usr/include/c++/8/cstdlib:75,
from /usr/include/c++/8/stdlib.h:36,
from src/gcode/calibrate/../../inc/../core/macros.h:23,
from src/gcode/calibrate/../../inc/../core/boards.h:24,
from src/gcode/calibrate/../../inc/MarlinConfigPre.h:35,
from src/gcode/calibrate/../../inc/MarlinConfig.h:28,
from src/gcode/calibrate/M48.cpp:23:
/usr/include/stdlib.h:401:17: note: declared here
extern long int random (void) __THROW;
^~~~~~
src/gcode/calibrate/M48.cpp:136:36: error: too many arguments to function ‘long int random()’
float angle = random(0, 360);
^
In file included from /usr/include/c++/8/cstdlib:75,
from /usr/include/c++/8/stdlib.h:36,
from src/gcode/calibrate/../../inc/../core/macros.h:23,
from src/gcode/calibrate/../../inc/../core/boards.h:24,
from src/gcode/calibrate/../../inc/MarlinConfigPre.h:35,
from src/gcode/calibrate/../../inc/MarlinConfig.h:28,
from src/gcode/calibrate/M48.cpp:23:
/usr/include/stdlib.h:401:17: note: declared here
extern long int random (void) __THROW;
^~~~~~
src/gcode/calibrate/M48.cpp:144:9: error: too many arguments to function ‘long int random()’
);
^
In file included from /usr/include/c++/8/cstdlib:75,
from /usr/include/c++/8/stdlib.h:36,
from src/gcode/calibrate/../../inc/../core/macros.h:23,
from src/gcode/calibrate/../../inc/../core/boards.h:24,
from src/gcode/calibrate/../../inc/MarlinConfigPre.h:35,
from src/gcode/calibrate/../../inc/MarlinConfig.h:28,
from src/gcode/calibrate/M48.cpp:23:
/usr/include/stdlib.h:401:17: note: declared here
extern long int random (void) __THROW;
^~~~~~
src/gcode/calibrate/M48.cpp:163:54: error: too many arguments to function ‘long int random()’
delta_angle = dir * (float) random(25, 45);
^
In file included from /usr/include/c++/8/cstdlib:75,
from /usr/include/c++/8/stdlib.h:36,
from src/gcode/calibrate/../../inc/../core/macros.h:23,
from src/gcode/calibrate/../../inc/../core/boards.h:24,
from src/gcode/calibrate/../../inc/MarlinConfigPre.h:35,
from src/gcode/calibrate/../../inc/MarlinConfig.h:28,
from src/gcode/calibrate/M48.cpp:23:
/usr/include/stdlib.h:401:17: note: declared here
extern long int random (void) __THROW;
^~~~~~
src/gcode/calibrate/M48.cpp:259:78: error: ‘dtostrf’ was not declared in this scope
ui.status_printf_P(0, PSTR(S_FMT ": %s"), GET_TEXT(MSG_M48_DEVIATION), dtostrf(sigma, 2, 6, sigma_str));
^~~~~~~
src/gcode/calibrate/M48.cpp:259:78: note: suggested alternative: ‘strstr’
ui.status_printf_P(0, PSTR(S_FMT ": %s"), GET_TEXT(MSG_M48_DEVIATION), dtostrf(sigma, 2, 6, sigma_str));
^~~~~~~
strstr
make: *** [Makefile:36: src/gcode/calibrate/M48.o] Error 1
randomSeed appears to be an Arduino thing.
error message:
"error: #error "Alternative LCD_INFO_SCREEN_STYLE requires 20x4 Character LCD."
this pandapi board do not support this 20*4 LCD,because it required many GPIO.
only support buzzer now, but it's nice to use speaker connector on the Pi,I will add that later.
Thanks Mark. I know it is extra work for you, but this helps document the capabilities of the PandaPi board.