0

I'm using my Raspberry Pi a lot for different applications and am normally running Python scrips on it to control the Raspberry Pi. I now have a problem that I couldn't find out how to solve. I have several controllers connected to my Windows computer and am recording different parameters from different controllers (I'm researcher and need to record different parameters, none of the controllers is a raspberry pi so far). However, it would be great to measure the room temperature and humidity as well as I record other parameter and I was wondering if I can directly connect to my Raspberry Pi and remotely read out the temperature and humidity and directly have the values stored on my Windows computer?

The only problem that I have is that it is unclear to me how to access the Raspberry Pi by Python (run from my Windows computer), do a readout and store the value directly on my computer.

  • I suggest having the necessary sensors connected to the Pi, with a python script that will save the output from them to a text file. You'll then need a piece of code that will have the file sent from the Pi to your Windows computer. There are plenty of tutorials out there for a setup like that. – Darth Vader Oct 8 '16 at 20:34
1

My pigpio library has a Python module which can run on Windows and will communicate with the pigpio daemon running on one or more Pis.

This allows your Windows (or Mac or Linux) box to run a Python script which talks to the GPIO on one or more networked Pis.

As long as your sensors use the GPIO, or I2C, or SPI there shouldn't be a problem.

| improve this answer | |
  • Just a question: how do I automatically run the pigpio deamon when the raspberry pi starts up? I basically have just to enter "sudo pigpiod" in the command line, but is there a way it automatically does it? – Andi Spiel Oct 8 '16 at 22:45
  • I've found the solution. the easiest is to add it to the crontab. by entering "sudo crontab -e" one can edit it by adding an extra line "@reboot /usr/local/bin/pigpiod" – Andi Spiel Oct 8 '16 at 23:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.