It is currently Mon May 20, 2013 12:17 am

All times are UTC




Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: [SOLVED] IDE 'motor' : how to enable tty for debug mode?
PostPosted: Sat Aug 04, 2007 3:56 pm 
Regular Zenwalker
Regular Zenwalker

Joined: Sat Jan 06, 2007 11:58 am
Posts: 10
Location: Germany-Stuttgart
Hi There,

(I accidently posted in a wrong forum; I hope this one is the correct one....)

as usual I am trying things, but those not going to work.  H!!!

This time i try to start the debugging mode in the IDE 'motor'. When I press F12 for debugging, it tells me there is no free TTY found, which is needed for debugging.

The author writes on his web page:
Quote:
Motor can only debug programs in local console. That means that you
need to sit in front of your Linux/FreeBSD/whatever box and work on a
local tty. One of those you usually switch with Alt-F1..F12 :) Also
you should have a place to run a debug session, a free tty, Just like
X-Windows needs a free tty to start X display.


The link for this program: http://www.freeos.com/articles/3062/

How I should proceed?
The folder /dev/ lists a tons of ttys. Whenever I open a term, then the command 'tty' outputs incrementing terminals, e.g.: '/dev/pts/0'. The next term outputs: '/dev/pts/1'.  So this mechanism works.  ??

How I can provide such needed tty to motor?

On the web I found a tutorial how to split tty regarding the debugger gdb.
But I don't think that it should be so complicated.

In the source code of the ide, the author opens /dev/tty for reading; and later for write access. In that fopen-command the error occurs.



Is there something related to export tty=something ?

Or can anybody explain me how the linkage between a editor and gdb works?

Hope somebody can help me.
Thank you and best regards,
Denis


Last edited by dekobas on Sat Aug 04, 2007 7:23 pm, edited 1 time in total.

 Profile Send private message  
 
 Post subject: Re: IDE 'motor' : how to enable tty for debug mode?
PostPosted: Sat Aug 04, 2007 4:05 pm 
Experienced Zenwalker
Experienced Zenwalker
User avatar

Joined: Sat Mar 11, 2006 2:53 pm
Posts: 208
Location: Estonia
Edit you /etc/inittab:
Code:
c1:1235:respawn:/sbin/agetty 38400 tty1 linux
c2:12345:respawn:/sbin/agetty 38400 tty2 linux
c3:12345:respawn:/sbin/agetty 38400 tty3 linux
c4:12345:respawn:/sbin/agetty 38400 tty4 linux
c5:12345:respawn:/sbin/agetty 38400 tty5 linux
c6:12345:respawn:/sbin/agetty 38400 tty6 linux
c12:12345:respawn:sbin/agetty 38400 tty12 linux #<------add this line


 Profile Send private message  
 
 Post subject: Re: IDE 'motor' : how to enable tty for debug mode?
PostPosted: Sat Aug 04, 2007 4:17 pm 
Regular Zenwalker
Regular Zenwalker

Joined: Sat Jan 06, 2007 11:58 am
Posts: 10
Location: Germany-Stuttgart
Hi, thank you for fast response.
Quote:
c12:12345:respawn:sbin/agetty 38400 tty12 linux #<------add this line

I added that line and rebooted. With CTRL-ALT+F12 I can jump to the console 12 and login.
But the IDE on X in a term, still tells: no free tty found.
In /dev/pts/...  the 12th console does not appear, even I am logged in there.
Any additional hints?
thank you


 Profile Send private message  
 
 Post subject: Re: IDE 'motor' : how to enable tty for debug mode?
PostPosted: Sat Aug 04, 2007 4:54 pm 
Experienced Zenwalker
Experienced Zenwalker
User avatar

Joined: Sat Mar 11, 2006 2:53 pm
Posts: 208
Location: Estonia
Cannot help with that.... >:(


 Profile Send private message  
 
 Post subject: DONE ! Re: IDE 'motor' : how to enable tty for debug mode?
PostPosted: Sat Aug 04, 2007 7:19 pm 
Regular Zenwalker
Regular Zenwalker

Joined: Sat Jan 06, 2007 11:58 am
Posts: 10
Location: Germany-Stuttgart
I am stoopid.
Simply:  man motor.....
and then it is listed how to do it.....

1. Open xterm in which motor will be running
2. Open additional xterm in which debugging output will take place
3.  tty  --> gives you the current tty of that xterm; e.g. /dev/pts/2
4. run in first xterm:  motor -t /dev/pts/2
--> voila

Same behaviour like gdb -t .

\!D/


 Profile Send private message  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC


 Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
 
cron