-->
Page 1 of 2

Can't upload from arduino IDE to nodeMCU v1

PostPosted: Sun Jan 24, 2016 4:06 am
by jrubins
Hi There,
I've just gotten my nodemcu all hooked up and lovely, but it won't talk to the Arduino IDE. I get error messages like
Code: Select allUploading 215456 bytes from /var/folders/rq/7kqgjrqd54d9g8pjq11_69vm0000gn/T/build03a8c3bb7e07490dfbbd35d8fb056769.tmp/CheckFlashConfig.ino.bin to flash at 0x00000000
warning: espcomm_send_command: wrong direction/command: 0x01 0x08, expected 0x01 0x02
warning: espcomm_send_command(FLASH_DOWNLOAD_BEGIN) failed

I have successfully rewritten the nodemcu firmware using
Code: Select allpython ./esptool.py --port /dev/tty.wch write_flash 0x00000 ../nodemcu_integer_0.9.6-dev_20150704.bin

If I connect serial monitor (9600) and 'reset' i see
Code: Select allNodeMCU 0.9.6 build 20150704  powered by Lua 5.1.4
lua: cannot open init.lua
>

and if I type AT, I just get ">>" at the prompt typing AT again gives me "stdin:2: '=' expected near 'AT' "
Anyway, I have no idea what's going on at this stage , so any help is appreciated, thanks!

Re: Can't upload from arduino IDE to nodeMCU v1

PostPosted: Mon Feb 01, 2016 12:20 pm
by jrubins
Bump!
I tried this again this past weekend and I still get nothing from the arduino. Any advice or is my nodeMCU just buggered?

Thanks,
JR

Re: Can't upload from arduino IDE to nodeMCU v1

PostPosted: Mon Feb 01, 2016 12:36 pm
by WereCatf
Have you tried holding the flash-button down while pressing reset? That should place it in a bootloader where no other code is executing and the issue with wrong direction for data should disappear and uploading a sketch with Arduino IDE should work fine. It's sometimes necessary to do it like that if e.g. your sketch just happens to write to the serial-port when the IDE tries to initialize uploading, and it would appear that the Nodemcu - firmware does exactly that.

Re: Can't upload from arduino IDE to nodeMCU v1

PostPosted: Mon Feb 01, 2016 12:40 pm
by martinayotte
jrubins wrote:and if I type AT, I just get ">>" at the prompt typing AT again gives me "stdin:2: '=' expected near 'AT' "
Anyway, I have no idea what's going on at this stage , so any help is appreciated, thanks!

If you uploaded the Lua firmware, don't expect any AT commands to work : AT firmware is one thing and Lua another. They are 2 different firmwares.
When you have the Lua prompt ">", simply try some Lua commands.
(I'm not familiar with Lua, so, look at the Lua sub-forum to get some simple example)