-
-
-
-
I have a code is working before but since the code is using Serial1.onData when i upload my code is get warning so i change the code above.
the older code
function onInit() { Serial1.setup(9600);} var trace = ""; Serial1.onData(function (e) { print("--->"+e.data); trace = +e.data; if(trace == "1" ){ digitalWrite(LED3,1); } if(trace == "0" ){ digitalWrite(LED3,0); } }); save();
-
Hi all,
I using the following code to control the On board LED by the Bluetooth ,when using USB cable to power the code below is work .but when i unplug the USB and using battery to power up is nothing happen .//Setup the BT Serial function onInit() { Serial1.setup(9600); } var trace = ""; Serial1.on('data', function (data) { trace = +data; digitalWrite(LED3,0); if(trace == "1" ){ digitalWrite(LED2,1); } if(trace == "0" ){ digitalWrite(LED2,0); } }); save();
-
-
@Gordon Hi, I Found what is the issue .
is my fault when i solder the pin header to Espruino not correct. their still have some gap.
I have use a LED test by
digitalWrite
All PIN is working Fine Now
-
@Ducky Thank You for you information and reply.
@Gordon I found my problem but still have one issue for me.First: in bread board, power circuit(+,-)is separated at half point so i need to make the far right two wire near.
The unsolved issue is i can't solve when i using [C6,C7,C8,C9] or [C6,C7,C4,C5]
the motor is not work properly.
Example if i using [C6,C7,C8,C9] and code like below . the motor should be stop,
but one of the motor is still workingvar outputs = [C6,C7,C4,C5]; digitalWrite(outputs[0],0); // output 1 digitalWrite(outputs[1],0); // output 2 digitalWrite(outputs[2],0); // output 3 digitalWrite(outputs[3],0); // output 4
I need to code like below to stop both of the motor
var outputs = [C6,C7,C4,C5]; digitalWrite(outputs[0],0); // output 1 digitalWrite(outputs[1],0); // output 2 digitalWrite(outputs[2],0); // output 3 digitalWrite(outputs[3],1); // output 4
I have testing few hours in [C6,C7,C8,C9] and [C6,C7,C4,C5] this two group.
but the result is same all not work properly for me.After few hours I change my Circuit PIN to B3,B4,B5,B6
Like the Attach Images belowand code like below is work properly for me
Both motor is Run
var outputs = [B3,B4,B5,B6]; digitalWrite(outputs[0],0); // output 1 digitalWrite(outputs[1],1); // output 2 digitalWrite(outputs[2],0); // output 3 digitalWrite(outputs[3],1); // output 4
Both motor is Stop
var outputs = [B3,B4,B5,B6]; digitalWrite(outputs[0],0); // output 1 digitalWrite(outputs[1],0); // output 2 digitalWrite(outputs[2],0); // output 3 digitalWrite(outputs[3],0; // output 4
I have No Idea why the PIN in the "C" is not working properly but the PIN in "B" is working Good?
-
I have Change my Circuit to the Following.
and update my code todigitalWrite(LED1,1); //Check the Board is Word for LED var outputs = [C6,C7,C8,C9]; digitalWrite(outputs[0],1); // output 1 digitalWrite(outputs[1],0); // output 2 digitalWrite(outputs[2],1); // output 3 digitalWrite(outputs[3],0); // output 4
But the Gearmotor is still not working
-
-
-
Hello,
I using a L293D chip(16 pin) to control two 298:1 Micro Metal Gearmotor.
the following attach files is my Circuit.Any i refer the http://www.espruino.com/L293D and write my code like below
but when send to Espruino to LED is LightUp but the GearMotor still not work is it any step i missing?digitalWrite(LED3,1); //Check the Board is Word for LED var outputs = [C6,C7,C8,C9]; digitalWrite(outputs[0],1); // output 1 digitalWrite(outputs[1],1); // output 2 digitalWrite(outputs[2],1); // output 3 digitalWrite(outputs[3],1); // output 4
-
-
-
-
@Gordon sorry for later reply just .busy in work.
I just get my ESPRUINO PICO today. I happy to Draw ESPRUINO PICO if you want