xC0000005 / Marlin

Optimized firmware for RepRap 3D printers based on the Arduino platform.
http://www.marlinfw.org/
GNU General Public License v3.0
22 stars 5 forks source link

Serial output toggles between UI serial and USB serial #4

Open lawrence-jeff opened 5 years ago

lawrence-jeff commented 5 years ago

I notice serial output seems to output to different ports randomly and I can't seem to identify any pattern. For instance in the LCD code using a SERIAL_ECHOLNPAIR seems to randomly be sent to either the UI (Serial1) or the USB connection (Serial0). Some messages from Marlin itself (like temperature updates) seem to be sent to both.

Opening this to see if you understood why - I dug through the marlin code and it seems these functions should send to Serial0 - but often I get the output on my debug device attached to the UI and it changes based on the function in the LCD code, almost like it just goes to the last serial port written to.

xC0000005 commented 5 years ago

I'm looking at this and not sure - I"m seeing the same thing, and am beginning to think it may be related to using Serial vs USBSerial. I'm creating a PR right now to adapt your changes to the new extui malyan LCD and also fix error output. It now correctly shows when Marlin halts the printer.

xC0000005 commented 4 years ago

I'm working on ExtUI support and once I"m done with that, this is up next on the to-debug list.