To use the node in your project you should have the ivanmason/lcd16x2x5button library installed. Use the “File → Add Library” menu item in XOD IDE if you don’t have it yet. See Using libraries for more info.
C++ implementation
{{#global}}
#include <LiquidCrystal.h>
{{/global}}
using Type = LiquidCrystal*;
struct State {
};
{{ GENERATED_CODE }}
void evaluate(Context ctx) {
if (isInputDirty<input_UPD>(ctx)){
auto lcd = new LiquidCrystal(
(int)getValue<input_RS>(ctx),
(int)getValue<input_EN>(ctx),
(int)getValue<input_D4>(ctx),
(int)getValue<input_D5>(ctx),
(int)getValue<input_D6>(ctx),
(int)getValue<input_D7>(ctx));
lcd->begin(16, 2);
emitValue<output_DEV>(ctx,lcd);
emitValue<output_DONE>(ctx, 1);
}
}