5 months, 1 week ago.  This question has been closed. Reason: Off Topic

Turning off LED with barcode scanner

Hello all,

I'm trying to turn off my led light if I scan a certain barcode string. So far in my code I am able to retrieve the barcode and then see the output of that scan on my serial terminal. My issue is I'm not sure how to get my code to work to turn off the led if the scan is the correct string.

Attached is an image of my code:

/media/uploads/shanefowler25/screen_shot_2019-07-02_at_8.36.31_pm.png

Not shown in the image is the mbed and string headers included at the top. If someone could help me out that would be greatly appreciated, thank you!

I'm using the STM32F072RB nucleo board and I'm using the online mbed compiler on my mac. I don't think this makes much of a difference but I'll share in the info regardless