electrorush4u / acs712 Goto Github PK
View Code? Open in Web Editor NEWArduino Library Supports ACS712 Current Sensor Module for 5A, 20A, and 30A
Home Page: https://ElectroRush4u.github.io
License: MIT License
Arduino Library Supports ACS712 Current Sensor Module for 5A, 20A, and 30A
Home Page: https://ElectroRush4u.github.io
License: MIT License
ACS.mA_AC()
doesn't work if esp32 is connected to WiFi.
Upload this sketch to esp32 it should give out some random noisy values (or connected it to an actual ACS712) then uncomment the lines about WIFI replacing ssid
and password
with your network credentials and upload the sketch again. Now it only spits out 0 mA.
#include "ACS712.h"
#include <WiFi.h>
ACS712 ACS(25, 5.0, 4095, 185);
void setup()
{
Serial.begin(115200);
ACS.autoMidPoint();
// WiFi.begin(ssid, password);
// while (WiFi.status() != WL_CONNECTED) {
// delay(500);
// }
}
void loop()
{
int mA = ACS.mA_AC();
Serial.print("mA: ");
Serial.println(mA);
}
When restarting arduino IDE and compiling the program for the first time this error gets printed, not sure if that's related:
/Users/noran/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/cores/esp32/esp32-hal-spi.c: In function 'spiTransferBytesNL':
/Users/noran/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/cores/esp32/esp32-hal-spi.c:922:39: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
uint8_t * last_out8 = &result[c_longs-1];
^
/Users/noran/Library/Arduino15/packages/esp32/hardware/esp32/1.0.6/cores/esp32/esp32-hal-spi.c:923:40: warning: initialization from incompatible pointer type [-Wincompatible-pointer-types]
uint8_t * last_data8 = &last_data;
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.