![]() ![]() Now we'll have to adjust the code a bit to make it work with your own project. ![]() Don't forget the 2nd tab " Mappings" -> see screenshot too. Next we'll also want to upload our code to our pi using ( Tools > Deployment > Configuration) Add a new configuration, choose SFTP as type and fill in the fields like the screenshot above. Install the following packages with the green add button on the right: This also means we can start adding packages to work with. We now have a remote Python3 interpreter to work with. Click the settings icon (upper right) and select " Add remote" and fill in the fields like the screenshot. In Pycharm go to ( File > Settings > Project: app > Project interpreter) and you'll see a window similar to the screenshot above.įirst we need to select our Python interpreter that's located on our pi. Open up Pycharm and select " open project" and select the app folder. "App" is the code we'll first use to make the water flow and "website" is the code we'll use second to run the website. Next go to " 5 Interfacing options > P7 1-Wire > Yes" Reboot your pi with this command after you enabled 1-wire: sudo rebootĭownload the code we'll use in pycharm hereĪs you can see there are 2 folders on my github page: app and website. We can do this by using this command: sudo raspi-config ![]() If we want to utilise the temperature sensor we'll have to enable 1-wire protocol on our pi. Next we want to make sure our pi is up to date, we can install updates with this command: sudo apt-get update & sudo apt-get upgrade ![]() Go to /etc/nf and check if these are the same as the screenshot above. Here you can find a list of common linux commands to help you navigate through the OS. The default username is "pi" and the default password is "raspberry". We can now start working on our pi in the terminal that just opened. Put "169.254.10.1" in the Host name form in putty, choose SSH as connection type and press "open". Now you can plug in the power cord for the pi and start Putty. Safely remove the sd card and put in the pi and connect the ethernet cable between your pc and pi. To get a safe conncetion with our pi we need to enable SSH, we can do this by putting an empty file (without extension) named "ssh" on our SD card. Open the cmdline.txt with your text editor of choice and add " ip=169.254.10.1" to your file (without quotes) so it looks like the photo above. Now we need to navigate to our SD card, in my case the "E:/" drive. Tip: The "Write" button can later on be used to create a backup. To continue click "Write", the software will now put the OS on your SD card. Then under "Device" you select the drive of the SD card. When you open Win32 Disk Imager you need to select your img file you have just downloaded. Win32 disk imager (to install the OS on the SD card).(Photo nr.4) Last thing that had to be done was making sure the front sensor was in a good position so I created a "roof" for my sensor so it could be right on top of the water bowl. (Photo nr.3) In my roof plate I cut a hole with a jigsaw so I could mount the LCD on it and mounted it on top of the rest. (Photo nr.2) Then I drilled a hole in my middle plate where the electronics are so I could let the wires pass through the hole and mounted it in my case. (Photo nr.1) After I cut the cover for my reservoir I drilled a big hole in the front plate (around the middle) so I could later on pass the water loop and drilled a small one for the cables of the hc-sr04 in front, then I started mounting the walls on the base plate That's it, other than this rule you can really just build what you prefer. The ultra sonic sensors have to be on top of your reservoir and water bowl facing the water.Īs you can see for my reservoir cover, there are 2 holes in it that I cut with a hot knife so I could get the water loop out of it and the ultra sonic sensor in it. First of all, your case doesn't have to be exactly like mine, you can build whatever you want but you want to make sure this rule applies to your build: ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |