I bought a duinotech arduino uno with wifi today and when I plug it into my laptop a green light and a red light turn on on the arduino but it doesn't show up in the device manager. I tried on two other computers and with another cable too and the same thing happens.
I've tried plugging it in multiple times and one time something did pop up in the device manager but it had an error saying "Uknown USB device (device descriptor request failed)" with the device status saying "Windows has stopped this device because it has reported problems. (Code 43)
A request for the USB device descriptor failed.". I've tried restarting my computer and re-installing the arduino IDE but this does not fix it. I'm thinking it might be a driver issue but i'm not sure what drivers to install for my specific board.
UPDATE: I fiddled around with the usb connection to the arduino and then something unrecognized to windows popped up in the device manager. I updated the drivers then it shows up as "USB Serial CH340)". In the arduino IDE I'm now able to select the port (which I wasn't able to do before). When I try to get board info through Tools -> Get Board Info, it says unknown board. In my list of boards I pick generic ESP8266 module, as it says in the manual. However when i try to upload code i get the error message:
esptool.FatalError: Failed to connect to ESP8266: Timed out waiting for packet header
Make sure the USB cable is fully inserted into the socket on the board and your computer. On a new board, sometimes it takes a bit of force to get the plug fully inserted.
Remove any external wiring, modules, or shields you might have connected to the board.
Okay. I selected "wifiduino" from the boards option and I successfully uploaded my sketch... i think? I uploaded the blink sketch from examples and it says done uploading but in the console thing at the bottom it says:
"leaving...
Hard resetting via RTS pin..."
but the light on the board is not flashing.
It's possible that the pin you're blinking is simply not connected to the LED on the board. The wifiduino variant defines LED_BUILTIN as 2 (which is GPIO2) but there's no guarantee that is the pin the designer of this board decided to connect the LED to. Try modifying the Blink sketch to blink one of the pins that are broken out to the "ESP Pin's" [sic] header on the board and then connect an LED or multimeter to that pin to see if it's working. Note that with the ESP8266 boards, the Dn pin notation is not necessarily the same as the GPIO numbers. For example, here are the definitions of the Dn pin names for the wifiduino variant:
I also don't see any documentation that indicates the board you have is using the wifiduino variant. Perhaps you just selected that because "wifiduino" sounds somewhat similar to "duinotech"?
The documentation at the link Juraj provided shows the Tools > Board > Generic ESP8266 Module board selected. The generic variant defines LED_BUILTIN as 1. Still no guarantee that the board designers connected the LED to GPIO1 though, but I suppose it's worth a try.
Pretty odd that they provide a sketch meant to run on the ATmega328P at the end of the instructions for uploading to the ESP8266. I'm always just astounded by the amazingly lack of effort so many of these companies put towards documentation. After all the work they do to manufacture or procure the hardware, create the product page on the website, etc. They miss that little bit of extra effort that could mean so much for the potential success of the product in the hobbyist/maker/educational market. I know they end up spending far more in the end on support due to the lack of documentation.
I ran into a bunch of similar problems but have now got it working.
The instructions_troubleshooting.txt located inside the XC4411-softwareMain.zip was pretty useful, much more than the "manual".
In brief, you have to switch the little dip switches (located on the board just above the WiFi logo) 3 times:
to chat to arduino,
to chat to ESP8266,
to chat to each other.
Then you need to log on to the Wifi network it creates called "XC4411 Dual Board example code", then go to http://10.0.0.7 and there is a simple web page for switching the LED on and off and away you go.
Hope this helps.
Here is the instructions_troubleshooting.txt in its entirety:
If you haven't already, install the ESP8266 Boards addon as per the XC3802
manual located on the product page:
https://jaycar.com.au/p/XC3802
the code in this zipfile is used as an example for our new XC4421 and XC4411
boards.
To write arduino code:
-------------------------------------
Configure the dip switches as shown: 3,4 are on, the others are off.
|-|-|o|o|-|-|-|-| on
|o|o|-|-|o|o|o|o| off
|1|2|3|4|5|6|7|8|
for XC4421 select Tools->Board->Arduino Mega (for XC4421) Or Uno (for XC4411)
open arduino.ino and press upload.
To write esp code:
-------------------------------------
Configure the dip switches as shown: 5,6,7 are on, the others are off.
|-|-|-|-|o|o|o|-| on
|o|o|o|o|-|-|-|o| off
|1|2|3|4|5|6|7|8|
for XC4421 select Tools->Board->Generic 8266 Module
-> If you cannot see it, you did not read the XC3802 Manual!
open esp.ino and press upload; after compiling, when the IDE says "Uploading.."
You should begin to see ".......________........_____" during this time, press
the reset button on the MCU; the ESP should begin to accept
instructions.
To run the example:
---------------------------------------
Upload both of the code as above, then configure the switches as shown: (1,2 are on)
|o|o|-|-|-|-|-|-| on
|-|-|o|o|o|o|o|o| off
|1|2|3|4|5|6|7|8|
Open up your wireless internet and you should see a new wireless network.
Connect to it and navigate to http://10.0.0.7, you'll see two hyperlinks
to turn the arduino L13 led on/off. You should be able to see the device
interplay between your phone/computer, the ESP, and the arduino.
Troubleshooting:
-----------------------------------------
"upload esp mem failed" in arduino IDE ESP8266 error:
* have you selected the right switch config? ensure that 5,6, AND 7, are
switched _ON_
* Did you press the MCU Reset button when the IDE says "uploading" ?
"WiFiServer.h not found" or similar not found messages
* Did you install the ESP8266 Boards in the Arduino IDE? read the XC3802
manual.
* Have you selected the right board for the project? make sure
Tools->Board->Generic8266 board is selected for the ESP project, and
Geniuno is selected for Arduino
Writing html code is better in proper html files, which can be stored in a "data" folder
and uploaded automatically, check out "SPIFFS" for more information:
https://randomnerdtutorials.com/esp8266-web-server-spiffs-nodemcu/