Go to advanced search

by techpaul
Thu Apr 23, 2015 5:25 pm
Forum: Python
Topic: Binary Counter without using shift register such as 74HC595
Replies: 4
Views: 2307

Re: Binary Counter without using shift register such as 74HC

Thanks! You could have learned how to read codes. I was only reducing codes instead of big codes. I had to do tips and tricks or mastering. :D :D That why i can saved file sizes. If I could understand what you are saying I could give a comment, as it seems gibberish Especially as these comments are...
by techpaul
Thu Apr 23, 2015 8:33 am
Forum: HATs and other add-ons
Topic: Advanced ADC Board for Pi
Replies: 6
Views: 2905

Re: Advanced ADC Board for Pi

Yikes. My rule of thumb: If I have to ask how much it costs (and sign up to do so), then I can't afford it. If you just doing hobby project then fine. In the original posters case it is a University Project and the first card he linked to was a 32 channel 16 bit @ 250Khz (probably for all channels ...
by techpaul
Wed Apr 22, 2015 9:39 pm
Forum: HATs and other add-ons
Topic: Advanced ADC Board for Pi
Replies: 6
Views: 2905

Re: Advanced ADC Board for Pi

The first things to ascertain are 1/ How many analog inputs you require and the voltage or current ranges on ALL inputs 2/ The fastest and slowest rate you need to acquire samples on ALL inputs 3/ To what resolution and accuracy you require for each input 4/ do you need additional analog outputs, ag...
by techpaul
Wed Apr 22, 2015 9:27 pm
Forum: Python
Topic: Binary Counter without using shift register such as 74HC595
Replies: 4
Views: 2307

Re: Binary Counter without using shift register such as 74HC

hey man :) why do you define 9 GPIOs while u are using only 8 ? Because the original was 9 bit code counting from 0 to 511, that is 512 steps which is 9 bits, that was the original contributors choice to use 9 bits Using the SAME python construct of for pin in iopins: Actually means it always scans...
by techpaul
Wed Sep 03, 2014 5:49 pm
Forum: Troubleshooting
Topic: i2c troubleshooting
Replies: 17
Views: 3695

Re: i2c troubleshooting

Re installing i2c-tools worked. Thank all of you for your insight and help :) Good day . May I know how you reinstalled i2c-tools. Im facing a similar problem. When I check using i2cdetect, nothing happens, it just moves to the next line. And Im new to Linux as well. So, if you can share how the re...
by techpaul
Tue Jul 15, 2014 4:03 pm
Forum: Python
Topic: I2C Problems - Myth or Fact
Replies: 17
Views: 2471

Re: I2C Problems - Myth or Fact

IOError 5 in Python Smbus is device not found or bus locked up, any number of reasons from bad code, intermittent wiring to gremlins.
by techpaul
Mon Jul 14, 2014 10:03 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: SPI Chip Select line (CE0) goes low after transmittin
Replies: 8
Views: 6221

Re: SPI Chip Select line (CE0) goes low after transmittin

Other than the glitch the rest is as I would expect from almost any SPI master device, you tell it to transfer two bytes and it does. This allows for larger SPI formats having dealt with 8 to 32 bit formats (even 17bit amongst them), and other formats like EEPROM where you may want to read or write ...
by techpaul
Thu Jul 03, 2014 12:20 am
Forum: Python
Topic: GPIO loop, stops
Replies: 11
Views: 2849

Re: GPIO loop, stops

@ techpaul In your read_ds1820 function you'll want to move that tfile.close() outside of the while loop, and you want to add a tfile.seek(0) before the tfile.read() :) The file close was originally indentation screw up by this place (now corrected) You should only need to do a file.seek if the dri...
by techpaul
Wed Jul 02, 2014 8:50 am
Forum: Python
Topic: GPIO loop, stops
Replies: 11
Views: 2849

Re: GPIO loop, stops

joan wrote:There is nothing wrong with the script. Not sure what the OP is actually seeing.
Hmm
  1. background task with no logging of device errors
  2. loop delay of 100ms for device that takes 750ms to do a conversion
  3. repeated block of reading and conversion that should have been a function
by techpaul
Wed Jul 02, 2014 8:47 am
Forum: Python
Topic: GPIO loop, stops
Replies: 11
Views: 2849

Re: GPIO loop, stops

I think I found the bug, I did a long test last night, and after a hour it crashed Traceback (most recent call last): File "zonneregelaar.py", line 29, in <module> tfile = open("/sys/bus/w1/devices/28-000005e6d9ca/w1_slave") IOError: [Errno 2] No such file or directory: '/sys/bus/w1/devices/28-0000...
by techpaul
Tue Jul 01, 2014 11:27 pm
Forum: Python
Topic: GPIO loop, stops
Replies: 11
Views: 2849

Re: GPIO loop, stops

Missed the rc.local bit, when run in background where do you expect the prints to appear? Test from command line first. When you want to convert to running in background put in all sorts of tests and error trapping for things like Unable to open or write to log file (make sure a message goes somewhe...
by techpaul
Tue Jul 01, 2014 5:16 pm
Forum: Python
Topic: GPIO loop, stops
Replies: 11
Views: 2849

Re: GPIO loop, stops

Why are you opening same files (device) inside a loop?

Open it once read it many times inside a loop, then close when finished.
by techpaul
Wed Jun 25, 2014 9:10 am
Forum: General discussion
Topic: Hiding Raspberry Pi inside a wall safely
Replies: 6
Views: 2210

Re: Hiding Raspberry Pi inside a wall safely

Oh and dont forget even if the whole lot is low power, there can be a heat build up when left on all the time, which will damage components over time.
by techpaul
Mon Jun 23, 2014 6:51 pm
Forum: Troubleshooting
Topic: i2c troubleshooting
Replies: 17
Views: 3695

Re: i2c troubleshooting

Whose breakout board would help? Also beware there are differences between MPU6000 and MPU6050 on the pinouts for SDA and SCL. Also beware of the cirucuit of the breakout board and be sure that they have labelled SDA/SCL pait and XDA/XCL pair correctly. You need to be sure you are on SDA/SCL where M...
by techpaul
Fri Jun 13, 2014 4:42 pm
Forum: Automation, sensing and robotics
Topic: Adding a 5v device to a A2D converter with a 3.3V reference
Replies: 9
Views: 2938

Re: Adding a 5v device to a A2D converter with a 3.3V refere

These CO2 sensors change so slowly that any readings faster than 2 seconds apart will only have to be averaged out anyway. I would put filters on signal. A 1.024V reference can be bought easily, at that sort of voltage level I would use a precision refrence rather than resistors from power rails as ...
by techpaul
Fri Jun 13, 2014 1:15 pm
Forum: Automation, sensing and robotics
Topic: Adding a 5v device to a A2D converter with a 3.3V reference
Replies: 9
Views: 2938

Re: Adding a 5v device to a A2D converter with a 3.3V refere

Quick check even on a Wiki page shows the DIFFERENCE bewteen NO CO2 and max concentration is 30-50mV, but it has NO CO2 at 330mv and max concentration around 280mV So any gain above 10 is pointless as the absolute value not the difference is what you are measuring. Also can take 60s between some CO2...
by techpaul
Fri Jun 13, 2014 1:01 pm
Forum: Automation, sensing and robotics
Topic: Adding a 5v device to a A2D converter with a 3.3V reference
Replies: 9
Views: 2938

Re: Adding a 5v device to a A2D converter with a 3.3V refere

Richard-TX started to give the answer to your question, but it looks like he didn't complete the thought. As he stated, the resolution of the ADC at 3.3v is roughly 3.2mV per count. If you connect the sensor directly to the ADC pin, at 30mV the ADC will register 6 (30mV * 1023 / 5v). At 50mV, the A...
by techpaul
Fri Jun 13, 2014 12:21 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: I2C Photodiodes
Replies: 5
Views: 2135

Re: I2C Photodiodes

So I am the mysterious coworker responsible for the code and the circuit that it is responsible for managing. I actually stumbled across this thread while trying to debug the problem, and it seems like you guys could help me figure out the problem. The goal of this system is to get the voltage diff...
by techpaul
Thu Jun 12, 2014 8:27 pm
Forum: General discussion
Topic: FTP/DATABASE Help please
Replies: 4
Views: 1424

Re: FTP/DATABASE Help please

Or find how to use PASSIVE mode FTP, ACTIVE mode uses port 20 and 21

Passive mode is for working from behind firewalls
by techpaul
Thu Jun 12, 2014 5:57 pm
Forum: Off topic discussion
Topic: My idea for a flexible "Strawberry Pi"
Replies: 20
Views: 4312

Re: My idea for a flexible "Strawberry Pi"

I sometimes wonder, why is 'frugality when programming' a good thing:?: Because not being frugal leads to un-necessary bloat and more bugs KISS principle means less to go wrong, operates generally faster, and more efficiently on many levels. Excessive code size generally leads to spaghetti code, un...
by techpaul
Thu Jun 12, 2014 5:48 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: I2C Photodiodes
Replies: 5
Views: 2135

Re: I2C Photodiodes

Considering we have no circuit for this I don't know if you have wired this up correctly. I have no idea why you need an ADC with differential mode inputs on photodiodes. Right assuming Correct reference source has been attached the device is actually powered (check resistance with power off to powe...
by techpaul
Thu Jun 12, 2014 4:00 pm
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: I2C Photodiodes
Replies: 5
Views: 2135

Re: I2C Photodiodes

It would help if you let everyone know what ADC chip you are using (there are 100's of them)

Also repost and put your code in CODE blocks to look like this

Code: Select all

example code block
      another indented line
then all the indents come through so we can understand your code
by techpaul
Thu Jun 12, 2014 2:23 pm
Forum: Off topic discussion
Topic: My idea for a flexible "Strawberry Pi"
Replies: 20
Views: 4312

Re: My idea for a flexible "Strawberry Pi"

I sometimes wonder, why is 'frugality when programming' a good thing:?: Because not being frugal leads to un-necessary bloat and more bugs KISS principle means less to go wrong, operates generally faster, and more efficiently on many levels. Excessive code size generally leads to spaghetti code, un...
by techpaul
Thu Jun 12, 2014 12:45 pm
Forum: Automation, sensing and robotics
Topic: Solar panel power output measurement with rpi
Replies: 19
Views: 5111

Re: Solar panel power output measurement with rpi

BTW for accuracy on my current sensing the sense resistor was 0.01% tolerance and the input circuit used 0.1% tolerance resistors.

The current sensors are the large black items standing up top right of image
by techpaul
Thu Jun 12, 2014 12:43 pm
Forum: Automation, sensing and robotics
Topic: Solar panel power output measurement with rpi
Replies: 19
Views: 5111

Re: Solar panel power output measurement with rpi

I'm new to using hall sensors, so just to get a simple feel of them, what kind of output can i expect when i place them on a wire carrying 2A? (I know it depends on the type of the sensor, but is there a rough guideline?) Best answer is read the data sheet, example circuits, characteristics curves ...

Go to advanced search