meta data for this page
Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
ssotc_2011:grp4:start [2011/08/19 11:09] grp4 [Conclusion] |
ssotc_2011:grp4:start [2011/08/19 12:47] grp4 [Code] |
||
---|---|---|---|
Line 7: | Line 7: | ||
Using phone as hearing aid for old people (and not so old). Using phone' | Using phone as hearing aid for old people (and not so old). Using phone' | ||
- | ===== Screenshots ===== | ||
- | None yet | + | ===== Result ===== |
+ | |||
+ | We managed to do application which uses Gstreamer to stream straight from mic to ear plugs. It has also a compressor to make audio audible. Problem is just that volume or compressor is not controllable. Whole code would be needed to be rearranged to get buttons and knobs to do some thing. Propaply using gstreamers commandline version but that's other story | ||
+ | ===== Screenshots ===== | ||
+ | {{: | ||
===== Code ===== | ===== Code ===== | ||
Line 79: | Line 82: | ||
""" | """ | ||
@attention: this is important it initializes softfare playtrought (audioconvert is not nesesity) | @attention: this is important it initializes softfare playtrought (audioconvert is not nesesity) | ||
- | @summary: takes stream from mic to autosink | + | @summary: takes stream from mic to autosink |
""" | """ | ||
self.pipeline = gst.parse_launch(""" | self.pipeline = gst.parse_launch(""" | ||
Line 115: | Line 118: | ||
| | ||
self.audiosink = gst.element_factory_make(" | self.audiosink = gst.element_factory_make(" | ||
+ | """ | ||
+ | @attention: intance of record class is created here and gstreamer started. | ||
+ | """ | ||
self.recorder=Record(self.audiosink) | self.recorder=Record(self.audiosink) | ||
""" | """ | ||
Line 157: | Line 163: | ||
class MeHear(hildon.Program): | class MeHear(hildon.Program): | ||
def __init__(self): | def __init__(self): | ||
+ | """ | ||
+ | @summary: creates an intance of pleyer class and that why starts also gsteamer | ||
+ | """ | ||
self.pl= player() | self.pl= player() | ||
- | # def record_button_clicked(self, | + | |
- | # buttontext = button.get_label() | + | |
- | # text = buttontext | + | |
- | # if text == " | + | |
- | # label.set_text(text+" | + | |
- | # button.set_label(" | + | |
- | # print " | + | |
- | # | + | |
- | # if text == " | + | |
- | # button.set_label(" | + | |
- | # print "Stop button pressed" | + | |
def addvol_button_clicked(self, | def addvol_button_clicked(self, | ||
+ | #this changes the value of adjustment and thats why changes also progress bars value as it is linked to adjesment | ||
a=self.adjus.get_value() | a=self.adjus.get_value() | ||
self.adjus.set_value(a+10) | self.adjus.set_value(a+10) | ||
Line 176: | Line 177: | ||
print " | print " | ||
| | ||
- | |||
- | | ||
def decvol_button_clicked(self, | def decvol_button_clicked(self, | ||
+ | #this changes the value of adjustment and thats why changes also progress bars value as it is linked to adjesment | ||
a=self.adjus.get_value() | a=self.adjus.get_value() | ||
self.adjus.set_value(a-10) | self.adjus.set_value(a-10) | ||
Line 230: | Line 230: | ||
buttonGTK = gtk.ToggleButton(" | buttonGTK = gtk.ToggleButton(" | ||
buttonGTK.connect(" | buttonGTK.connect(" | ||
- | |||
- | |||
- | |||
- | | ||
- | #this changes the value of progres bar | ||
- | # | ||
- | |||
- | | ||
- | | ||
- | | ||
- | #a= gtk.CheckButton(" | ||
- | # | ||
- | | ||
- | #b= gtk.ToggleButton(" | ||
- | # | ||
- | | ||
- | #c = gtk.RadioButton(None, | ||
- | # | ||
- | | ||
- | #adjus = gtk.Adjustment(value=60, | ||
- | #d = gtk.SpinButton(adjustment= adjus, climb_rate=0.1, | ||
- | # | ||
- | #hscrollbar = gtk.HSscrollbar(adjustment) | ||
| | ||
self.ratiotext= gtk.Label(" | self.ratiotext= gtk.Label(" | ||
Line 268: | Line 245: | ||
| | ||
self.volumetext= gtk.Label(" | self.volumetext= gtk.Label(" | ||
- | # Create a centering alignment object | ||
- | #align = gtk.Alignment(0.5 ,0.5, 0, 0) | ||
- | # | ||
- | # | ||
- | # | ||
- | # | ||
hbox3.pack_start(self.ratiotext, | hbox3.pack_start(self.ratiotext, | ||
hbox3.pack_start(combo, | hbox3.pack_start(combo, | ||
Line 298: | Line 269: | ||
| | ||
| | ||
- | if __name__ == " | + | if __name__ == " |
- | | + | |
app = MeHear() | app = MeHear() | ||
app.main() | app.main() | ||
+ | #EOF | ||
</ | </ | ||
- | + | Uncleaned | |
- | Upload and attach your project **source | + | {{: |
- | * Clean up compiled binary files before making package | + | |
- | * Use .zip format | + | |
| | ||
+ | ===== Presentation===== | ||
+ | |||
+ | {{: | ||
+ | |||
===== Conclusion ===== | ===== Conclusion ===== | ||
- | Developing in Maemo environment was challenging, | + | Hilmi:Developing in Maemo environment was challenging, |
+ | Esa-Petri: Coding to maemo was nightmare as libraries aren't well ported like Gstreamer Pygtk and so on. Also software restrictions make coding awful. But learning to use gstreamer and Pygtk was good experience. I just would not want to have maemo ever. | ||
+ | Trip to Riuttasaari was a really good experience and should be made as tradition. Overall good experience | ||