[SOLVED]Issue with sending data to webserver
Posted: Fri Sep 01, 2017 11:19 pm
Murphy's law seems to strike again for me. My current project is simply sending some temperature data to my Pi with my Wemos D1 mini. I finally got everything working smoothly, or so I thought. After an hour or two of running a loop that reads the temp sensors and sends the readings to the webserver, it crashes with this error:
my function that sends the temperature readings:
Code: Select all
File "esp8266temptest4.py", line 117, in go
File "esp8266temptest4.py", line 110, in send_data
File "urequests.py", line 104, in post
TypeError: unexpected keyword argument 'crc8'
Code: Select all
def send_data():
url = 'http://[webserveripaddress]/php/rsensor.php'
headers = {'Content-Type': 'application/x-www-form-urlencoded'}
datas = "data=" + str(basic_temp) + "&" + "data2=" + str(advanced_temp)
urequests.post(url, data=datas, headers= headers)