Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 17:04 11 May 2025 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : which terminal?

Author Message
BobDevries

Senior Member

Joined: 08/06/2011
Location: Australia
Posts: 266
Posted: 05:58pm 22 Jul 2014
Copy link to clipboard 
Print this post

Hi all,

I've looked through the manual (v4.5) but found no answer:

Is there currently a way for an MMBasic programme to know whether it is "talking" to a USB terminal (Tera Term) or the internal keyboard/display?

We currently have MM.DEVICE$, so maybe MM.TERMINAL could be added to return (say) 0 for internal or 1 for external?

Regards, Bob Devries
Dalby, QLD, Australia

Bob Devries
Dalby, QLD, Australia
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6220
Posted: 07:23pm 22 Jul 2014
Copy link to clipboard 
Print this post

You could monitor the USB 5V supply and if it is there, you are 'possibly' using the USB. If the 5V is not there, it is probably safe to say that you are using the on-board keyboard/VGA.

Jim
VK7JH
MMedit
 
BobDevries

Senior Member

Joined: 08/06/2011
Location: Australia
Posts: 266
Posted: 08:22pm 22 Jul 2014
Copy link to clipboard 
Print this post

Hi Jim,

Is it possible to monitor the USB supply without modifying the MM?
Sorry, I omitted to mention I'm using a Mono MM.

Regards, Bob Devries
Dalby, QLD, Australia

Bob Devries
Dalby, QLD, Australia
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6220
Posted: 08:56pm 22 Jul 2014
Copy link to clipboard 
Print this post

There should be a diode between the +5V pin on the USB connector and the input to the 3.3V regulator.
Put a resistor, about 1k, between the USB connector side of the diode and a spare input on the maximite. I would use a voltage divider if not using a 5V tolerant pin.

This will let you know when 5V is supplied via the USB but there is no easy way to know if you have your terminal program running.

Jim

VK7JH
MMedit
 
Print this page


To reply to this topic, you need to log in.

The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025