![]() |
2010-06-30
, 10:51
|
Posts: 83 |
Thanked: 130 times |
Joined on Dec 2009
|
#22
|
![]() |
2010-06-30
, 20:03
|
Posts: 53 |
Thanked: 20 times |
Joined on Feb 2010
|
#23
|
![]() |
2010-06-30
, 21:10
|
Posts: 1,224 |
Thanked: 1,763 times |
Joined on Jul 2007
|
#24
|
I think we are all stuck on the fact that when the 'phone' is active (i.e ongoing phonecall)
the vibrator won't function, it seems as if it is disabled, and enabling it with dbus during call does not work...
the code i posted can be run with python on the phone, but will only vibrate the phone when the call is ended, not when the call is started...
The Following User Says Thank You to Matan For This Useful Post: | ||
![]() |
2010-07-07
, 18:11
|
Posts: 44 |
Thanked: 28 times |
Joined on Mar 2010
|
#25
|
![]() |
2010-07-08
, 15:57
|
|
Posts: 4,365 |
Thanked: 2,467 times |
Joined on Jan 2010
@ Australia Mate
|
#26
|
![]() |
2010-07-08
, 16:42
|
Posts: 44 |
Thanked: 28 times |
Joined on Mar 2010
|
#27
|
![]() |
2010-07-09
, 02:53
|
|
Posts: 4,365 |
Thanked: 2,467 times |
Joined on Jan 2010
@ Australia Mate
|
#28
|
![]() |
2010-07-09
, 03:53
|
Posts: 24 |
Thanked: 10 times |
Joined on Jun 2010
|
#29
|
#! /usr/bin/env python2.5 # -*- coding: utf-8 -*- import pygtk import gtk from gtk import Window, Button, Widget import hildon import time import os import gobject, dbus from dbus.mainloop.glib import DBusGMainLoop vibrator=0 def connect_call(message, actor, memberids): #print 'message = %s' % message #print '\n actor = %s' % actor #print '\n memberids = %s' % memberids global vibrator if actor==1 and message==0: vibrator=1 return if actor==1 and message==1 and vibrator==1: os.system('echo 100 > /sys/class/leds/twl4030\:vibrator/brightness') time.sleep(1) os.system('echo 0 > /sys/class/leds/twl4030\:vibrator/brightness') vibrator=0 return DBusGMainLoop(set_as_default=True) bus = dbus.SystemBus() bus.add_signal_receiver(connect_call, path='/com/nokia/csd/call/1', dbus_interface='com.nokia.csd.Call.Instance', signal_name='AudioConnect') gobject.MainLoop().run() if __name__ == '__main__': gtk.main()
sudo gainroot cd /sys/class/leds/twl4030\:vibrator chmod 666 brightness
The Following User Says Thank You to colakang For This Useful Post: | ||
![]() |
2010-07-09
, 04:22
|
|
Posts: 4,365 |
Thanked: 2,467 times |
Joined on Jan 2010
@ Australia Mate
|
#30
|
the vibrator won't function, it seems as if it is disabled, and enabling it with dbus during call does not work...
the code i posted can be run with python on the phone, but will only vibrate the phone when the call is ended, not when the call is started...