[Update] Tellurium: serial monitor

Tellurium has been updated. You can download the latest installer from here: https://dl.dropboxusercontent.com/u/85621331/tellurium%20setup.exe (NB: changed as of 27th June, 2013)

Any questions / feedback / suggestions / bugs can be added to this thread.

Roadmap (what's coming next):

  • timer based send to com port. ie specify a string and an interval and Tellurium will send the string at that interval until you stop it.

Known issues:

  • toggling the auto scroll function can lead to incorrect scrolling when it's just been turned off. brain currently broken. function will be fixed but is not critical to application.
  • the raw output memo is meant to be using a fixed width font but fails to render all characters with the same width.

Version history:
Version 1.5.0.0

  • Fix: bluetooth ports should now be handled efficiently at start up. This also fixes a bug where modules like HC06 BT modules would be essentially disabled by the app starting up.
  • New: Stay on top button added

Version 1.0.1.19

  • Fix: kinda. Reset may almost work at resetting a board that is continuously spitting out data. Maybe.

  • New: raw output modes update. 3 options:

  • Ascii: just displays the raw ascii, replacing non-printable characters with a period ('.').

  • Hex: displays the hex value of each character. You can specify characters per line, from 0 to 42. At 0, no manual line wrapping occurs. From 1 to 42, horizontal scrollbars ensure your wrapping happens where you want it to.

  • Both: displays the hex value and then the character value further to the right. Characters per line is restricted to 1..42, and horizontal scrollbars make sure this happens regardless of window size.

  • Fix: switching from Hex output mode with width == 0 to "Both" output mode resulted in an error.

Version 1.0.1.16

  • Fix: "Clear" raw output when not connected.

Version 1.0.1.15

  • Fix: 0 characters per line in hex output mode now does what you expect: start world war III. Or leave wrapping to the memo control, and hence wrap at the edges of the memo. Pick one.
  • Fix: the number of characters (n) to display per line is now honoured, rather than n+1. Good old greater than comparison not quite up to the task.

Version 1.0.1.14

  • New: hex output now available. number of characters per line displayed is settable from 0 to 48. Software proven to not be idiot proof. Maybe I should go and fix that 0 characters / line edge case. Nah. She'll be right.
  • New: ascii output replaces non-printable characters other than space, tab and cr/lf as "."
  • Fix: show/hide sent text toggle at startup now updating correctly

Version 1.0.0.10

  • show / hide sent text history
  • DBG library integration: variables and pins sent via DBG are displayed on the "Parsed variables" tab

Version 1.0.0.8

  • displays all currently connected com ports with a description of what's connected to that port
  • all drop down selection, toggle button, form position, etc settings should be saved and restored at startup
  • auto reset upon connect
  • manual reset
  • manual reset button present in numerous places, so you don't have to look away from your current app focus to reset the board. Haven't seen this done like this before, am curious how it will be received.
  • heaps of functionality trimmed due to incomplete implementation. eesh. the ideas were flowing like runaway trains...
  • hints implemented for all controls. if you want to know what something does, hover your mouse over the control and a little hint should pop up and tell you
  • state-driven controls. ie if due to current application / com port state, it does not make sense to click a button, said button should be disabled. eg: you are not connected to a com port, so the reset buttons are disabled. No doubt someone will find an exception(s) to the rule. Just let me know if it glares at you in its lack of logic. :smiley:
  • toggle automatic raw output: it will keep arriving but you can choose to not display it. refresh button allows you to update the raw output display
  • toggle auto scroll

Background
I dislike the Serial Monitor app that comes with Arduino IDE.
RealTerm is ugly as uglier than sin. Good grief.
Hyperterminal doesn't ship with Windows ... and if you get a hold of it. wtf?
Putty is ... dunno didn't even look. I mudded with it once, that was enough to put me off.

Anyway. I have been doing a lot of USB / serial port interfacing with external hardware using Delphi recently, so I thought I'd start writing my own serial monitor. As I have been climbing the Arduino development learning curve, I have found debugging to be a bit of a chore, so I thought I'd integrate a debugging library with the serial monitor also.

I apologise in advance for naming my software app, if you find that conceited. I can't help it.

I have it up and running, with some basic debugging library integration as well. Here's what it looks like running my latest sketch (I was holding the green button down when I took the snapshot):

Debugging library:
The DBG debugging library has been released. Full details and download links can be found here: [Update] dbg.h : debug library - Libraries - Arduino Forum

Comments / suggestions welcome.

Use references instead of pointers. Eliminates having to type all those ampersands.

Add support for the F-macro.

Nice. I like it.

Yes! I was looking at it last night, and thinking - man there must be a better way than having all those ampersands, what a PITA. I have been in mad professor mode for 2 weeks now, where it's safest to say - if it works, don't fix it. But definitely, will implement that first up.

I saw that F-macro code but that's what you mean, isn't it? Implement a macro based on it?

Thank you. C pointers have been kicking my ass since 1989, but for once I was pleased with what you can do with them.

aarondc:
I saw that F-macro code but that's what you mean, isn't it? Implement a macro based on it?

This...

addDebugVar("My string variable", &someString);

...becomes this...

addDebugVar( F( "My string variable" ), &someString);

Making the change reduces the amount of SRAM used to zero.

What you have shown is using the F-macro, not adding support for it. The user can do that when they use the library - I was thinking about how to implement it in the procedure calls automatically ("add support") :smiley:

aarondc:
What you have shown is using the F-macro, not adding support for it.

You, the library developer, have to add support for the F-macro or it will not work with your library.

The user can do that when they use the library...

Give it a try. Let me know how that turns out for you.

Ahh I see.

Thanks again!

Would you set it up to force them to reference the F macro, or provide F-macro enabled and non-F-macro enabled versions?

Or do an auto implementation like I want to do?

I see core file Print.cpp implements

    size_t print(const __FlashStringHelper *);
    size_t print(const String &);
    size_t print(const char[]);
    // etc

so I shall do the same.

aarondc:
Would you set it up to force them to reference the F macro, or provide F-macro enabled and non-F-macro enabled versions?

Second option. That makes it consistent with the Arduino API which makes it familiar to your users.

Or do an auto implementation like I want to do?

See above. It is possible the char const * signature is useful. Let your users decide.

Yeah the Print.cpp code I looked at convinced me it's the better option too.

You coded this in java? Looks neat. A lot of people isn't happy with the default one from Arduino IDE, maybe I can add this to my mod as an option. (I tried to add someway to debug things, but is very primitive, it just cleans the output so you see 1 screen of data refreshed). Arduino IDE just need to share the comport and bauds when opening the Monitor, and also be able to close it on demand but that's everything.

Also, the options for the serial port seem complex for a normal arduino user, maybe you can collapse them below the bauds (usually the only thing they need from arduino), so including the current collapsive panels I can see from the image, when everything is collapsed, the looks will be similar to the official one, but you can uncollapse the serial port list, serial port options, debug.

Thanks, eried.

It's written in Delphi. I hear you on the com port settings - have been thinking of rearranging a few things so I appreciate the feedback, I can definitely implement something similar to what you suggest.

No download? Bummer.

codlink:
No download? Bummer.

The app is still in development :slight_smile: I'll post a link once it's working (ie all the buttons do something).

It works much better with the debug library, which requires attention also, so delayed x 2.

Thanks for your interest.

If you need someone to test it, send me a PM. 8)

codlink:
If you need someone to test it, send me a PM. 8)

As soon as it's in a state of testability, I will do so. You're running Windows, I take it?

Windows 7 Ultimate x64 w/latest updates.

Still enhancing functionality in both the app and the library, writing things I need to work out wtf is going on with my own Arduino development...

Once it's all up and running, I'd like to run as complex a sketch as I can as an example of what the library + app can do.

Any suggestions on one of the more complex examples users can obtain from the Playground? Preferably a tutorial or similar that actually does something, that does not require esoteric hardware, with some functions and what not, rather than a library which are typically designed to be used more as black boxes?

Thanks.

After the flood of responses to my query, I have decided I will probably demo the debug library with this tutorial: Google Code Archive - Long-term storage for Google Code Project Hosting.