Cant get LCD to work on Dolly Build

Electronics, Components etc
Post Reply
TAPII
Posts: 3
Joined: Mon Oct 02, 2017 6:46 pm

Cant get LCD to work on Dolly Build

Post by TAPII » Mon Oct 02, 2017 9:00 pm

Howdy,
This is my first post and first printer. I'm an electronics tech and an avid R/Cer. So building things such as this isn't generally an issue. My problem comes with the programing. Not my cup of tea! But I have managed to get all other aspects of the printer working. The problem I am having is that when I turn on the LCD in firmware and compile it I get errors. Here is the first one that comes up.

In file included from sketch\temperature.h:31:0,

from sketch\ultralcd.cpp:28:

sketch\thermistortables.h:677:1: warning: narrowing conversion of '3.20640015e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

};

^

sketch\thermistortables.h:677:1: warning: narrowing conversion of '3.71040009e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '4.27359985e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '4.99679993e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '5.84320007e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '6.84e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '8.10880005e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '9.6352002e+2' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.15247998e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.38943994e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.64464001e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.99135999e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '2.41632007e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '2.92576001e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '3.53152002e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '5.07135986e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '7.15472021e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '9.44975977e+3' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.179696e+4' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.37243203e+4' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.50323203e+4' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.57764805e+4' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\thermistortables.h:677:1: warning: narrowing conversion of '1.61392002e+4' from 'double' to 'const short int' inside { } [-Wnarrowing]

sketch\ultralcd.cpp: In function 'void _lcd_move_xyz(const char*, AxisEnum)':

ultralcd.cpp:1414: error: 'min_software_endstops' was not declared in this scope

float min = (soft_endstops_enabled && min_software_endstops) ? soft_endstop_min[axis] : current_position[axis] - 100,

^

In file included from sketch\MarlinConfig.h:27:0,

from sketch\Marlin.h:36,

from sketch\ultralcd.h:26,

from sketch\ultralcd.cpp:23:

ultralcd.cpp:1431: error: 'max' was not declared in this scope

if ((int32_t)encoderPosition > 0) NOMORE(current_position[axis], max);

^

sketch\macros.h:66:33: note: in definition of macro 'NOMORE'

#define NOMORE(v,n) do{ if (v > n) v = n; }while(0)

^

exit status 1
'min_software_endstops' was not declared in this scope


Anyone have any idea why its doing this?? I'm not completely sure what I'm looking at since I am new to the Arduino stuff and programing in general. Thanks for any help you can give me.

TAPII

chumm
Posts: 176
Joined: Thu Jun 15, 2017 11:24 am

Re: Cant get LCD to work on Dolly Build

Post by chumm » Mon Oct 02, 2017 9:54 pm

Hi, what LCD are you using?

TAPII
Posts: 3
Joined: Mon Oct 02, 2017 6:46 pm

Re: Cant get LCD to work on Dolly Build

Post by TAPII » Mon Oct 02, 2017 10:41 pm

Sorry, I did forgot to put that. I'm just using the standard 20x4 line screen and controller. Here is the description on the page RAMPS 1.4 3D PRINTER 2004 LCD smart controller. I did get the screen to display the temps and tell me the printer is ready but that's it. Thanks

TAPII

chumm
Posts: 176
Joined: Thu Jun 15, 2017 11:24 am

Re: Cant get LCD to work on Dolly Build

Post by chumm » Tue Oct 03, 2017 12:13 am

Hm, if it's displaying the info the LCD settings are probably right, but looking at the code, I think the ultralcd.cpp file only gets called when you enable a TFT or similar high-resolution display. In the LCD section of the firmware, make sure only the following LCD is enabled (the "//" is removed before #define). Maybe you have multiple LCDs enabled and it's calling unnecessary code.

Code: Select all

// RepRapDiscount Smart Controller.
// http://reprap.org/wiki/RepRapDiscount_Smart_Controller
//
// Note: Usually sold with a white PCB.
//
#define REPRAP_DISCOUNT_SMART_CONTROLLER

TAPII
Posts: 3
Joined: Mon Oct 02, 2017 6:46 pm

Re: Cant get LCD to work on Dolly Build

Post by TAPII » Tue Oct 03, 2017 3:11 pm

I will look back through it but I'm pretty sure just the one LCD is selected. Seems like it is the controller that isn't working but I'm not sure.

chumm
Posts: 176
Joined: Thu Jun 15, 2017 11:24 am

Re: Cant get LCD to work on Dolly Build

Post by chumm » Tue Oct 03, 2017 9:02 pm

The wiki has some outdated information for using that controller. Just make sure the above is the LCD you have selected and not ULTIPANEL, which is the same shape of LCD but is outdated and uses that ultralcd code.

User avatar
Tomáš“tomoxm”Martinove
Posts: 1
Joined: Sat Jun 16, 2018 10:53 pm

Re: Cant get LCD to work on Dolly Build

Post by Tomáš“tomoxm”Martinove » Sat Jun 16, 2018 10:56 pm

Hello, maybe it is not late, but for me helped that i enabled

Code: Select all

#define REPRAP_DISCOUNT_SMART_CONTROLLER
and also enabled

Code: Select all

#define min_software_endstops true // If true, axis won't move to coordinates less than HOME_POS.
#define max_software_endstops true  // If true, axis won't move to coordinates greater than the defined lengths below.
all in configuration.h

hope this helps

Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests