So when you’re still in the initial flashing stage, you only need to have an USB connection to the device. Pinging the ESP won’t help because it’s probably not even connected to WiFi. Are you still in the “first flashing” stage? Then it’s probably due to the FTDI adapter not being recognized, and I don’t know too much how to help with that.
@e_jp Somehow your computer still has esphomeyaml 1.6.2 installed somewhere. I would suggest just trying to remove esphomeyaml (with pip2 uninstall esphomeyamlandsudo pip2 uninstall esphomeyaml) until esphomeyaml ... run returns a command not found. Then you can try re-installing esphomeyaml again and I hope it should work.
@pcl I’m not sure what error you’re referring to But here are a few steps that should help with all kinds of upload problems:
Make sure the initial flashing works - So check that the first “upload” happens via USB.
Look at the serial monitor logs (“logs” with the USB device selected in the header bar in the dashboard). Do any errors appear there? The esphomelib logs are a great place to debug these issues
When the first upload worked and you’re now trying an OTA update, try flashing with a static IP in the wifi: section (if the static IP points to a new host, you’ll have to reflash with USB again; unless you’re using the command line version, then you can use --upload-port)
Look at the logs again, does anything show up there?
pi@raspberrypi:~ $ sudo pip2 uninstall esphomeyaml
Uninstalling esphomeyaml-1.7.0:
Proceed (y/n)? y
Successfully uninstalled esphomeyaml-1.7.0
pi@raspberrypi:~ $ pip2 uninstall esphomeyaml
Traceback (most recent call last):
File "/usr/bin/pip2", line 9, in <module>
from pip import main
ImportError: cannot import name main
pi@raspberrypi:~ $ esphomeyaml
-bash: /usr/local/bin/esphomeyaml: No such file or directory
pi@raspberrypi:~ $ sudo pip2 install esphomeyaml
Collecting esphomeyaml
Installing collected packages: esphomeyaml
Successfully installed esphomeyaml-1.7.0
pi@raspberrypi:~ $ esphomeyaml config/ dashboard
but still, dashboard is showing “esphomeyaml 1.6.2 Documentation” in the bottom right and same validation errors.
EDIT: problem solved by removing manually files in those locations:
pi@raspberrypi:~ $ sudo find / -name esphomeyaml
/home/pi/.local/bin/esphomeyaml
/home/pi/.local/lib/python2.7/site-packages/esphomeyaml
Your’s probably provides 5v out on VCC or Vin, but the logic on the pins D0-D# and A0-A# are going to be 3.3v and using a sensor that outputs at 5v will probably damage you esp
Take this with a grain of salt, but as long as the GPIOs are defined as inputs internally, you can most often hook up higher voltages such as 5v and even smaller negative voltages. The problem really only is when you have them defined as outputs. For example, if you have a 5V line connected to a GPIO pin, it will work quite happily as long as you’re just measuring if the signal is high or low. But if you put the pin into output mode and still have a 5v rail on the other end, the internals will have to sink all that current, which can lead to the chip being damaged.
Of course most sensors use the same pin as output and input for their protocol (such as i2c), so 5v will damage the chip. But if you know what you’re doing, you can often get away with just connecting it directly (or even with a simple in-series resistor).
I’ve removed a GPIO from my yaml of a device I’m working on and re-compiled to the ESP8266 but the binary sensor still shows up in hassio, even after a restart. Is there a method to cleanup sensors?
The usual recommendation I followed in this case was that the ultrasonic sensor’s trigger can be directly connected to an output pin on the ESP (i.e. trigger on 3.3V normally works), but the receiver should be connected through a voltage divider to the ESP’s input pin.