Project 3 : Controlling led

Hi
the led bulb is not glowing . everything is perfect , the hardware connection was right and i have used the code mentioned in the training and the code was also error free still after trying a lot of times the led is not glowing …I have also checked the led whether it was a faulty but it was all right …please help me i cant figure out where the problem lies …

have you connected a resistor, make sure that it is connected to the positive leg of the LED, and shorter leg is GND

sir
i have checked the hardware connections were right even removing the resistor and the led i have tried to connect the buzzer without resistor still it was not working…
sir plz see the code :

Bolt IoT Platform ON OFF

i have used the code used the training`

Hi @moharanajanmajay

Check whether your code is as below:

Bolt IoT Platform ON OFF

Check your device is connected and functioning properly and connected to the cloud.

1 Like
Bolt IoT Platform ON OFF

I hope you haven’t replace the “API Key” and “Name” with your device details. Keep it as it is.

If still not working try this js code:

singleButton({name:“ON”, action:“digitalWrite”, pin:“0”, value:“HIGH”});
singleButton({name:“Off”, action:“digitalWrite”, pin:“0”, value:“LOW”});

2 Likes

Actually there is the problem with the API key …thank you everyone for your wonderful consultation .
The problem is solved now

2 Likes

also check out this website


there is some api rules to access it

Sir can you tell me what was your problem with your API key

Thanks for your concern
I entered my previous API key that’s why the device was not responding

Once see carefully the resistor which you have connected whether you have connect the leg of resistor to the proper pin because there is difference in both the legs which you can find the right one by reading the color on the resistor.

Thank you sir, i also had the same problem now it has fixed

Don’t replace the “API Key” and “Name” with your device details. Keep it as it is.
If not working try this js code:

singleButton({name:“ON”, action:“digitalWrite”, pin:“0”, value:“HIGH”});
singleButton({name:“Off”, action:“digitalWrite”, pin:“0”, value:“LOW”});

The setKey command is not showing as a valid command
It appears white instead of green showing that the compiler does not recognize this command
as a result I am getting internal sever error 500. Please help