linuxcncrsh invalid -i option

More
17 Feb 2016 18:21 #70298 by bkt
hi at all,

at the end of my hal file I write:
loadusr linuxcncrsh --port 5007 --name k1 --connectpw pw enablepw ena -ini /home/k1/folder/myini.ini

but when run linuxcncrsh with option in terminal like these:
linuxcncrsh --port 5007 --name k1 --connectpw pw enablepw ena -ini /home/k1/folder/myini.ini
it return the follow error:
linuxcncsrh -i invalid option
....... the ini file have the original pyvcp file and panel yet ..... and run on JA9 .... Lcnc2.7 ubuntu 10.04 ..... not understaND these error...


someone can help me to understand??

Please Log in or Create an account to join the conversation.

More
17 Feb 2016 18:38 - 17 Feb 2016 21:47 #70300 by dgarrett
You probably need to separate the LinuxCNC_Options with --

Example (using joints_axes11):
linuxcncrsh --port 5007 --name k1 --connectpw pw --enablepw ena -- -ini /home/k1/folder/myini.ini

Ref:
$ linuxcncrsh --help
Usage: 
         linuxcncrsh [Options] [-- LinuxCNC_Options]
Options:
         --help       this help
         --port       <port number>  (default=5007)
         --name       <server name>  (default=EMCNETSVR)
         --connectpw  <password>     (default=EMC)
         --enablepw   <password>     (default=EMCTOO)
         --sessions   <max sessions> (default=-1) (-1 ==> no limit) 
         --path       <path>         (default=../../nc_files/)
LinuxCNC_Options:
          -ini        <inifile>      (default=emc.ini)
Note:
The most recent joints_axes updates for linuxcncrsh (emcrsh.cc) are in the
branch joints_axes11. These updates support teleop (world) jogging

Ref:
git.linuxcnc.org/gitweb?p=linuxcnc.git;a...021650b24d4a67f0265e
Updating for joints_axes:
buildbot.linuxcnc.org/doc/scratch/v2.8.0...nc.html#_linuxcncrsh
Last edit: 17 Feb 2016 21:47 by dgarrett. Reason: fix example, was: enablepw ena, is: --enablepw ena
The following user(s) said Thank You: bkt

Please Log in or Create an account to join the conversation.

More
17 Feb 2016 19:12 - 17 Feb 2016 19:15 #70302 by bkt
Replied by bkt on topic linuxcncrsh invalid -i option

linuxcncrsh --port 5007 --name k1 --connectpw pw enablepw ena -- -ini /home/k1/folder/myini.ini


--connectpw pw enablepw ena -- -ini....... this is an error or is the correct structures?

1) linuxcncrsh --port 5007 --name k1 --connectpw pw enablepw ena -- -ini /home/k1/folder/myini.ini (<--- there is no error)
2)]linuxcncrsh --port 5007 --name k1 --connectpw pw --enablepw ena -- -ini /home/k1/folder/myini.ini ( <--- correct form)

i try JA11 today -- real tanks


An other question ..... I have a tkinker error too .... because toll changer window try to appear in any situation ..... on ini file on DISPLAY=linuxcncrsh ...... if cancell introtime and gif linuxcncrsh give me other error ...... so not change it.

Giorgio
Last edit: 17 Feb 2016 19:15 by bkt.

Please Log in or Create an account to join the conversation.

More
17 Feb 2016 21:59 #70315 by dgarrett
The correct form is:
linuxcncrsh --port 5007 --name k1 --connectpw pw --enablepw ena -- -ini /home/k1/folder/myini.ini

In my tests i find that this message:

linuxcncsrh -i invalid option

is an erroneous _warning_ (not an error) and can be ignored.
The warning is issued by the main linuxcnc script --
i will try to fix it later for the joints_axes branch.

An other question ..... I have a tkinker error too .... because toll changer window try to appear in any situation ..... on ini file on DISPLAY=linuxcncrsh ...... if cancell introtime and gif linuxcncrsh give me other error ...... so not change it.


Not sure what you are seeing since you did not post the text of the
error message(s).

However, note that if you connect to linuxcncrsh by telneting from another
machine you must have support for remote X display working in order
to use items like:
[HAL]
...
HALFILE = axis_manualtoolchange.hal
...

[DISPLAY]
...
INTRO_GRAPHIC = linuxcnc.gif
...

So -- it is appropriate to NOT use these items if you do not
have X enabled to the machine using telnet. Enabling X to the
machine using telnet is not specifically a LinuxCNC issue
but depends on the setup of both machines.

Please Log in or Create an account to join the conversation.

More
18 Feb 2016 08:06 #70335 by bkt
Replied by bkt on topic linuxcncrsh invalid -i option
sorry my redicolous error .... iI forgot to delete the toolchange lines hal file (loadusr -w tollchanger.......) the tkinker error is disappear...

linuxcncrsh --port 5007 --name k1 --connectpw pw --enablepw ena -- -ini /home/k1/folder/myini.ini


ok tanks but the warning is stable ..... today or tomorrow i Try JA11 ....

regards
giorgio

Please Log in or Create an account to join the conversation.

More
21 Feb 2016 12:37 #70428 by bkt
Replied by bkt on topic linuxcncrsh invalid -i option
Is possible to use linuxcncrsh with standard tcpi connection or with ssh connection??

How? where see the right command?

regards
Giorgio

Please Log in or Create an account to join the conversation.

More
21 Feb 2016 17:39 #70448 by dgarrett

Is possible to use linuxcncrsh with standard tcpi connection or with ssh connection?

Examples:

First, setup remote host
(name is: the_remote ==192.168.0.41 for my test),
and start LinuxCNC on the_remote using ini file with:
[DISPLAY]
DISPLAY = linuxncrsh
# defaults are port=5007, connectpw=EMC, enablepw=EMCTOO
# to customize, specify items, use:
# DISPLAY = linuxcncrsh --port NNNN --connectpw PW1 --enablepw PW2
...

Example session using telnet from client to the_remote
(with default linuxcncrsh port 5007)
$ telnet the_remote 5007
Trying 192.168.0.41...
Connected to the_remote.
Escape character is '^]'.
hello EMC myname 1.1
HELLO ACK EMCNETSVR 1.1
set enable EMCTOO
set enable EMCTOO
get enable
get enable
ENABLE ON

Example session using ssh from client to the_remote
(using port 9999 on localhost and linuxcncrsh default port 5007)
$ # set up port forwarding:
$ # -v for verbose
$ # -f for backgrounding
$ # -N for port forwarding
$ ssh -v -f dgarrett@the_remote -L 9999:localhost:5007 -N 
OpenSSH_6.7p1 Debian-5, OpenSSL 1.0.1k 8 Jan 2015
debug1: Reading configuration data /home/dgarrett/.ssh/config
debug1: /home/dgarrett/.ssh/config line 1: Applying options for *
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: Applying options for *
debug1: auto-mux: Trying existing master
debug1: Requesting forwarding of local forward LOCALHOST:9999 -> localhost:5007
debug1: mux_client_request_session: master session id: 19
$ #
$ # Now connect via localhost using localhost port 9999 forwarded to the_remote:5007
$ telnet localhost 9999
Trying ::1...
Connected to localhost.
Escape character is '^]'.
hello EMC me2 1.1
HELLO ACK EMCNETSVR 1.1
set enable EMCTOO
set enable EMCTOO
get enable
get enable
ENABLE ON
...
The following user(s) said Thank You: bkt

Please Log in or Create an account to join the conversation.

More
02 Mar 2016 21:18 #70931 by bkt
Replied by bkt on topic linuxcncrsh invalid -i option
I try to connect with qtcpsocket client..... but I've not clear the termination string...... is fifth to send for example...... "set estop on\\r\\n"???

Regards
Giorgio

Please Log in or Create an account to join the conversation.

More
03 Mar 2016 08:54 #70952 by ArcEye
I am sure it will be quite a simple protocol.

I can recommend Wireshark (used to be called Ethereal) as a packet sniffer.
Used it successfully in the past to reverse engineer an IPCam windoze only IE based interface, so that I could write a Linux Qt based one for it.

Or you may simply be able to connect using something like Cutecom instead of telnet and just switch the display to hex, to see the packet strings in full, including terminations.

regards
The following user(s) said Thank You: bkt

Please Log in or Create an account to join the conversation.

More
03 Mar 2016 10:08 - 03 Mar 2016 17:02 #70956 by bkt
Replied by bkt on topic linuxcncrsh invalid -i option
I saw all thanks .... but one thing take rather long to do .... I have to send all commands and get all the answers in order to make a " library" of commands and responses .... I do not think in facts there are many applicants sending and receiving packets ... later place an example for the get estop command ....

the schermata:




Acctually I use qprocess (not in these png file when I use terminal) and "tee" command for to have a clear response file where to read ....

if I can not understand (I not understand ... for shure ArkEye understand very well ... sorry for my first version of post) .... a simple trick to using and codify direct tcp connection (without having to re-implement again the telnet connection .... we would telnetlib or libtelnet for this ...) I can't delete qprocess and use only QTcpSocket ...

sorry for my english junk .... I do not mean to offend you .... i correct the last row of post ....

Regards
Giorgio
Attachments:
Last edit: 03 Mar 2016 17:02 by bkt.

Please Log in or Create an account to join the conversation.

Time to create page: 0.194 seconds
Powered by Kunena Forum