Notices


Reply
Thread Tools
Posts: 56 | Thanked: 11 times | Joined on Jan 2010
#31
Originally Posted by digitalvoid View Post
@ AlexV12:

Sorry for that, must indeed be apt-get install ...
and one install of pexpect is enough . I corrected my first post...

Are the two scripts in /usr/bin and have the right permissions?
And did you install the Python packages?


"...
it is a nice idea though to trigger that via sms, but you'd have to be sure that the thief still has your simcard in the phone, otherwise it won't work"

--> smscon detects a SIM change at boot and then sends you the new provider name, new IMSI and new phonenumber. With this number you can SMS & control your phone again.
any python package in specific? i've only installed the packages that you named in your first post. are there any other packages (maybe from the application manager) i need installed?

also i typed in the code:
Code:
root
cd usr/bin
chmod 755 smscon
chmod 755 smscon_daemon
however i don't get any response (as in 50% done or what so ever.) it just starts a new line saying:
Code:
Nokia-N900:/usr/bin#
which i think is ok, because it doesn't give an error, which normally means succes.
 
Posts: 200 | Thanked: 300 times | Joined on Nov 2009 @ The Netherlands
#32
Can you show me all the errors you getting from starting smscon?
 
Posts: 56 | Thanked: 11 times | Joined on Jan 2010
#33









Last edited by AlexV12; 2010-08-24 at 12:43.
 
Posts: 200 | Thanked: 300 times | Joined on Nov 2009 @ The Netherlands
#34
It looks like maybe Python isn't installed on your device...

In X Terminal, if you do this:

Code:
Nokia-N900:~# python


you should get this:

Code:
Nokia-N900:~# python
Python 2.5.4 (r254:67916, May 17 2010, 21:00:32)
[GCC 4.2.1] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>


Use Ctrl + D to quit Python.
 
Posts: 56 | Thanked: 11 times | Joined on Jan 2010
#35
Originally Posted by digitalvoid View Post

Code:
Nokia-N900:~# python
Python 2.5.4 (r254:67916, May 17 2010, 21:00:32)
[GCC 4.2.1] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>>


Use Ctrl + D to quit Python.
i get this code perfectly!, same date, time etc, so same version i guess
 
Posts: 62 | Thanked: 6 times | Joined on Jun 2010 @ Poland
#36
Do you edit this files on windows notepad? This is a fcking app.- it change a file, that n900 can't read it.
Try apt-get install nano
cd folder
nano smscon
And that try to edit.

To author this app:
It is possible to give o this app email function?
Photos can be easy send to email server.

Can anyone show me how to for example configure a server for smscon?? What i must write here

Code:
RemoteHost                   = 'ftp.60free.ovh.org'                         # remote server address
RemotePort                   = 22                                           # remote server port
RemotePath                   = '/XXXXXXXXXXXX'                              # remote server ftp path
RemoteUser                   = 'XXXXXXXXXXXXX'                              # remote user
RemotePassword
__________________
Maemo Meego Maego!

Last edited by knypek3; 2010-08-24 at 19:30.
 
Posts: 56 | Thanked: 11 times | Joined on Jan 2010
#37
either edit it with notepad on your pc, or open the file in "notes" on your n900 and edit the file there.
 
Posts: 200 | Thanked: 300 times | Joined on Nov 2009 @ The Netherlands
#38
Originally Posted by knypek3 View Post
Do you edit this files on windows notepad? This is a fcking app.- it change a file, that n900 can't read it.
Try apt-get install nano
cd folder
nano smscon
And that try to edit.

To author this app:
It is possible to give o this app email function?
Photos can be easy send to email server.

Can anyone show me how to for example configure a server for smscon?? What i must write here

Code:
RemoteHost = 'ftp.60free.ovh.org'   # remote server address
RemotePort = 22   # remote server port
RemotePath = '/XXXXXXXXXXXX'  # remote server ftp path
RemoteUser = 'XXXXXXXXXXXXX'   # remote user
RemotePassword = 'XXXXXXXXXXXXX' # remote password
RemoteHost is the name of your server address (example: myserver.com)
RemotePort is the port on your server for the ssh connection (normally this is port 22). Your server must have a running ssh server.
RemotePath is the path to connect to on your server for ftp. (example: /ftp/nokia). (ftp uses port 21 for connection)
RemoteUser is the username for the ssh connection & ftp access.
RemotePassword is the password for the RemoteUser for the ssh connection & ftp access.

I have a home server with a fixed IP adddress (and a website) so I can configure it all very easely. It's very funny to ssh your phone through GPRS connection from your home (it's not super fast but it works ok).

I will look into making smscon also have a email function.
I'm currently rewriting parts of smscon & smscon_daemon (code cleanup, using a settings file (smscon_config) instead of editing smscon_daemon.

Last edited by digitalvoid; 2010-08-25 at 08:36. Reason: typo
 

The Following User Says Thank You to digitalvoid For This Useful Post:
Posts: 62 | Thanked: 6 times | Joined on Jun 2010 @ Poland
#39
hmn it's strange.
Why you using ssh?
I test this but in log write:
searching "ftp.60free.ovh.org"
failed to find "ftp.60free.ovh.org" (max retries reached)

But when i manualy try ncftpput -V -E -u user -p pass -P 21 ftp.60free.ovh.org / file
it send successfully the file.
So for what is the ssh necessary??

If i delete all ssh (ssh start, stop, status) and leave only function ncftpput it will work?

Edit:
I think it can't connect becouse in
def StatusRemoteHost():
p = urlparse('http://' + RemoteHost)
h = HTTP(p[1])
Have a http prefix.
I have only ftp.

Can anyone help?
__________________
Maemo Meego Maego!

Last edited by knypek3; 2010-08-25 at 11:50.
 
Posts: 200 | Thanked: 300 times | Joined on Nov 2009 @ The Netherlands
#40
Ssh (it's technically a reverse ssh connection) is only needed if you want to control you device (command 'Remote on' & 'Remote off').

Ftp is used for sending the frontcam photo to you own ftp server (command 'Camera').

I check if the connection is active (before ftping) by checking if my website can be reached. Why? I could use a simple ping to my IP address (server), but the ping is not always passed through GPRS or LAN networks with a strict firewall. Port 80 (website) is always passed, so smscon only works if a website is available on the server to connect to. I will look in to it; maybe I change this to a ping again with a fallback to website checking.

Does anybody know how I can compose & send a email by cli.
Python smtplib doesn't work either.
 
Reply


 
Forum Jump


All times are GMT. The time now is 15:37.