Go to advanced search

by Anugerah Nuri Satria
Tue Jul 28, 2020 1:39 pm
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

I need your help. sir
by Anugerah Nuri Satria
Tue Jul 28, 2020 8:04 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

It means I should change my sensor and follow the list of sensor that can run https://circuitpython.org/blinka ???
by Anugerah Nuri Satria
Tue Jul 28, 2020 12:50 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

I dont know exactly what line makes that code wrong sir. I use 2.7.16 version of phyton
by Anugerah Nuri Satria
Mon Jul 27, 2020 7:34 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

I have another problem Sir. When I try to run MAX6675 program that can work in the past, now i always get this in terminal Traceback (most recent call last): File "simple_test.py", line 50, in <module> sensor = MAX6675.MAX6675(CLK, CS, DO) File "build/bdist.linux-armv7l/egg/MAX6675/MAX6675.py", line...
by Anugerah Nuri Satria
Mon Jul 27, 2020 7:27 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

thanks in advanced sir, you help me a lot!
by Anugerah Nuri Satria
Fri Jul 24, 2020 1:21 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

when i started to excute this code in terminal, the output always like this


Proses Tapper Roll ke 1
08:18:27
('time between detections', 0.0, 'seconds')

it is first sense but i do nothing for that
by Anugerah Nuri Satria
Thu Jul 23, 2020 11:32 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

I mean when I start firstly, that code will give output 2 directly ( 1 and 2 Items)

Or I make a mistake?
by Anugerah Nuri Satria
Thu Jul 23, 2020 11:01 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

What should I change to make that program start from zero while counting? Ok so now we have that sorted. try this code , note its untested so there may be spacing errors and I have set it to clear the LCD on every update , you can change this if you make it so that you load the LCD fixed test once a...
by Anugerah Nuri Satria
Wed Jul 22, 2020 1:29 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

Yes sir, it works in my Rpi. So how can I show a counter and average time between? So if you have installed RPLCD, then if my guess at your hardware set up is correct then this should output test on all 4 lines of the LCD import RPi.GPIO as GPIO import time from RPLCD.i2c import CharLCD lcd = CharLC...
by Anugerah Nuri Satria
Tue Jul 21, 2020 1:01 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

Sorry, i remember that i follow this web: https://github.com/jumejume1/pi-LCD-Ultrasonic/blob/master/distance-lcd.py But it is used just for 2 lines. Then I am confused because no were in the docs I can see does it say import lcddriver the import command for RPLCD is from RPLCD.i2c import CharLCD th...
by Anugerah Nuri Satria
Mon Jul 20, 2020 12:50 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

pi@raspberrypi:~ $ sudo pip install RPLCD Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: RPLCD in /usr/local/lib/python2.7/dist-packages (1.3.0) i just follow your instruction before at https://rplcd.readthedocs.io/en/stable/installation.h...
by Anugerah Nuri Satria
Fri Jul 17, 2020 9:03 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

pi@raspberrypi:~/Documents $ python saiful.py
Traceback (most recent call last):
File "saiful.py", line 6, in <module>
lcd = lcddriver.lcd(cols=20, rows=4)
TypeError: __init__() got an unexpected keyword argument 'rows'
by Anugerah Nuri Satria
Fri Jul 17, 2020 3:13 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

if I run my code, it will give output like this WhatsApp Image 2020-07-17 at 10.05.09.jpeg For Expander and Adress. pi@raspberrypi:~ $ i2cdetect -y 1 0 1 2 3 4 5 6 7 8 9 a b c d e f 00: -- -- -- -- -- -- -- -- -- -- -- -- -- 10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 20: -- -- -- -- -- -- -...
by Anugerah Nuri Satria
Thu Jul 16, 2020 8:40 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

looking at your code you have already worked out how to display information on the LCD , so what problem are you having in changing the print lines to output the information on the display ? i just found that way today sir, I still confuse how to make 2 line to make 2 output. average time between a...
by Anugerah Nuri Satria
Thu Jul 16, 2020 8:26 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

This is my code SIr import RPi.GPIO as GPIO import time import csv import lcddriver display = lcddriver.lcd() display.lcd_display_string("Counter :", 1) counting = 0 GPIO.setmode(GPIO.BCM) GPIO.setup(25, GPIO.IN) GPIO.setup(24, GPIO.IN, pull_up_down=GPIO.PUD_UP) csvfile = "countermesin" try: start =...
by Anugerah Nuri Satria
Thu Jul 16, 2020 12:44 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

I still use your code Sir. because it matches for my project to count leaf spring. I dont know how to show in LCD sir. I need your suggestions. This version of the code will also give you the number of seconds between detections import RPi.GPIO as GPIO import time counting = 0 GPIO.setmode(GPIO.BCM)...
by Anugerah Nuri Satria
Tue Jul 14, 2020 1:30 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

Hello Mr. PcManBob
Now, My LCD is ON. But I dont know how to show output from terminal to LCD in realtime for my code before.
Python Code for counting.
by Anugerah Nuri Satria
Mon Jul 13, 2020 5:59 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

Dear Mr.Pcmanbob


I have followed that instruction. But why my LCD does not ON? i have given VCC and GND correctly.
by Anugerah Nuri Satria
Thu Jul 09, 2020 1:27 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

I have purchased LCD 20x4 I2C.
and i have installed RPLCD.

Then, what should I do to show my counter system?
by Anugerah Nuri Satria
Fri Jul 03, 2020 2:22 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

Anugerah Nuri Satria wrote:
Fri Jul 03, 2020 1:24 am
Probably i will use gpio because if i decided to use i2C, it means that i should buy display and i2C module, right?

Basicly, what is the differences between i2C and gpio?
But i think wiring using i2c is easier than using gpio, right?
by Anugerah Nuri Satria
Fri Jul 03, 2020 1:24 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

Probably i will use i2c because if i decided to use i2C, it means that i should buy display and i2C module, right?

Basicly, what is the differences between i2C and gpio?
by Anugerah Nuri Satria
Thu Jul 02, 2020 1:20 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

So, i can write this exactly like this pict in lcd ?

WhatsApp Image 2020-06-18 at 08.58.42.jpeg
WhatsApp Image 2020-06-18 at 08.58.42.jpeg (114.65 KiB) Viewed 633 times
that is your project that you gave before

should we make another program to show output in that lcd? do u have the example for that?
by Anugerah Nuri Satria
Wed Jul 01, 2020 3:44 am
Forum: General discussion
Topic: Define output from terminal
Replies: 2
Views: 141

Re: Define output from terminal

Your question is not clear. The Pi itself cannot count time at all when it is powered off. That means that for it to know the time it has been powered off it will need some external hardware, with it's own battery or other power supply, to measure the down time. Or you could do it by making use of ...
by Anugerah Nuri Satria
Wed Jul 01, 2020 3:32 am
Forum: Python
Topic: Write data just when the output changes
Replies: 60
Views: 2177

Re: Write data just when the output changes

Hi pcmanbob I have read a lot of seven segment for my output, but i also need to show time between to my operator. is there any HMi for raspberry pi that can show number of count and time between 2 sensing?
by Anugerah Nuri Satria
Wed Jul 01, 2020 3:13 am
Forum: General discussion
Topic: Define output from terminal
Replies: 2
Views: 141

Define output from terminal

i am new with raspberry pi. i have a small project. i need to count time if the supplied power to the machine is cut. that's mean when the machine is at 'OFF' state the counter will start counting and if the machine back on to the 'ON' state the counter stop the counting. the problem is I need to de...

Go to advanced search