Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 11:12 01 Aug 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 : Micromite/Explore28 comms question

Author Message
BrianP
Senior Member

Joined: 30/03/2017
Location: Australia
Posts: 292
Posted: 10:41pm 05 Jul 2017
Copy link to clipboard 
Print this post

Hi all

The more I read the manual the more confused I get... (know the feeling?) (Brain now overloaded & shut down)

Regarding using the default console/com1 port on an Explore-28:

According to the manual, com1 is reserved for console & therefore is not available to MMbasic.

BUT

In Appendix A (Serial Comms) the examples given use com1 (just an example - can't use??).

The relevance is that I want to use serial comms in both program/edit mode (basic not running) & also for 2-way data transfer (within MMbasic) over a single serial link. I gather then that this perhaps cannot be done?

I was hoping that I could:
1. Within MMbasic send & receive data via Teraterm.
2. Ctrl-C interrupt the running program for editing / program upload use over the same serial link.

Can this be made to work?

Any suggestions / solutions very welcome.

(I don't yet have my Explore-28 - 'tis paid for & coming... thanks Grogs ).

Regards to all

Brian P.
 
OA47

Guru

Joined: 11/04/2012
Location: Australia
Posts: 986
Posted: 11:04pm 05 Jul 2017
Copy link to clipboard 
Print this post

Brian, the 28 pin chip has 3 serial ports:
Console serial port. Pins 11 & 12
Com1 serial port. Pins 21 & 22
Com2 serial port. Pins 9 & 10

Graeme
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9610
Posted: 03:48pm 06 Jul 2017
Copy link to clipboard 
Print this post

As OA47 says, the console is totally separate from COM1 or COM2.

Using the USB connection, you can edit your programs, XMODEM or directly enter command at the console. The console pins are available on the pins of the E28, but it was envisaged that people would use the USB connection the most with this module, so that is the recommended console path for the E28.

The USB console is totally separate from COM1 and COM2, which are separate pins again along the edge of the E28 module.

You can, however, force-feed data into the console via the CONSOLE pins on the edge of the module, but those pins are designed more as a local monitor of the console so you can check something if you are fault-finding, and is not the recommended console path.

Robert Rozee might chime in here, as it is really his design, I just helped him design the PCB, but he would be able to better clarify exactly what the CONSOLE pins are on the E28, but I think I understand it right in what I stated above.

I hope to have more E28's by Monday, so your ones will be sent to you soon, with any luck.
Smoke makes things work. When the smoke gets out, it stops!
 
BrianP
Senior Member

Joined: 30/03/2017
Location: Australia
Posts: 292
Posted: 02:58pm 07 Jul 2017
Copy link to clipboard 
Print this post

Thanks guys

The issue is not the number of serial ports available - it's that we only have one external serial connection available.

What I am trying to work out is how I might be able to do data transfer when the Mite is running & console / programming work when at the command prompt, both over this single serial connection.

Looking for ideas / suggestions...

B
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6283
Posted: 03:19pm 07 Jul 2017
Copy link to clipboard 
Print this post

  BrianP said  
What I am trying to work out is how I might be able to do data transfer when the Mite is running & console / programming work when at the command prompt, both over this single serial connection.


That's what I do with a number of my setups.
In your program
PRINT "stuff"
will send "stuff" over the console
INPUT and INKEY both work over the console
If you use INPUT$(nbr, [#]fnbr), #0 refers to the console.

I use the console over TCPIP type links and by using console instead of com ports, I can update my programs remotely. You have to make sure that your 'in program' data link doesn't send a break signal to the 'mite.

Jim


VK7JH
MMedit
 
robert.rozee
Guru

Joined: 31/12/2012
Location: New Zealand
Posts: 2442
Posted: 03:46pm 07 Jul 2017
Copy link to clipboard 
Print this post

  BrianP said  The issue is not the number of serial ports available - it's that we only have one external serial connection available


i'm a little confused, there are 3 serial port connections available: the console, COM1, and COM2. on the E-28 the console is available over USB, while COM1 and COM2 are directly accessible.


cheers,
rob :-)
 
BrianP
Senior Member

Joined: 30/03/2017
Location: Australia
Posts: 292
Posted: 03:58pm 07 Jul 2017
Copy link to clipboard 
Print this post

Jim - I'll try that as soon as...

Rob - we only have one serial line available so I can only connect one com port.
There will no USB connection available, ie. no local connection, only remote.

Or am I missing something? (quite likely...)

B
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6283
Posted: 04:25pm 07 Jul 2017
Copy link to clipboard 
Print this post

If you don't have USB available, the Explore28 is not the best choice.
A standard micromite without the USB-TTL makes more sense.
If you are connecting to an RS232 port, you will probably need a TTL-RS232 converter to make things easier.

What sort of remote connection are you using?

Jim

VK7JH
MMedit
 
robert.rozee
Guru

Joined: 31/12/2012
Location: New Zealand
Posts: 2442
Posted: 05:04pm 07 Jul 2017
Copy link to clipboard 
Print this post

it sounds like a 28-pin SDIP MX170 would be preferable to an E-28 then, as you'd not be using the E-28's onboard USB (that draws around 10mA itself all the time).

what is the problem with routing all the communications through the console? i presume you're attached to a PC at the other end that is running some sort of custom application?


cheers,
rob :-)
 
BrianP
Senior Member

Joined: 30/03/2017
Location: Australia
Posts: 292
Posted: 05:23pm 07 Jul 2017
Copy link to clipboard 
Print this post

@TassyJim

I will be using the existing RS232 connection to an Internet connected Laptop using a USB converter & running Teraterm. This arrangement is already working on my developmental project for controlling the local hall door lock via keypad entry (colour Maximite), allowing remote control of the door lock & logging of use. The issue here is that there is no provision for program modification unless a local USB connection is made to the Maximite. Functionally,we need to maintain/update an array of current valid keypad entry codes which are likely to change at a moment's notice - this is currently working under program control.

As is normal the development project hardware is a major dog's breakfast. The permanent plan is to use the E28 on an breakout motherboard with RTC & RS232-TTL converter, 4x3 keypad connection & 12v-5v power reg. I want to be able to use the one serial connection for both data/running program control use as well as make any program changes that might be needed down the track. The E28 is being used because of its small footprint taking up minimal space on the breakout board, & it has more than enough space for the data array.

If com1 can be used for both console & data then that will fit the bill nicely.

Cheers

Brian P.
 
BrianP
Senior Member

Joined: 30/03/2017
Location: Australia
Posts: 292
Posted: 05:28pm 07 Jul 2017
Copy link to clipboard 
Print this post

Rob - no problem at all routing all comms through the console - I wasn't sure if this could in fact be made to work.

If it does, NO PROBLEM!

B
 
BrianP
Senior Member

Joined: 30/03/2017
Location: Australia
Posts: 292
Posted: 07:43pm 08 Jul 2017
Copy link to clipboard 
Print this post

1 more question - if using console with RS232 the comms will need to be inverted? (the book says INV only works with com1).

Ta

B
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6283
Posted: 09:20pm 08 Jul 2017
Copy link to clipboard 
Print this post

It is not something that I have tried but from the manual (page 15/16):
  Quote  OPTION CONSOLE INVERT which will invert the data on the transmit
and receive lines so that it can be used with RS232 devices.


My preference is for a USB-TTL converter or a MAX232 chip if the serial line is long.

Jim
VK7JH
MMedit
 
BrianP
Senior Member

Joined: 30/03/2017
Location: Australia
Posts: 292
Posted: 04:50pm 09 Jul 2017
Copy link to clipboard 
Print this post

Thanks Jim :)

B
 
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