BLYNK_DEBUG print to terminal

I know I can print to the terminal like I do to serial monitor, but is it possible to print to terminal the DEBUG data as well? Or does DEBUG only print to Serial monitor?

I tried fiddling with that. Seems a bit of catch 22. You need Blynk to connect to use terminal, but Debug needs to be at the top of the script (before any connection is made). I could only get it to compile if I put #define BLYNK_PRINT terminal after #include <BlynkSimpleStream.h> and WidgetTerminal terminal(V1); But then nothing shows up on terminal, even after connect, unless I specifically print to it. And of course, if anything goes wrong with the connection… well, no way to send that data to terminal :stuck_out_tongue_winking_eye:

So unless the powers that be know something secret… I would have to say NO.

A similar question I would have is, can DEBUG info be displayed in the USB script window? <-- For us limited to the can-and-string connection method :wink:

I tried doing it a week ago and failed. Would love to see see this made an option. #define BLYNK_PRINT terminal

Well I am trying to figure out why my nano connected via ethernet, when connected in my shop disconnects and reconnects over 100 times a day. When I bring it inside and hook it up works just fine.

Same router? Wired or Wifi in each location?

I have a router in the shop but just as an access point connected to the router in the house over a Powerline Ethernet Connection.

When I connect it in the house I use a Powerline Ethernet Connection as well.

Based on that, I would suggest that there is just enough latency added with the (likely) longer distance to the shop (over the powerline) and the addition of the access point (especially if there is a double NAT situation). Blynk does seem a little picky on latency at times.

That what I was thinking. That’s why I was wanting to see the DEBUG on a terminal. I might just have to take my laptop out and try it, but it will still be going through the router and powerline connection.
There are 2 wifi camera’s and a security system connected to the router then through the powerline connection.

I can’t remember… Are you running the Cloud or Local Server? I believe DEBUG info is also stored on Local Server.

Cloud

Yup, then laptop… or if you have one, a physical LCD display on the nano might even work in a pinch (because, when troubleshooting, adding to the complexity is always the right way :wink: )

Do you mean like this :slight_smile:

this guy… :heart_eyes:

Is that showing all DEBUG data? If so yes.

Ah, yes… but as we normally ask… @Costas Do you have any code to back up what you are showing us? :stuck_out_tongue: (as in proper order of required commands)

Please :wink:

He goes quiet right after the big reveal he can do it … lol

1 Like

It was after 5am when I made the post so I then went to sleep :slight_smile:

For “sure” this is DEBUG data.

Something not quite right about that screenshot.
OK so the bottom of the “y” in Blynk is not quite in line but maybe that was just a Terminal glitch.
No it’s more than that.
Doesn’t the Blynk logo appear before the connection to the server is made?
How can the Terminal widget show this data?

1 Like

@Costas Are you playing ASCII art tricks here? There looks to be a leading space before each line.

And, as I already suspect… catch 22ish… need connection to use terminal, thus if connection down, no terminal.

Me thinks you are pulling our leg?

Hmm… or buffering text??

Got it!! :sunglasses:

Although my buffer or somthing may need to be adjusted… :confused:

After thinking about buffering… and good old Google, I found a solution’ish here:

Looks like you are getting there @Gunner