Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TCS34725 configuration #203

Open
Noro999 opened this issue Jan 30, 2022 · 7 comments
Open

TCS34725 configuration #203

Noro999 opened this issue Jan 30, 2022 · 7 comments

Comments

@Noro999
Copy link

Noro999 commented Jan 30, 2022

Hi,
I will start by saying I really love this project!!
Thanks a lot for sharing this.

I’m new to Raspberry, so I’m guessing I missing something.

I’m trying to configure TCS34725, but when booting the web page shows on startup, and I don’t know how to access the Ras setting and the file sys to update the files.

Thanks in advance.

Noro

@dadr
Copy link
Contributor

dadr commented Jan 31, 2022

Hi Noro999,

Here are some "long-winded" instructions...

First, shut down the Pi. Then access the SD card from another computer. When you plug it in, it should show up as a drive called boot. Copy the colortemp.sh file to the boot drive so you don't have to download it from the command line on the Pi.

If you attach a spare USB keyboard to the Pi, then you're done. If you don't, then create a file named ssh within the boot drive - no extensions or dot. It can be empty.

When the Pi boots up with the keyboard attached, type ALT-F2.

If you are using ssh instead of the keyboard, then from another computer ssh into the Pi by watching for the address it shows you when it boots. So, if it boots and says it's listening to 192.168.1.5:7777, then you would use the ssh command like this: ssh 192.168.1.5 ssh is a command line program, so you need to run it from a shell. (command in Windows)

You should now see a login prompt from the Pi. The default user is pi and password is raspberry
Once logged in, type sudo raspi-config and this will start a text menu system. Goto item 5 and then select to enable the I2C bus. Then you can exit raspi-config.

Now type sudo mv /boot/colortemp.sh /root/photoframe_config/colortemp.sh
Now type: sudo chmod +x /root/photoframe_config/colortemp.sh

If you want to make sure everything worked:
type ls -l /root/photoframe_config/colortemp.sh
You should see the following from that command:
-rwxr-xr-x 1 root root 25153 Mar 11 2021 colortemp.sh (the important part is the rwxr-xr-x)

At this point you should reboot the Pi and everything should work.

If it works, and you enabled ssh on the Pi, then you should either create a new password for pi with the passwd command, or use the sudo raspi-config to turn off the ssh server.

@Noro999
Copy link
Author

Noro999 commented Feb 3, 2022

@dadr Thanks for your help.
I mange to make it work,
I got a read, that looks good ("Current ambient environment 120.57 lux and 1856K color temperature")

The ambient powersave feature works great (Very nice !),
But it look like there is no effect on the way the photo is display on the monitor (ie - when dimming the lights, the values decrease but the brightness of the photo remain the same).
I wonder if there is a way to control the brightness of the photo display with the color sensor, or it only used for powersave?

Thanks in advance

Noro

@dadr
Copy link
Contributor

dadr commented Feb 4, 2022

@Noro999 - I'm glad it's working for you. The way this feature works is that it will use the colortemp.sh script to change the color balance or temperature of the picture when it is initially shown. So you will not see immediate changes when you turn off the lights; the change occurs when the next picture is shown. And, unless the temperature changes, you might not see any changes at all. The way to see the most dramatic change is if you go from daylight to incandescent light. (e.g. if you see a large swing in the temperature reading). The brightness or lumens are only used to turn on and off the screen.

I'm curious what sort of screen or monitor you are using for your photoframe? There are potentially some improvements for you in an upcoming photoframe V2 release. You can read about this in issue #191 .

@Noro999
Copy link
Author

Noro999 commented Feb 13, 2022

@dadr Thanks again for the detailed answer.
I'm using this monitor, which looks really good.

https://www.amazon.com/Sceptre-E248W-19203R-Monitor-Speakers-Metallic/

Waiting for your next update 🙏

Noro

@dadr
Copy link
Contributor

dadr commented Feb 13, 2022

That looks like a great monitor. Are you planning to put it into a frame, or just use it as-is? I've done both. For the photo frame I put together for my son's birthday, (#191) I took apart the monitor and put it in a deep picture frame.

You can see one of my learnings in this picture. I put the Pi inside the monitor chassis just inside an opening where some cables were connected, but later I had to cut a notch to expose the WiFi antenna on the Pi. While it might seem a good idea to protect the Pi, the chassis kills the WiFi signal unless you're careful. You can also see the light sensor at the top. I got an acrylic rod that I cut to the thickness of the frame and then flame-polished. It's a light pipe that works nearly as good as placing the sensor on the top of the frame.

IMG_7168
IMG_7167

I have some older monitors that I use as-is, placed on a desk with a RPi dangling from a short cable or adapter behind it.

I'm waiting for release 2 too! I think that the software is ready for a 2.0 release. But that is not up to me. @mrworf is the "owner" of this repository. He's a professional programmer, whereas I'm just a retiree using this to teach myself how to program in python. I think he has to find the time to look through all the changes - not just for correctness, but also to ensure that it's in good enough shape to be put into production.

@Noro999
Copy link
Author

Noro999 commented Feb 13, 2022

@dadr That looks like an amazing work!

I have a question regarding the TCS34725 mounting -
I'm using a shadow box as a frame, and I want to drill hole to place the sensor behind it, inside the frame.
Do you think it will work and enough light will get inside, or I need a different approach?
If so - what size will do the work?
I don't want to cut a piece from the frame.

Thx

Noro

@dadr
Copy link
Contributor

dadr commented Feb 13, 2022

@Noro999 - your idea should work well. If you get the small sensor in the middle of the board behind a hole about the same size and through paper or matting, then I think you have no worries. That will work great. And facing forward is the preferred direction - looking into the room. If you have to mount the sensor more than about a centimeter behind a small hole, then you could think about using a light pipe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants