Community discussions

MikroTik App
 
hotspotsolutions
Member Candidate
Member Candidate
Topic Author
Posts: 119
Joined: Thu Dec 16, 2004 1:48 pm

Serial Connectiviting on a RB433

Thu Jan 14, 2010 2:25 am

Hi,

I want to connect a serial device to my RB433 board, to send/receive data.

I found an example somewhere that said to use:
/interface ppp-client add name="scripttemp" port=serial0 modem-init="test" null-modem=yes disabled=no
:delay 1
/interface ppp-client remove [/interface ppp-client find name="scripttemp"]
This doesnt seem to work, can I do this. Or can I receive only or send only? Can I use the port at all?
 
User avatar
sergejs
MikroTik Support
MikroTik Support
Posts: 6695
Joined: Thu Mar 31, 2005 3:33 pm
Location: Riga, Latvia
Contact:

Re: Serial Connectiviting on a RB433

Thu Jan 14, 2010 10:59 am

You need to disabled serial port in /system console. Then it should work.
 
hotspotsolutions
Member Candidate
Member Candidate
Topic Author
Posts: 119
Joined: Thu Dec 16, 2004 1:48 pm

Re: Serial Connectiviting on a RB433

Fri Jan 15, 2010 8:52 am

Hi,

I have done that but it still doesnt work?

The serial device does not get the data sent,. I assume its neither sending nor receiving.

Is the code I sent the right code? do I need to do anything else?
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: Serial Connectiviting on a RB433

Fri Jan 15, 2010 10:43 am

if you need to connect to serial port via RB - you may use 'special-login' feature: http://forum.mikrotik.com/viewtopic.php ... cial+login
 
hotspotsolutions
Member Candidate
Member Candidate
Topic Author
Posts: 119
Joined: Thu Dec 16, 2004 1:48 pm

Re: Serial Connectiviting on a RB433

Mon Jan 18, 2010 2:05 am

Hi,

Ok so I see the special-login, however that seems to me to be only usable when I winbox in right, then access the console.

Thats no good, I need a scripted solution.

I also saw "/system serial-terminal" and this works as well, but I cant script this either.

I need to be able to access the serial port via a script, can I do this? seems crazy that I cant?

My original post with the code is how I see it should be accessed, is this not the case?
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: Serial Connectiviting on a RB433

Mon Jan 18, 2010 1:43 pm

Ok so I see the special-login, however that seems to me to be only usable when I winbox in right, then access the console.

Thats no good, I need a scripted solution.
well, you may use Telnet. or even SSH - then you don't even need to enter login/password in interactive prompt
 
hotspotsolutions
Member Candidate
Member Candidate
Topic Author
Posts: 119
Joined: Thu Dec 16, 2004 1:48 pm

Re: Serial Connectiviting on a RB433

Tue Jan 19, 2010 3:00 am

I NEED TO USE SERIAL.

I cannot use any other method.

MIKROTIK: is this possible or not?
 
User avatar
Joako
just joined
Posts: 2
Joined: Tue Jan 19, 2010 7:15 am
Location: Capital Federal, Argentina

Re: Serial Connectiviting on a RB433

Tue Jan 19, 2010 7:47 am

I NEED TO USE SERIAL.

I cannot use any other method.

MIKROTIK: is this possible or not?

Capital letters mean shouting, and on some occasions a lack of
interest in the responses of members of the forum.
Be friendly, creating a better environment
 
hotspotsolutions
Member Candidate
Member Candidate
Topic Author
Posts: 119
Joined: Thu Dec 16, 2004 1:48 pm

Re: Serial Connectiviting on a RB433

Tue Jan 19, 2010 8:32 am

I know what capital letters mean.

My request is specific, perhaps it was not clear enough, clearly now it is.

Capital letters help get the point across, interpret it how you want.
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: Serial Connectiviting on a RB433

Tue Jan 19, 2010 4:03 pm

no, you cannot initiate any connections from RouterOS, either telnet/ssh, or serial, and fully control it. the only solution is 'special-login' feature, which can be easily scripted. why do you think I mentioned it? ;)

p.s. don't worry, be happy =)
 
hotspotsolutions
Member Candidate
Member Candidate
Topic Author
Posts: 119
Joined: Thu Dec 16, 2004 1:48 pm

Re: Serial Connectiviting on a RB433

Wed Jan 20, 2010 1:20 am

Hi,

I tried the special login, but i'm either doing something wrong or it doesnt suit my needs.

Let me be a little more specific:

I have a serial device which has two modes:
1.) The serial device will send data down serial port every few mins, and I need to respond to it with a character/s
2.) I can connect directly to the serial device and send data, every few mins

Both of the above scenarios need to be scripted, so that I can do this at regular intervals via scheduler.

Special login as far as I can tell only works when I do this manually, is this correct?
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: Serial Connectiviting on a RB433

Wed Jan 20, 2010 2:31 am

you cannot do it from RouterOS - you need another machine to do the work. this machine will connect to the router, login with 'special' login - and it will be directly connected to the serial port. all you send to the terminal will be sent to COM port, and all received on the COM port will be sent to your terminal connection
 
hotspotsolutions
Member Candidate
Member Candidate
Topic Author
Posts: 119
Joined: Thu Dec 16, 2004 1:48 pm

Re: Serial Connectiviting on a RB433

Wed Jan 20, 2010 3:04 am

hi,

thanks for the confirmation, (that I didn't want)

Seems pretty pointless having a serial port if I cant use it, very disappointing.

I have used the method mentioned in my first post to send data, but its my understanding I cant receive anything back, which is also disappointing.

Seems a waste of money investing in a device that can achieve proper serial connectivity when the mikrotik boards have serial ports, but are essentially useless unless you want to control a UPS.

anyway, thanks for your help.
 
User avatar
Chupaka
Forum Guru
Forum Guru
Posts: 8709
Joined: Mon Jun 19, 2006 11:15 pm
Location: Minsk, Belarus
Contact:

Re: Serial Connectiviting on a RB433

Fri Jan 22, 2010 2:06 pm

it may be strange, but 'special-login' works fine for similar tasks =)

Who is online

Users browsing this forum: fadelliz78, ianjay06, pajapatak, rudivd and 108 guests