New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WebSockets.cpp:485:77: error: 'sha1' was not declared in this scope #266
Comments
Hi, is the problem still pressend? which board / µ do you use? |
Same problem here! |
Hi there! |
Apparently, this issue still occurs. Also, it seems the CryptoLegacy library is no longer available, so the mentioned workaround doesn't work anymore. Am i missing something, or is this just broken? |
Is it possible to get details on how to reproduce this? the CI building with the Arduino IDE and latest dev ESP8266 and ESP32 core are working. looks like there is some other factor at play, |
sha1 is part of the "Hash" lib in the ESP8266 which is still there in the latest master: |
@Links2004 I'm using this code: https://git.franzi.business/kunsi/obs-websocket-tally/src/branch/main/src/main.cpp - works fine if you don't use OBS_PASS, but it won't compile when it's set.
|
ok in your case it the fault of the this can be seen at the beging of the build.
good:
|
with some changes to the code PlatformIO will do it correctly. diff --git a/platformio.ini b/platformio.ini
index 8a53e25..72cfa7f 100644
--- a/platformio.ini
+++ b/platformio.ini
@@ -14,9 +14,10 @@ framework = arduino
monitor_speed = 115200
platform = espressif8266
upload_protocol = esptool
+lib_ldf_mode = chain+
lib_deps =
bblanchon/ArduinoJson@^6.17.3
fastled/FastLED@^3.4.0
agdl/Base64@^1.0.0
links2004/WebSockets@^2.3.6
- rweather/Crypto@^0.2.0
+ Hash
diff --git a/src/main.cpp b/src/main.cpp
index 5d87a78..f013565 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -7,7 +7,7 @@
#define OBS_HOST ""
#define OBS_PORT 4444
-//#define OBS_PASS ""
+#define OBS_PASS ""
#define OBS_SOURCE "ATEM"
@@ -15,6 +15,7 @@
// END CONFIGURATION
+#include <Arduino.h>
#include <Hash.h>
#include <ESP8266WiFi.h>
#include <WebSocketsClient.h> |
You're correct, it works this way. Thank you for your help, even if it wasn't caused by your library. |
Hello, I am using one of your examples to test and I got a compilation error "WebSockets.cpp:485:77: error: 'sha1' was not declared in this scope". How can I fix it?
The text was updated successfully, but these errors were encountered: