Go to advanced search

by ragulin
Fri Jun 10, 2016 11:53 pm
Forum: Beginners
Topic: SUDO Python
Replies: 11
Views: 2472

Re: SUDO Python

To be exact, this is question from oponent in my graduation work at college at monday, and Id really like to know how to get rid of the need of sudo. I know that I can change it somehow in script, or change rights, but I have no idea how to do it. Can I even use GPIO pins without being root ? (sudo...
by ragulin
Fri Jun 10, 2016 10:48 pm
Forum: Beginners
Topic: SUDO Python
Replies: 11
Views: 2472

Re: SUDO Python

If this is a school assignment, then you probably aren't going to get too much help around here. But there's a really popular website that you could go to to ask "Why is sudo bad" and get back tons of great research material that will help you in your understanding of root accounts and elevate priv...
by ragulin
Fri Jun 10, 2016 10:34 pm
Forum: Beginners
Topic: SUDO Python
Replies: 11
Views: 2472

Re: SUDO Python

Hi, what should I do to void need of using SUDO to run python script? Ascertain what rights are needed and add yourself to the appropriate group. EDIT. The root group is never appropriate. Why? How? Im linux noob...I dont know what group do you even speak bout...I just have to use sudo when I run t...
by ragulin
Fri Jun 10, 2016 9:49 pm
Forum: Beginners
Topic: SUDO Python
Replies: 11
Views: 2472

SUDO Python

Hi, what should I do to void need of using SUDO to run python script?
by ragulin
Sat May 14, 2016 11:20 am
Forum: Beginners
Topic: LCD autoscroll
Replies: 4
Views: 890

Re: LCD autoscroll

DirkS wrote:Did you set autoscroll *before* writing the message?
Does the example code work? You may have to change the pin configuration.
See https://github.com/adafruit/Adafruit_Py ... har_lcd.py
If I set the autoscroll before writing the message, the display clears itself
by ragulin
Fri May 13, 2016 3:46 pm
Forum: Beginners
Topic: LCD autoscroll
Replies: 4
Views: 890

Re: LCD autoscroll

DirkS wrote:IIRC autoscroll only works for messages that don't fit on the display and you probably have to set it before you display the message.
It doesnt work even if I make the message longer. I use Adafruit CHar LCD. . . what am I doing wrong? Thanks
by ragulin
Fri May 13, 2016 12:47 pm
Forum: Beginners
Topic: LCD autoscroll
Replies: 4
Views: 890

LCD autoscroll

Hi, my display does not autscroll, do you have any idea how is it possible? I think that the code is all right! import time import Adafruit_GPIO as GPIO import Adafruit_CharLCD as LCD lcd_rs = 7 lcd_en = 8 lcd_d4 = 25 lcd_d5 = 24 lcd_d6 = 23 lcd_d7 = 18 lcd_columns = 16 lcd_rows = 2 lcd_backlight = ...
by ragulin
Fri May 13, 2016 12:40 pm
Forum: Beginners
Topic: Usage of Char_LCD library
Replies: 3
Views: 498

Re: Usage of Char_LCD library

Hey, I dont know why, but my library prolly does not work. I use this code, and when I try to use whichever kind of the library order, it tells me that it isnt defined, for example with the clear... import time import Adafruit_GPIO as GPIO import Adafruit_CharLCD as LCD lcd_rs = 7 lcd_en = 8 lcd_d4...
by ragulin
Fri May 13, 2016 11:37 am
Forum: Beginners
Topic: Usage of Char_LCD library
Replies: 3
Views: 498

Usage of Char_LCD library

Hey, I dont know why, but my library prolly does not work. I use this code, and when I try to use whichever kind of the library order, it tells me that it isnt defined, for example with the clear... import time import Adafruit_GPIO as GPIO import Adafruit_CharLCD as LCD lcd_rs = 7 lcd_en = 8 lcd_d4 ...
by ragulin
Sun May 08, 2016 5:47 pm
Forum: Beginners
Topic: LCD High and Low bits
Replies: 3
Views: 618

Re: LCD High and Low bits

It's inefficient code. The bits are all set to zero first, then set to 1 one-at-a-time if they need to be. It would be better to treat all 8 GPIOs as a byte, and set them all at once. My circuit works in 4 bits mode, I just dont know why and how I have this parts in there...I dont see a reason why ...
by ragulin
Sun May 08, 2016 3:36 pm
Forum: Beginners
Topic: LCD High and Low bits
Replies: 3
Views: 618

LCD High and Low bits

Hey, I need a little help with understanding the code I use. I know that this code sets the 4 bits operational mode for my LCD display. I cant find the reason of the "if" function and its parameters in the datasheet though....thanks for advice ! The code: # High bits GPIO.output(LCD_D4, False) GPIO....
by ragulin
Thu May 05, 2016 7:22 pm
Forum: Python
Topic: DHT connected in the TXD
Replies: 3
Views: 741

Re: DHT connected in the TXD

GPIO14 is being used as an ordinary GPIO. It is not configured in a serial mode. The DHT11 datasheet shows the wiring requirements, THanks, I know that DHT pin2 is connected to the MCU...so I load data from DHT in GPIO 14, which is configured as "input" and I write it in my LCD..so if I understand ...
by ragulin
Thu May 05, 2016 6:05 pm
Forum: Python
Topic: DHT connected in the TXD
Replies: 3
Views: 741

DHT connected in the TXD

Hi, I have my DHT11 sensor connected in the TXD port in my Raspberry Pi. I am not sure, what does it mean and what does it do. I follow this tutorial, and I would like to know what is hapenning there, and why I need to have +5V and resistor as well connected to the DHT pin 2. I know that TXD is some...
by ragulin
Tue Apr 12, 2016 11:57 pm
Forum: Beginners
Topic: Load of data from DHT11 in Google sheets
Replies: 2
Views: 754

Load of data from DHT11 in Google sheets

hi, I followed this tutorial step by step. https://learn.adafruit.com/dht-humidity-sensing-on-raspberry-pi-with-gdocs-logging/connecting-to-googles-docs-updated Unfortunatelly, when I start the program, it tells me: Traceback (most recent call last): File "./google_spreadsheet.py", line 43, in <modu...
by ragulin
Thu Mar 10, 2016 9:20 am
Forum: Beginners
Topic: Question about my LCD code
Replies: 7
Views: 877

Re: Question about my LCD code

[The problem is that I am using TC1602A, it is weird, but the libraries works with it as well. I am not sure why... That display is just one of many HD44780 compatible displays. That is the most common type of controller for those sort of displays, so the libraries will work with it just fine. so t...
by ragulin
Wed Mar 09, 2016 11:07 pm
Forum: Beginners
Topic: Question about my LCD code
Replies: 7
Views: 877

Re: Question about my LCD code

If you're doing it as a learning exercise that's great. But if you want a simpler and more "human readable" way to control it and troubleshoot, then import an LCD library for the hd44780. Then the library will deal with the bits, bytes, and commands, and you can just: lcd.message('to print some tex...
by ragulin
Wed Mar 09, 2016 1:38 pm
Forum: Beginners
Topic: Question about my LCD code
Replies: 7
Views: 877

Question about my LCD code

Hi, I have a code which allows me write whatever I want in my LCD from a terminal: #import dulezitych knihoven import sys import RPi.GPIO as GPIO import time #Nastaveni promenych na jednotlive GPIO piny LCD_RS = 7 LCD_E = 8 LCD_D4 = 25 LCD_D5 = 24 LCD_D6 = 23 LCD_D7 = 18 # Nastaveni konstant LCD pan...
by ragulin
Wed Mar 09, 2016 1:25 pm
Forum: Beginners
Topic: Understanding to LCD
Replies: 7
Views: 801

Re: Understanding to LCD

Actually you don't have to worry about those signals. They are between the control IC and the LCD panel itself. You send the right commands to the module and it handles the LCD signals for you. Thanks, I just have a problem that I will have to vindicate it infront of comission, and if they ask me e...
by ragulin
Wed Mar 09, 2016 12:30 pm
Forum: Beginners
Topic: Understanding to LCD
Replies: 7
Views: 801

Re: Understanding to LCD

BMS Doug wrote:I think that is correct, I just use the libraries that other people have already written.
And the common is some wave form, which specifies which segments are selected, and which characters are going to be displayed, right?
by ragulin
Wed Mar 09, 2016 12:20 pm
Forum: Beginners
Topic: Understanding to LCD
Replies: 7
Views: 801

Re: Understanding to LCD

Common: shared by, coming from, or done by two or more people, groups, or things. on Page 14: LCD Driver Circuit Total of 16 commons and 40 segments signal drivers are valid in the LCD driver circuit. When a program specifies the character fonts and line numbers, the corresponding common signals ou...
by ragulin
Wed Mar 09, 2016 11:53 am
Forum: Beginners
Topic: Understanding to LCD
Replies: 7
Views: 801

Understanding to LCD

Hey, I am writing my diplom work and I am working with raspberry pi and TC1602A. I found a weird sentence in the datasheet, and I cant translate it, or find what does it mean. Can somebody give me some aid please? The sentence: Total of 16 commons and 40 segments signal drivers are valid in the LCD ...
by ragulin
Wed Feb 03, 2016 2:25 pm
Forum: Python
Topic: LCD 16x2 control
Replies: 12
Views: 1745

Re: LCD 16x2 control

It looks as though it is expecting an input that you have not provided: probably the text for the second line of the display. Yeah, it works now, thanks. DO you by accident know, why we have to control high and low bits? THis part of code # High bits GPIO.output(LCD_D4, False) GPIO.output(LCD_D5, F...
by ragulin
Wed Feb 03, 2016 2:08 pm
Forum: Python
Topic: LCD 16x2 control
Replies: 12
Views: 1745

Re: LCD 16x2 control

B.Goode wrote:Can you give an example of what you put on the command line to start your script? It looks as though it is expecting an input that you have not provided: probably the text for the second line of the display.

sudo python LCD2x16.py 123

Thats what I write there :-)
by ragulin
Wed Feb 03, 2016 1:47 pm
Forum: Python
Topic: LCD 16x2 control
Replies: 12
Views: 1745

Re: LCD 16x2 control

I have a syntax error in this part of the def string(): i = i + 1 Whats wrong there?Whatever I try to do, it doesn t help...thanks for advice. Usually if there is an error in a simple statement (that looks perfect) it means there is an error in the previous line or block of code. So, there is nothi...
by ragulin
Wed Feb 03, 2016 11:27 am
Forum: Python
Topic: LCD 16x2 control
Replies: 12
Views: 1745

Re: LCD 16x2 control

Hi, so I somehow understood to almost all parts of the code. I just dont know why its important to have high and low bits and delay in the end of the code. My code looks this: #import dulezitych knihoven import sys import RPi.GPIO as GPIO import time #Nastaveni promenych na jednotlive GPIO piny LCD_...

Go to advanced search