Go to advanced search

by hzhwang
Thu Jul 04, 2013 4:44 pm
Forum: Python
Topic: Question about driving 128x64 Graphic LCD
Replies: 18
Views: 21503

Re: Question about driving 128x64 Graphic LCD

Hi, I think it world be a indent problem useDisp1 's indent should be the same def __init__, useDisp2, lcd_byte .. roughly code: class LCD_GPIO def __init__ ... : def useDisp1(self): : def useDisp2(self): : def lcd_byte(self,value, mode): : Hi there, I am currently trying to interface to a similar L...
by hzhwang
Mon Jun 03, 2013 10:35 pm
Forum: Troubleshooting
Topic: Raspberry Pi Camera Module Causes Reboot
Replies: 28
Views: 14239

Re: Raspberry Pi Camera Module Causes Reboot

Hi all, I have same problem before. I modified current_limit_override in /boot/config.txt but no luck. I tested several USB port power supply (Raspberry Pi Model B Rev 2.0)(000f) 5V 1A (1000mA) USB port power supply (iPodTouch / iPhone4s) → reboot 5V 2A (2000mA) USB port power supply (iPad2) → reboo...
by hzhwang
Thu Jan 24, 2013 11:39 pm
Forum: Python
Topic: Random noise on button
Replies: 13
Views: 2491

Re: Random noise on button

Hi,

I have similar problem before. I use resistor but no luck.
After I modify my code
GPIO.setup(buttonPin, GPIO.IN)
to

Code: Select all

GPIO.setup(buttonPin, GPIO.IN, pull_up_down=GPIO.PUD_DOWN)
It works fine. ;)

Hope it helps.
by hzhwang
Wed Jan 23, 2013 10:20 am
Forum: 日本語
Topic: 128x64 LCDモジュールを動かしてみた
Replies: 2
Views: 4953

128x64 LCDモジュールを動かしてみた

LMG-SSC12A64 LCDモジュール(コントローラICはHD61202かKS0108らしい)を動かしてみました。

Image

ピン数はぎりぎりです(電源、バックライトを除いて14ピン要ります)、どうやって減らせるかに悩んでいます。

日本語/漢字を表示のついても調べてみました、「美咲フォント」という 8×8 ドットの日本語ビットマップフォントはバッチリです。

頑張ります :3
by hzhwang
Wed Jan 23, 2013 8:18 am
Forum: Python
Topic: Question about driving 128x64 Graphic LCD
Replies: 18
Views: 21503

Re: Question about driving 128x64 Graphic LCD

Code is quite messy, and it need LCD module's user manual to understand how/why it works... I use LMG-SS12A64 LCD module, it seems using HD61203 or KS0108 Controller IC #!/usr/bin/python # -*- coding: utf-8 -*- import time import RPi.GPIO as GPIO class LCD_GPIO(object): # Timing constants E_PULSE = ...
by hzhwang
Wed Jan 23, 2013 6:15 am
Forum: Python
Topic: Question about driving 128x64 Graphic LCD
Replies: 18
Views: 21503

Re: Question about driving 128x64 Graphic LCD

Before writing next display data, let it waiting until BUSY signal is off. def lcd_byte(self,value, mode): GPIO.output(self.RW,0) GPIO.output(self.RS,mode) GPIO.output(self.D0, (value) & 0x01) GPIO.output(self.D1, (value) & 0x02) GPIO.output(self.D2, (value) & 0x04) GPIO.output(self.D3, (value) & 0x...
by hzhwang
Tue Jan 22, 2013 1:07 pm
Forum: Python
Topic: Question about driving 128x64 Graphic LCD
Replies: 18
Views: 21503

Re: Question about driving 128x64 Graphic LCD

texy wrote:There are quite a few different driver chips used with these displays, which type does yours use - ST7565, ST7920 ?

T.
Thanks for reply

A little hard to tell...This LCD Module "LMG-SSC12A64 " user manual only said Controller IC x2 (KS0108 OR HD61202), not sure what is uses...
by hzhwang
Tue Jan 22, 2013 12:04 pm
Forum: Python
Topic: Question about driving 128x64 Graphic LCD
Replies: 18
Views: 21503

Question about driving 128x64 Graphic LCD

Hi everyone, I am trying making 128x64 Graphic LCD works with Raspberry Pi. It almost done but I have problem on write operation's timing control. # Timing constants E_PULSE = 0.000000140 # Addess setup time 140ns E_DELAY = 0.000000200 # Data setup time 200ns def lcd_byte(self,value, mode): GPIO.out...
by hzhwang
Mon Jan 07, 2013 10:39 pm
Forum: General programming discussion
Topic: Question about autostart program in LXDE
Replies: 8
Views: 17302

Re: Question about autostart program in LXDE

Hi thanks for the suggestions, I tried it today :- firstly I could not find the appropiate folder "~/.config/lxsession/ LXDE /autostart", so after reviewing the link I put my autostart file in the /usr/share/lxsession and created a new folder LXDE - no joy The contents of my autostart file was " su...
by hzhwang
Fri Jan 04, 2013 10:36 pm
Forum: General programming discussion
Topic: Question about autostart program in LXDE
Replies: 8
Views: 17302

Re: Question about autostart program in LXDE

Hi everybody, I wrote a python script using Tkinter and GPIO, so far it works fine. I hope to start it in a more simple way: Just connect power, RaspberryPi will boot, start LXDE and run my python script automatically. But I have no idea how to start python script with sudo(or run as root , because...
by hzhwang
Fri Jan 04, 2013 2:28 pm
Forum: General programming discussion
Topic: Question about autostart program in LXDE
Replies: 8
Views: 17302

Re: Question about autostart program in LXDE

Shouldn't that be ~/.config/autostart/.desktop (not auto.desktop)? http://wiki.lxde.org/en/Autostart Thanks for reply, much appreciated I had tried setting them in ~/.config/autostart/.desktop before, but still not working. Maybe I am setting wrong command, here is my .desktop (autostart.desktop) f...
by hzhwang
Fri Jan 04, 2013 12:17 am
Forum: General programming discussion
Topic: Question about autostart program in LXDE
Replies: 8
Views: 17302

Question about autostart program in LXDE

Hi everybody, I wrote a python script using Tkinter and GPIO, so far it works fine. I hope to start it in a more simple way: Just connect power, RaspberryPi will boot, start LXDE and run my python script automatically. But I have no idea how to start python script with sudo(or run as root , because ...
by hzhwang
Thu Dec 13, 2012 11:29 pm
Forum: 日本語
Topic: 早速作ってもらえてよかったです!
Replies: 8
Views: 5518

Re: 早速作ってもらえてよかったです!

こんにちは

先月RaspberryPiを手に入って、いろいろを試しています
例えば16x2LCDモジュールに日本語を表示
http://www.youtube.com/watch?v=f8dLQsNS4ws

なにかを作ろうという計画はまだありませんけど、
今はJulius(音声認識エンジン)をRaspberry Piにインストールしていろいろをやってみた。
動けるが処理はちょっと重いからモージュルモード(Mac --> Rpi)で続いています
by hzhwang
Mon Dec 10, 2012 5:04 pm
Forum: Python
Topic: A simple program controlling Raspberry Pi GPIO
Replies: 20
Views: 10332

Re: A simple program controlling Raspberry Pi GPIO

Hi, I'm trying to use the example, but I can't figure out how to load the RPi.GPIO library. I went to the source, http://code.google.com/p/raspberry-gpio-python/downloads/list and tried "wget http://code.google.com/p/raspberry-gpio-python/downloads/detail?name=python3-rpi.gpio_0.4.1a-1_armhf.deb&can...
by hzhwang
Sun Dec 09, 2012 11:19 pm
Forum: Python
Topic: A simple program controlling Raspberry Pi GPIO
Replies: 20
Views: 10332

Re: A simple program controlling Raspberry Pi GPIO

Thanks for everyone comments and suggestions and sorry for late reply This program requires RPi.GPIO Library and must run as root. It works under Rev.B v1.0, v2.0 may need some modification. GPIO numbering and color is referred to RPi Low-level peripherals - eLinux.org http://elinux.org/Rpi_Low-leve...
by hzhwang
Tue Dec 04, 2012 5:29 am
Forum: General programming discussion
Topic: A beginner guide to Raspberry Pi driving 5x7 LED Matrix
Replies: 1
Views: 988

A beginner guide to Raspberry Pi driving 5x7 LED Matrix

Hi everybody,

I made a video guide to Raspberry Pi driving 5x7 LED Matrix (using Python)

http://www.youtube.com/watch?v=PRwaj-pGJNs

I am not good at English, and some concepts may be wrong.
It still a draft, and need your kindly comment and suggestions.

Thank you in advance.
by hzhwang
Tue Nov 06, 2012 9:00 am
Forum: Python
Topic: A simple program controlling Raspberry Pi GPIO
Replies: 20
Views: 10332

Re: A simple program controlling Raspberry Pi GPIO

@hzhwang: Way too much code repitition. When you copy and pasting a piece of code over and over again think a moment about the differences and make a function of it that gets the differences as arguments. ... Thank for your comment and suggestions ,it helps. I will refine my code again. Thank you
by hzhwang
Tue Nov 06, 2012 8:56 am
Forum: Python
Topic: A simple program controlling Raspberry Pi GPIO
Replies: 20
Views: 10332

Re: A simple program controlling Raspberry Pi GPIO

Sorry everyone I found a problem in my code, I didn't notice it when I paste the code class App: io4=0 io17=0 io18=0 io21=0 io22=0 io23=0 io24=0 io25=0 def __init__(self, master): should be: class App: io4=0 io17=0 io18=0 io21=0 io22=0 io23=0 io24=0 io25=0 def __init__(self, master): Source code can...
by hzhwang
Mon Nov 05, 2012 11:16 pm
Forum: Python
Topic: A simple program controlling Raspberry Pi GPIO
Replies: 20
Views: 10332

A simple program controlling Raspberry Pi GPIO

Hi everyone, I wrote a simple program that control GPIO in LXDE. Currently you can control GPIO 4,17,18,21,22,23,24,25 high/low just simply press the button. https://s3.amazonaws.com/HZ-Studio/rpp.png Video: http://www.youtube.com/watch?v=15m4-KmMlJM I am new to Raspberry Pi hardware and Python/Tkin...

Go to advanced search