-
I have an esp8266 connected to a skr 2 mainboard runing dwc3.5.0 . Whenever I press the reset button on the mainboard, or tell it to reboot from the web interface, the esp powers off and it just stays like that forever. The only thing that works afterwards is to power down the entire machine and turn it on again.
-
@justGuner how do you have it connect?
can you connect over usb and run M122 and post the output here after say 30 seconds of sending an emergency stop? -
@jay_s_uk I have it connected using the wifi headers on the board.
Here is the output after sending M122:
SENDING:M122 === Diagnostics === RepRapFirmware for STM32F4 based Boards (biquskr_2) version 3.5.0-rc.1+102 (2023-09-05 23:19:17) running on STM32F4 (standalone mode) Board ID: A1083-0D0JA-DDPV0-7L182-YB2T9-40000 Used output buffers: 1 of 40 (1 max) Error in macro line 78 while starting up: Accelerometer not found on specified port Error in macro line 78 while starting up: Accelerometer not found on specified port === RTOS === Static ram: 19704 Dynamic ram: 89268 of which 156 recycled Never used RAM 20916, free system stack 192 words CCMRam static ram: 24276 dynamic ram: 33204 free ram 8052 Tasks: NETWORK(1,ready,6.0%,497) HEAT(3,nWait,0.0%,375) Move(4,nWait,0.0%,359) TMC22xx(4,nWait,1.7%,146) FSWRITE(2,nWait,0.0%,566) MAIN(1,running,91.2%,563) IDLE(0,ready,1.0%,29), total 100.0% Owned mutexes: BITIO(TMC22xx) USB(MAIN) === Platform === Last reset 00:01:19 ago, cause: software Last software reset at 2024-01-29 15:35, reason: User, Gcodes spinning, available RAM 20916, slot 0 Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x00400000 BFAR 0xe000ed38 SP 0x00000000 Task MAIN Freestk 0 n/a Error status: 0x00 Error status: 0x00 MCU temperature: min 38.4, current 40.5, max 40.5 Supply voltage: min 24.0, current 24.0, max 24.0, under voltage events: 0, over voltage events: 0, power good: yes Heap OK, handles allocated/used 99/2, heap memory allocated/used/recyclable 2048/52/0, gc cycles 0 Events: 0 queued, 0 completed Driver 0: standstill 2209, SG min 0, reads 5643, writes 11 Driver 1: standstill 2209, SG min 0, reads 5643, writes 11 Driver 2: standstill 2209, SG min 0, reads 5643, writes 11 Driver 3: standstill 2209, SG min 0, reads 5642, writes 11 Driver 4: standstill 2209, SG min 0, reads 5642, writes 11 Driver 5: Driver 6: Driver 7: Driver 8: Driver 9: Driver 10: Driver 11: Driver 12: Driver 13: Date/time: 1970-01-01 00:00:00 Slowest loop: 7.23ms; fastest: 0.12ms === Storage === Free file entries: 20 SD card 0 detected SD card longest read time 1.5ms, write time 0.0ms, max retries 0 === Move === DMs created 83, segments created 0, maxWait 0ms, bed compensation in use: none, height map offset 0.000, ebfmin 0.00, ebfmax 0.00 no step interrupt scheduled Moves shaped first try 0, on retry 0, too short 0, wrong shape 0, maybepossible 0 === DDARing 0 === Scheduled moves 0, completed 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1 === DDARing 1 === Scheduled moves 0, completed 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1 === Heat === Bed heaters 0 -1 -1 -1, chamber heaters -1 -1 -1 -1, ordering errs 0 Heater 1 is on, I-accum = 0.0 === GCodes === Movement locks held by null, null HTTP is idle in state(s) 0 File is idle in state(s) 0 USB is ready with "M122" in state(s) 0 Aux is idle in state(s) 0 Trigger is idle in state(s) 0 Queue is idle in state(s) 0 LCD is idle in state(s) 0 Daemon is idle in state(s) 0 Autopause is idle in state(s) 0 File2 is idle in state(s) 0 Queue2 is idle in state(s) 0 Q0 segments left 0, axes/extruders owned 0x0004003 Code queue 0 is empty Q1 segments left 0, axes/extruders owned 0x0000000 Code queue 1 is empty === CAN === Disabled Longest wait 0ms for reply type 0, peak Tx sync delay 0 free buffers 0 (min 0), ts 0/0/0 Tx timeouts 0,0,0,0,0,0 === Network === Slowest loop: 0.21ms; fastest: 0.00ms Responder states: MQTT(0) HTTP(0) HTTP(0) HTTP(0) HTTP(0) FTP(0) HTTP sessions: 0 of 8 Uploads/Errors: 0/0 === WiFi === Interface state: disabled Module is disabled Failed messages: pending 0, notrdy 0, noresp 0 Bad header: 0/0 Socket states: 0 0 0 0 0 0 0 0
-
@justGuner it looks like your config.g might not being fully ran.
Can you post its contents please? -
@jay_s_uk Sure, here:
; Configuration file for BTT SKR 2 (firmware version 3) ; executed by the firmware on start-up ; ; generated by RepRapFirmware Configuration Tool v3.4.0-LPC-STM32+7 on Sun Aug 20 2023 12:46:47 GMT+0300 (Eastern European Summer Time) ; General preferences G90 ; send absolute coordinates... M83 ; ...but relative extruder moves M550 P"My Printer" ; set printer name M669 K1 ; select CoreXY mode ; Network M552 S1 ; enable network M586 P0 S1 ; enable HTTP M586 P1 S0 ; disable FTP M586 P2 S0 ; disable Telnet ; Drives M569 P0 S1 ; physical drive 0 goes forwards using default driver timings M569 P1 S1 ; physical drive 1 goes forwards using default driver timings M569 P2 S0 ; physical drive 2 goes backwards using default driver timings M569 P4 S0 ; physical drive 4 goes backwards using default driver timings M584 X0 Y1 Z2:3 E4 ; set drive mapping M350 Z256 E256 I0 ; configure microstepping without interpolation M350 X16 Y16 I1 ; configure microstepping with interpolation M92 X80.00 Y80.00 Z6400.00 E415 ; set steps per mm M566 X900.00 Y900.00 Z60.00 E1200.00 ; set maximum instantaneous speed changes (mm/min) M203 X30000.00 Y30000.00 Z1000.00 E3000.00 ; set maximum speeds (mm/min) M201 X10000.00 Y10000.00 Z300.00 E1000.00 ; set accelerations (mm/s^2) M906 X800 Y800 Z1200 E800 I30 ; set motor currents (mA) and motor idle factor in per cent M84 S30 ; Set idle timeout ; Axis Limits M208 X0 Y0 Z0 S1 ; set axis minima M208 X260 Y260 Z350 S0 ; set axis maxima ; Endstops M574 X2 S1 P"xstop" ; configure switch-type (e.g. microswitch) endstop for high end on X via pin xstop M574 Y2 S1 P"ystop" ; configure switch-type (e.g. microswitch) endstop for high end on Y via pin ystop M574 Z1 S2 ; configure Z-probe endstop for low end on Z ; Z-Probe M950 S0 C"servo0" ; create servo pin 0 for BLTouch M558 P9 C"^probe" H5 F120 T6000 ; set Z probe type to bltouch and the dive height + speeds G31 P500 X-22.345 Y-6.941 Z2.436523 ; set Z probe trigger value, offset and trigger height M557 X15:215 Y15:195 S20 ; define mesh grid ; Heaters M308 S0 P"bedtemp" Y"thermistor" T100000 B4092 ; configure sensor 0 as thermistor on pin bedtemp M950 H0 C"bed" T0 ; create bed heater output on bed and map it to sensor 0 M307 H0 B0 S1.00 ; disable bang-bang mode for the bed heater and set PWM limit M140 H0 ; map heated bed to heater 0 M307 H0 R0.320 K0.414:0.000 D1.01 E1.35 S1.00 B0 V24.6 ; set PID values for heated bed M143 H0 S130 ; set temperature limit for heater 0 to 120C M308 S1 P"e0temp" Y"thermistor" T100000 B4092 ; configure sensor 1 as thermistor on pin e0temp M950 H1 C"e0heat" T1 ; create nozzle heater output on e0heat and map it to sensor 1 M307 H1 B0 S1.00 ; disable bang-bang mode for heater and set PWM limit M143 H1 S300 ; set temperature limit for heater 1 to 300C M307 H1 R3.201 K0.662:0.000 D9.07 E1.35 S1.00 B0 V24.0 ; set PID values for heater 1 ; Fans M950 F0 C"fan0" Q250 ; create fan 0 on pin fan0 and set its frequency M106 P0 S0 H-1 ; set fan 0 value. Thermostatic control is turned off M950 F1 C"fan1" Q500 ; create fan 1 on pin fan1 and set its frequency M106 P1 S0 H1 T100 ; set fan 1 value. Thermostatic control is turned on ;M308 S2 P"e1temp" Y"thermistor" T100000 B4092 A"Bed mosfet" ; Tools M563 P0 D0 H1 F0:1 ; define tool 0 G10 P0 X0 Y0 Z0 ; set tool 0 axis offsets G10 P0 R0 S0 ; set initial tool 0 active and standby temperatures to 0C ; Custom settings are not defined ; Miscellaneous T0 ; select first tool M955 P0 C"PE_10+PE_9" I20 M572 D0 S0.085 M912 P0 S-8.9 ;M593 P"zvddd" F44.8 ; use ZVDDD input shaping to cancel ringing at 46.1Hz M308 S2 Y"drivers" A"DRIVERS" ; configure sensor 2 as temperature warning and overheat flags on the TMC2660 on Duet M308 S3 Y"mcu-temp" A"MCU" ; configure sensor 3 as on-chip MCU temperature sensor M950 F2 C"fan2" Q20000 ; create fan 2 on pin fan2 and set its frequency M106 P2 H2:3 L0.15 X0.5 B0.3 T40 ; set fan 2 value
-
@justGuner said in Esp8266 not turning on after mainboard reset:
M955 P0 C"PE_10+PE_9" I20
if you don't have the accelerometer connected, can you comment this out
M912 P0 S-8.9
We have a restriction on the STM32 port of the firmware that the temperature reported by the MCU can't be adjusted. Its detailed here https://teamgloomy.github.io/stm32_differences.html so please remove the M912 line.
Could you then try the emergency reset again? Could you also post a photo of your ESP module
-
@jay_s_uk Before I do those things, I should mention that the problem was present before adding those lines.
Update: the problem still persists
-
@justGuner please provide a photo of your ESP module/wiring.
what happens if, after an emergency reset, you runM552 S1
over USB? does it then reconnect?
If it does, can you grab another M122 output? -
@jay_s_uk After sending M552 S1, it finally connected. Here is the output:
SENDING:M122 === Diagnostics === RepRapFirmware for STM32F4 based Boards (biquskr_2) version 3.5.0-rc.1+102 (2023-09-05 23:19:17) running on STM32F4 (standalone mode) Board ID: A1083-0D0JA-DDPV0-7L182-YB2T9-40000 Used output buffers: 1 of 40 (15 max) === RTOS === Static ram: 19704 Dynamic ram: 89268 of which 156 recycled Never used RAM 20916, free system stack 169 words CCMRam static ram: 24276 dynamic ram: 30348 free ram 10908 Tasks: NETWORK(1,ready,8.0%,243) HEAT(3,nWait,0.0%,365) Move(4,nWait,0.0%,359) TMC22xx(4,nWait,1.8%,146) FSWRITE(2,nWait,0.0%,566) MAIN(1,running,89.1%,563) IDLE(0,ready,1.2%,29), total 100.0% Owned mutexes: WiFi(NETWORK) BITIO(TMC22xx) USB(MAIN) === Platform === Last reset 00:01:05 ago, cause: software Last software reset at 2024-01-29 17:08, reason: User, Gcodes spinning, available RAM 20916, slot 1 Software reset code 0x0003 HFSR 0x00000000 CFSR 0x00000000 ICSR 0x00400000 BFAR 0xe000ed38 SP 0x00000000 Task MAIN Freestk 0 n/a Error status: 0x00 Error status: 0x00 MCU temperature: min 39.6, current 40.0, max 40.1 Supply voltage: min 24.0, current 24.0, max 24.0, under voltage events: 0, over voltage events: 0, power good: yes Heap OK, handles allocated/used 0/0, heap memory allocated/used/recyclable 0/0/0, gc cycles 0 Events: 0 queued, 0 completed Driver 0: standstill 2209, SG min 0, reads 4620, writes 11 Driver 1: standstill 2209, SG min 0, reads 4620, writes 11 Driver 2: standstill 2209, SG min 0, reads 4620, writes 11 Driver 3: standstill 2209, SG min 0, reads 4620, writes 11 Driver 4: standstill 2209, SG min 0, reads 4619, writes 11 Driver 5: Driver 6: Driver 7: Driver 8: Driver 9: Driver 10: Driver 11: Driver 12: Driver 13: Date/time: 2024-01-29 17:09:17 Slowest loop: 99.78ms; fastest: 0.12ms === Storage === Free file entries: 20 SD card 0 detected SD card longest read time 1.5ms, write time 0.0ms, max retries 0 === Move === DMs created 83, segments created 0, maxWait 0ms, bed compensation in use: none, height map offset 0.000, ebfmin 0.00, ebfmax 0.00 no step interrupt scheduled Moves shaped first try 0, on retry 0, too short 0, wrong shape 0, maybepossible 0 === DDARing 0 === Scheduled moves 0, completed 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1 === DDARing 1 === Scheduled moves 0, completed 0, hiccups 0, stepErrors 0, LaErrors 0, Underruns [0, 0, 0], CDDA state -1 === Heat === Bed heaters 0 -1 -1 -1, chamber heaters -1 -1 -1 -1, ordering errs 0 Heater 1 is on, I-accum = 0.0 === GCodes === Movement locks held by null, null HTTP is idle in state(s) 0 File is idle in state(s) 0 USB is ready with "M122" in state(s) 0 Aux is idle in state(s) 0 Trigger is idle in state(s) 0 Queue is idle in state(s) 0 LCD is idle in state(s) 0 Daemon is idle in state(s) 0 Autopause is idle in state(s) 0 File2 is idle in state(s) 0 Queue2 is idle in state(s) 0 Q0 segments left 0, axes/extruders owned 0x0004003 Code queue 0 is empty Q1 segments left 0, axes/extruders owned 0x0000000 Code queue 1 is empty === CAN === Disabled Longest wait 0ms for reply type 0, peak Tx sync delay 0 free buffers 0 (min 0), ts 0/0/0 Tx timeouts 0,0,0,0,0,0 === Network === Slowest loop: 14.75ms; fastest: 0.00ms Responder states: MQTT(0) HTTP(0) HTTP(0) HTTP(0) HTTP(0) FTP(0) HTTP sessions: 1 of 8 Uploads/Errors: 0/0 === WiFi === Interface state: active Module is connected to access point Failed messages: pending 0, notrdy 0, noresp 0 Bad header: 0/0 Firmware version 1.27-02S-D MAC address 68:58:11:44:3b:b0 Module reset reason: Turned on by main processor, Vcc 3.26, flash size 4194304, free heap 35696 WiFi IP address 192.168.1.40 Signal strength -56dBm, channel 0, mode 802.11n, reconnections 0 Clock register 00004002 Socket states: 0 0 0 0 0 0 0 0
-
@justGuner Can i ask again for a photo of the ESP/wiring please?
And can you also send the following commands over USB and post the full output
M111 P14 S1 M552 S-1 M552 S1
Give 10 seconds or so between sending each of the above commands
-
@jay_s_uk
(ignore the hot glue; I ripped the sd card slot accidentally a while back)Here's the output :
s1 SENDING:M552 S1 WiFi: WiFi: ets Jan 8 2013,rst cause:2, boot mode:(3,7) WiFi: WiFi: load 0x4010f000, len 1392, room 16 WiFi: tail 0 WiFi: chksum 0xd0 WiFi: csum 0xd0 WiFi: v00000000 WiFi: ~ld WiFi: phy buf[107] is ff adc mode is ff WiFi: boot not set WiFi: ota1 not set WiFi: ota2 not set WiFi: V2 WiFi: Mo WiFi: irf cal sector: 1019 WiFi: freq trace enable 0 Got rubbish reply from COM5 at baudrate 115200: Maybe a bad baudrate?
I did try the same command with other baudrates; it gave the same rubbish reply thing every time
-
@justGuner What are you using to connect to the board? If you are using a Windows PC I would suggest using putty see: https://teamgloomy.github.io/putty.html We really need to see all of the output to work out what is happening. If you are connecting to the board via USB the baud rate is ignored.
I've not seen a module connected like that before. You seem to have a lot more pins connected between the module and the board than we would normally recommend (Our setup uses 11 in total I think you have 16 connected). I'm not sure if the additional ones could be causing a problem.
-
@gloomyandy yeah, I'm not gonna be able to try new things for about a week since I won't be near the printer...
I am connected to the printer over USB via pronterface
In terms of the pins used, I assumed that because on the official esp board there are 16 pins, all of them are connected. What are the necessary pins (on the esp) for the module to work properly?
-
@justGuner We don't have instructions for that board because most people simply use a commercially available module (if you get one get an esp32). The module you linked to may have all of the pins but I suspect some of them are not connected. You may be able to work out the connections from looking at the details of the homemade boards for the SKR Pro and mathcing it up with the skr 2 schematic. https://teamgloomy.github.io/skr_pro_connected_wifi_8266.html note that this does not include the UART connections, but I think you already have those working correctly.
I'd strongly recommend using putty rather than pronterface. Pronterface tends to try and interpret/change the commands and responses and generally "gets in the way".
-
-
Here is a little update on the situation: after trying to solder some resistors to the esp according to this, I think I managed to damage the esp somehow, because after connecting it to the skr afterwards resulted in timeout errors no matter what. To make sure, I reverted to the previous method of wiring straight to the wifi header just like before, only to result in the same timeout error.
If I'm unable to fix this new issue by trying to resolder the wires again, I think I will just buy the btt esp module.
-
@justGuner I think all of the resistors that are needed are already on the skr2 board (see the schematic I linked to above). If you do get a module I'd strongly recommend that you get an esp32 version not an esp8266. Not sure if BTT do a esp32 but, Fly/Mellow certainly does. You will get much better performance from that and additional features.
-
@gloomyandy can you tell me what are some of the other features I get by going with the esp32? All I could find online was improved conectivity over the 8266
-
-
@deckingman Yeah but how many of those features can I use on the 3d printer itsels? For example as far as I know there isn't any bluetooth suport in rrf yet, and the sole reasong for buying an esp is to be attached to the printer, so I'm not thinking about using it in other projects
-
@justGuner The main "feature" is the improved upload speed. With the esp8266 the best I ever see is around 550KBytes/s with the esp32 I see up to 2.5MBytes/s with a STM32H7 based board, with a STM32F4 board I'd expect around 1.8MBytes/s. But that all depends on your WiFi signal SD card speed etc.
The other thing is that new features like enterprise wifi authentication and the MQTT support both need the latest 2.1 version of the WiFi firmware and that seems to run much better on the esp32. Basically there is not likely to be any new work on the esp8266 firmware going forwards (at least not from me). For the small extra cost I just don't think it makes sense to use an 8266.