Problem with RIDE

APL-related discussions - a stream of APL consciousness.
Not sure where to start a discussion ? Here's the place to be
Forum rules
This forum is for discussing APL-related issues. If you think that the subject is off-topic, then the Chat forum is probably a better place for your thoughts !

Problem with RIDE

Postby ray on Mon Jan 30, 2017 12:37 am

Hi

I have encountered a minor problem using RIDE on my Windows 7 PC connecting to APL running on a Raspberry Pi.

On the Pi, APL is calling a function written in C and made available to APL via ⎕NA.
The C function outputs some debugging "text" to the screen via a "printf" statement. The text appears on the Raspberry Pi screen.

Unfortunately, the debugging "text" does not appear at all in the RIDE session.

Although the text appears on the Pi screen, it does not appear to be part of the session/session log, and a screen refresh <windows-L> removes it.

Is there any way that I can make the debugging text available to the RIDE session?
(Possibly via Pipes/stderr ???)

IDE:
Version: 3.0.1996
Platform: Win32
Date: 2016-11-01 14:14:30 +0000
Git commit: 6545091e25cf7d760b1677388b8542a2fa858256
User agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.76 Safari/537.36
Settings:{
"editorWidth":"916",
"favs":"[{\"name\":\"Pi2eye\",\"host\":\"192.168.0.18\",\"type\":\"connect\"},{\"name\":\"raspberrypi2\",\"host\":\"192.168.0.24\"}]",
"floatOnTop":"1",
"kbdLocale":"en_US",
"otherExe":"dyalog",
"pos":"[-9,-9,1938,1064,1]",
"posEditor":"[793,0,1084,1046]",
"posTracer":"[2155,236,1597,667]",
"theme":"classic",
"title":"{WSID}{PID}{HOST}",
"tracerHeight":"257",
"wse":"1"
}

Interpreter:
Version: 15.0.29007
Platform: Linux
Edition: Unicode/32
Date: Created: Jan 17 2017 at 00:52:39


Thanks
Ray Cannon
Please excuse any smelling pisstakes.
User avatar
ray
 
Posts: 221
Joined: Wed Feb 24, 2010 12:24 am
Location: Blackwater, Camberley. UK

Re: Problem with RIDE

Postby AndyS|Dyalog on Tue Jan 31, 2017 9:40 am

I'm afraid that that's not possible .. that output doesn't come from the interpreter, so cannot be captured by RIDE .. and it's why when you use a tty interface a screen refresh clears it.

I think that the best you can do is to alter your code so that rather than using printf() you use fprintf() having opened a file (in append mode) to write the debug info to. Then either open a terminal/ssh window onto the machine and run tail -f on the file, or run your code, and then from within RIDE read the contents of the file using ⎕SH'cat file' or ⎕nget file.
User avatar
AndyS|Dyalog
 
Posts: 257
Joined: Tue May 12, 2009 6:06 pm

Re: Problem with RIDE

Postby ray on Tue Jan 31, 2017 3:10 pm

Thanks Andy, I feared as much.

Unfortunately, a lot of code I access via ⎕NA is not under my control so I don't have the option to use fptintf() in place of printf().

I am already using fprintf() to write out I2C data (compass bearings) on a continuous basis, and read snapshots of it in APL via ⎕map.

So I will continue to run Dyalog APL directly on the Raspberry Pi with a screen connected, so I can see the printf() debugging output, but control the APL session via RIDE, running under Windows.

Thanks.
Ray Cannon
Please excuse any smelling pisstakes.
User avatar
ray
 
Posts: 221
Joined: Wed Feb 24, 2010 12:24 am
Location: Blackwater, Camberley. UK

Re: Problem with RIDE

Postby ray on Tue Jan 31, 2017 3:41 pm

On a different RIDE point, I notice that when debugging, the "Trace Tools" menu bar (Exec, Trace, Back, Fwd, Restart, Restart all threads, Edit, Exit, Intr, and Reset) under RIDE, the Exit button (X) is missing. (Actually I always regarded it as a "cut back" button rather than "Exit".)

The (Windows)"Exit" button is described as "Close the Trace window and exit the current function".

The RIDE "X" on the line above is marked "Save and Close", which I do not think is the same, one cuts back the stack, while the other does not. (Or am I mistaken/confused?)

Is there a good reason for there being no "Exit"(cut back) button in RIDE? I miss it!

Ray
Ray Cannon
Please excuse any smelling pisstakes.
User avatar
ray
 
Posts: 221
Joined: Wed Feb 24, 2010 12:24 am
Location: Blackwater, Camberley. UK

Re: Problem with RIDE

Postby Vince|Dyalog on Wed Jun 07, 2017 10:59 am

Hi Ray,

I am sorry that we have not replied to your last post in this thread.

About the X button on the trace tools bar: we do not intend to make the RIDE exactly the same as the current Dyalog for Windows IDE, so we will not be adding that.

RIDE tabs and windows have X buttons as well.

I think that these buttons also "cut back" as you mention.

Regards,

Vince
Vince|Dyalog
 
Posts: 412
Joined: Wed Oct 01, 2008 9:39 am


Return to APL Chat

Who is online

Users browsing this forum: No registered users and 1 guest