Preview:
DESCRIPTION
Citation preview
- 1.
- 2. Arduino Arduino Arduino
- 3.
- 4.
- 5. Apache
1 test.php
- 6. Apache
- [root@lucen /]vi /etc/php.ini
- /usr/sbin/apachectl restart
- 7.
2
- 8.
3
- 9. IP -print_ip.php 4 print_ip.php
- 10. -temp_write.php
- 11. 2.Arduino
LM61 5 Arduino
- 12. Arduino
6 Aduino
- 13. Arduino
- { 0x90, 0xA2, 0xDA, 0x00, 0x0D, 0x42 }; //Ethernet mac
- byte ip[] = {160, 18, 8, 158 }; //Arduino IP
- Client client = Client(server, PORT);
- Ethernet.begin(mac, ip); //Ethernet
- 14. Arduino
- A_val = analogRead( A_inPin ); // (8bit A/DC)
- client.write("GET /temp_write.php?temp=");
- client.print(tempC, DEC);
- client.write(" HTTP/1.1n");
- client.write("HOST:160.18.8.156nn");
- 15. temp_write.php
7 temp_write.php
- 16.
- chown apache /var/.data.txt
- chmod (option) [a+w] [file name]
- chmod R 777 /var/..data.txt
- 17. data.txt
8 data.txt
- 18. Arduino Arduino