Projet de remplacement du "RPiPasserelle" d'Otec.
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

INSTALL 1.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. # Install instructions
  2. ## Resources
  3. You'll need a rasbpiOs image, and the kernel and dtb for qemu
  4. ## Procedure
  5. ### Enlarge img
  6. The downloaded img is resized on the SD card during the installation. We will need more space on the img. Qemu has command for that :
  7. ```
  8. qemu-img resize rpi.img +1G
  9. ```
  10. Install dependencies :
  11. ```
  12. apt install git sqlite3 python3-pip python3-click python3-requests python3-netifaces python3-serial
  13. ```
  14. Deploy pyHeatpump. Replace MONITORING_SERVER with the address of your server :
  15. ```
  16. mkdir /var/lib/pyheatpump
  17. echo 'pip3 install --upgrade git+https://git.yannweb.net/cli/pyHeatpump.git' > /var/lib/pyheatpump/pyheatpump_upgrade.sh
  18. chmod +x /var/lib/pyheatpump/pyheatpump_upgrade.sh
  19. /var/lib/pyheatpump/pyheatpump_upgrade.sh
  20. cp db/*.sql /var/lib/pyheatpump/
  21. cp db/*.service /var/lib/pyheatpump/
  22. cp db/*.timer /var/lib/pyheatpump/
  23. sqlite3 -init /var/lib/pyheatpump/pyheatpump.sql /var/lib/pyheatpump/pyheatpump.sqlite3
  24. cat << EOF > /var/lib/pyheatpump/pyheatpump.ini
  25. [heatpump]
  26. database = /var/lib/pyheatpump/pyheatpump.sqlite3
  27. [supervisor]
  28. scheme = https
  29. host = MONITORING_SERVER
  30. port = 8081
  31. post_path = /Symfony/web/app_dev.php/boardws/insert
  32. get_path = /Symfony/web/app_dev.php/boardws/orders
  33. interval = 60
  34. heatpump_id = 42
  35. [api]
  36. host = 0.0.0.0
  37. port = 80
  38. EOF
  39. cd /etc/systemd/system
  40. ln -s /var/lib/pyheatpump/pyheatpump_api.service
  41. ln -s /var/lib/pyheatpump/pyheatpump_fetch.service
  42. ln -s /var/lib/pyheatpump/pyheatpump_fetch.timer
  43. ln -s /var/lib/pyheatpump/pyheatpump_supervise.service
  44. ln -s /var/lib/pyheatpump/pyheatpump_supervise.timer
  45. systemctl daemon-reload
  46. systemctl enable pyheatpump_api.service pyheatpump_fetch.timer pyheatpump_supervise.timer
  47. ```