get-pixel-color

awgrover/adafruitneopixel/get-pixel-color

No description
get-pixel-color
@/get-pixel-color
adafruitneopixel@/adafruitneopixel
triggerpulse
get-pixel-color
adafruitneopixel
trigger
dev
val
done
donepulse
valnumber
dev@/adafruitneopixel
To use the node in your project you should have the awgrover/adafruitneopixel 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

//-- int Adafruit_NeoPixel::getPixelColor()
// Our constructor namespace should be: awgrover__adafruit_neopixel_ll__adafruitneopixel
struct State {
  // not used
  };

{{ GENERATED_CODE }}

void evaluate(Context ctx) {

  // only act on trigger, inputs not relevant for this
  if ( !isInputDirty<input_trigger>(ctx) ) return;

  // var names are valid c++ because we got them from the arglist of the c++ method
  

  auto object  = getValue<input_adafruitneopixel>(ctx); // Adafruit_NeoPixel

  auto rez = object->getPixelColor(  ); // int
  
  emitValue<output_dev>(ctx, object); // for chaining

  emitValue<output_val>(ctx, rez); // int
  emitValue<output_done>(ctx, 1); // pulse
}