Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
var lcd; // Declare a variável LCD aqui pra ser acessível por outras funções
var onArduinoReady = function () {
// Quando o arduino tiver pronto
// ...
lcd = new QualquerCoisa();
lcd.on('ready', onLcdReady);
};
var onLcdReady = function () {
// ...
mostraLcd()
};
var mostraLcd = function () {
// ...
// Objeto lcd estará acessivel aqui
};
arduino.on('ready', onArduinoReady)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.