DuetWiFiServer upload to generic ESP8266
-
Is it possible to upload the complied DuetWiFiServer-1.23.bin to a generic ESP8266?
I was trying it out with a 4MB device using the espressif ESP flash tool but could not get it to work properly. Not sure if it is a settings issue on where to place the bin location at e.g. 0x01000 or just not compatible at all.
If it is not flash-able this way, would I need to compile a different firmware from source instead?
I finally got around to using my first duet 2 Ethernet v1.03 after having it sit around for quite awhile, purchased on sale when the v1.04's were coming out. I really enjoy the web interface, much more then ESP3D and thought I'd try and adapt that to an Azteeg X5 Mini Wifi (trying out the LPC port of RRF) either using the internal ESP8266 or an external one and connect it over the TX/RX port. Also might try to use it on other boards as well.
-
https://github.com/gloomyandy/RepRapFirmware/wiki/ESP8266
This covers setting up an ESP8266 for the LPC Port.
If you get the pinout for the Azteeg X5 Mini sorted, let me know and I'll add it to the wiki. -
I was able to flash device by removing the RX0 and TX0 jumpers and by shorting JD1 to put pull IO 0 to GND. Although I messed up and forgot to backup the flash, trying to request it from panucatt
I have been trying to get RepRapFirmware to run on the Azteeg Mini X5 Wifi using the LPC176X port but to no avail. The device hangs if I connect it to the ESP, I think partly because I do not have the boards.txt setup properly for the uSD card. Is there a way I can test the ESP DuetWifiServer on it's own? From what I have read I think it needs access to files on the SD card.
I have more or less reversed the pins from the uSD to the FST3257 that sits in-between the LPC1769 and the ESP8266, most of the other pins already match that from the X5 Mini v1.1.
It's messy but this what I have compiled X5MiniWifi-pinout -
@fythios DuetWifiServer uses SPI to communicate with the main board and in the LPC port this is assumed to be connected to SSP0.
-
Looking at the wiring diagram here http://files.panucatt.com/datasheets/x5mini_wiring_v3.pdf, you may be able to follow the SKR wiring guide found here https://github.com/gloomyandy/RepRapFirmware/wiki/SKR-1.4 as most of the pins can be found on headers EXP1 and EXP2. The only pin you'll have an issue with is 0.28 as its not available.
Could you try pin 0.25 instead? You'll need to set the pin accordingly in your board.txt file.
If that doesn't work, try pin 2.11.
Please update us if either of those work.Example board.txt file
//Config for Azteeg x5 Mini lpc.board = azteegx5mini_1.1 //wifi pins 8266wifi.espDataReadyPin = 0.25 //or 2.11 8266wifi.lpcTfrReadyPin = 1.30 8266wifi.espResetPin = 1.31 adc.prefilter.enable = true
-
@jay_s_uk Thank you all for your support and help on this, please note I am using the x5mini wifi (diagram), I generated the system files using LPC RRF config, updated my board.txt, hooked the up the ESP per pin out but am not getting any response from either the ESP or board.
I think there is a larger issue I am having right now of the Azteeg X5 Mini Wifi not responding. I uploaded the latest RFF LPC176X port, named in Firmware.bin. It did it's update thing per the LEDs. The halt LED (leds.diagnostic = 4.28) is just blinking the entire time. I can hook up to it over USB and send commands but get no response. The SD access LED is stuck on however. I tried a simple M115 but got back nothing, I am using YAT as outlined in the Duet guide.
The major difference I can tell between the wifi and mini v1.1 is there are two controllable fans and the on board ESP. Fan 1 = P1_25, Fan 2 = P0_26, and P2_4 is on the header. I have pulled the RX and TX from the onboard ESP device, and per the wiring and datasheet the on board uSD card is connected to a 2:1 multiplexer (FST3257) then to either the LPC1769 or the on board ESP. The ESP controls the switching with IO 0, when pulled low it connects the uSD to the ESP, normally pulled-up and connected to the LPC1769.
I will keep tinkering with it and let you know if I make any progress.
ESP RES LPC1769 RST 470R 1.31 GPIO15 2200R 0.16 GPIO13 47R 0.18 GPIO12 47R 0.17 GPIO14 47R 0.15 GPIO0 2200R 0.25 GPIO4 None 1.30 3.3V None 3.3v GND None GND GND 2200R RST
-
I've emailed them and asked for copies of the design files.
That way, we can go through them and check the complete pinout.
I can then get the wifi version added to the firmware.Need to look more into the onboard wifi and see how that's connected.
Might have found another use case for those board.txt file changes (SPI Pinout) we spoke about.
-
I think you will need to use custom firmware for the ESP8266. At the moment the "standard" firmware will be using GPIO0 to talk to the LPC1768, but you need it to control the SD multiplexer. There is also the issue of what state the ESP8266 pins are in when the LPC1768 boots and tries to read the SD card (to obtain information on how to talk to the ESP8266!). I suspect that to get this working you will also need custom firmware for the LPC1768 as well.
-
@gloomyandy I am curious about that too but will have to wait for the stock onboard ESP8266 firmware as I messed it up. You make a great point, I did not consider what the firmware on the LPC1769 is doing on boot. I did try forcing the multiplexer in one state or another by pulling the onboard ESP GPIO 0 to either GND or 3.3V, this actually causes the SD access LED to either turn on or off. Although the onboard ESP8266 RX and TX lines are connected to the LPC1769 on TXD0 and RXD0 so that might have something to do with it as well.
Only a handle full of random times did I get the board to respond to an M115 command, sometimes right after it installs the RRF firmware and then boots up. Any subsequent reboots puts the device in limbo and non operating mode.
This board might not be a good candidate for this, I did however learn a lot and will be messing around with this more as I have replaced this board with a Duet 2 wifi. I just really enjoy RRF and the DuetWifiServer, so wanted to run both on this board if possible.
-
I suspect your best bet is to leave the built in Wifi stuff well alone and to add an additional ESP8266 to use for the RRF DWC. But this all assumes that the various I/O lines are available, in particular the SPI0 pins.