Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
Develo
@devyte
Depending on your code, even yields and delays may not be enough. They allow servicing the wifi stack, but not passing data out to the app layer, so if you take too long you could still blow up
Yield and delay can only be called from the loop, or functions called from the loop. Can't be called from e.g. a Ticker callback, and ISR
There are specific time specs defined by espressif about how long you can be away in your own code, bow long an ISR should take max, and so on.
I don't remember the specifics for each case, but they should be in the espressif sdk docs
Bryce Schober
@bryceschober
Thanks for your help on this channel, all of you! I know it can seem like a thankless task sometimes, with users complaining about the problems they're usually causing themselves.
Bryce Schober
@bryceschober
@riataman @brutzler FYI, just ran across ESP.getSketchMD5() as declared in ESP.h. It would only help identify a particular build binary to match against the firmware on the ESP, but that would be easy to search for in the continuous-integration build job that produced that artifact and the source revision that it came from. You're doing all that, right? ;-)
Develo
@devyte
In case anyone is interested, I implemented an async dns server. It uses AsyncUDP instead of WifiUDP, and there is no need to call a function within the loop.
Bryce Schober
@bryceschober
Nice! Now we just need an AsyncDHCPServer and AsyncMDNSResponder to go with it. ;-)
Develo
@devyte
@bryceschober I think esp8266mdns is already async, although it doesn't use asyncudp
The dhcpserver for the softap is also async, I think. You don't need to call a handler from the loop
Me No Dev
@me-no-dev
@bryceschober most/half of the services are already async. They do not use AsyncUDP because it was not around when I wrote them. Plus AsyncUDP is external lib :P
Develo
@devyte
@me-no-dev I tried to write it in a generic way, aiming for compat on the esp32, but I haven't tried it (don't have boards)
Don't know if it'd be useful over there, but it's available in case somebody wants to try it out
Me No Dev
@me-no-dev
generic way will be once I add AsyncUDP there ;) which BTW I think is done, just not throughly tested. Network works differently on ESP32
Develo
@devyte
@me-no-dev ah sorry, I thought it was done. I've been sort of keeping half an eye on the esp32 repo by reading the issues and activity in general, so I'm sort of aware of the status, but not specifics
Me No Dev
@me-no-dev
async udp is a personal project of mine :) though i am thinking of including it in Arduino and basing dns and such services on it
maybe even AsyncTCP
yannS2016
@yannS2016
libmain.a(app_main.o):(.irom0.text+0x14): undefined reference to `__wrap_register_chipv6_phy'
can get help with this issues: libmain.a(app_main.o):(.irom0.text+0x21): undefined reference to `__wrap_register_chipv6_phy'
brutzler
@brutzler
Hi, has anyone experiences with light sensors (e.g. with I2C)?
Just looking at a BH1750. But its imho only as breakout available. How to use this for outdoor?....
Holger Lembke
@holgerlembke
@brutzler yes. bme280(P:1005 mBar T:21.5° C H:64 %) bmp180(P:1005 mBar T:21.2° C) hih9130(H:70 % T:21.0° C) htu21d(T:21.1° C H:66 %) bh1750fvi(Ev:15.51 lx) TSL2561(Ev:9.10 lx) rtc(T:21.2° C)
but it is indoor
brutzler
@brutzler
??? what do u want to tell me?
Mehrdad K
@mkeyno
hi guys ,I intend to make 3x3 keys with 6 pin of ESP8266, I made pin 0,2,5 as pullup input and 4,5,12 as output , I made following sketch , does anyone has experience to make keypad from ESP pins? do I need more extra pullup or pulldown resistor?
1.png
Holger Lembke
@holgerlembke
@mkeyno Should work. GPIO 16 is pulldown, all others are pullup.
Mehrdad K
@mkeyno
thanks @holgerlembke , I'm using GPIO 16 as output
dragon-engineer
@dragon-engineer
I had problems with oneWire on pin16, even with external pull-up, not a single device found on PIN16, on others works great (pin set only as input)
Me No Dev
@me-no-dev
pin16 works at a different frequency than the rest
maybe that is causing your issue
dragon-engineer
@dragon-engineer
maybe. but oneWire is 'kinda' low speed
is there anything we can do about it or not? :smile:
Holger Lembke
@holgerlembke
@matasondrak did you try a lower pullup value?
dragon-engineer
@dragon-engineer
actually I think this is the only thing so onewire MAY run, but I was busy doing other stuff.. I use 4k7 pull-ups, so 2k2 might do it
dragon-engineer
@dragon-engineer
It doesn't work. 10cm wires, 2 parallel 4k7 resistors
Holger Lembke
@holgerlembke
@matasondrak 2k2 might be to low... I thought about 3k5 or so. I have a small decade resistor box for experiments.
Mehrdad K
@mkeyno
hi guys , I'm trying use 3x3 keypad with 6 ESP8266 pins and Arduino Keypad Library , according to its library, row pins set input pullup and column Pins set output and LOW and in pool all output pins versus input pins will be checked , but after running the following sketch, notice only couple of key combination works (2&16 ->e 0&16->h) any clue really appreciated
#include <Keypad.h>

const byte ROWS = 3; //four rows
const byte COLS = 3; //four columns
//define the cymbols on the buttons of the keypads
char myKeys[ROWS][COLS] = {
 //16   12  4
  {'a','b','c' }, //5
  {'d','e','f' }, //2
  {'g','h','i' } //0
};
byte row_Input_pullup_Pins[ROWS] = {5, 2, 0}; //connect to the row pinouts of the keypad
byte output_low_state_colPins[COLS] = {16, 12, 4}; //connect to the column pinouts of the keypad

//initialize an instance of class NewKeypad
Keypad customKeypad = Keypad( makeKeymap(myKeys), row_Input_pullup_Pins, output_low_state_colPins, ROWS, COLS); 

void setup(){
  Serial.begin(115200);
  Serial.println("\n\n\nStarting.........");
}

void loop(){
  char customKey = customKeypad.getKey();

  if (customKey){
    Serial.println(customKey);
  }
}
Martin Ayotte
@martinayotte
@mkeyno , do you have external PullUps, even on GPIO5 ? does the 'B' key also working ?
Cristóvão Trevisan
@cristovao-trevisan
Any reason why SPIFFS.open(NAME, "r") should fail for an existing file? Should I retry if there is a fail or can I consider the file does not exists?
Cristóvão Trevisan
@cristovao-trevisan
I'm using 2.3.0, btw
rodrigocirilo
@rodrigocirilo
It is possible to put my esp (which is client and connects on a local server IP (192.168.1.200) to connect in a ddns over the internet?
Currently the program is made server "192.168.1.200" it already connects
Develo
@devyte
Look at the easyddns examples
rodrigocirilo
@rodrigocirilo
Thank you, but ... I need the opposite.
in this example easyddns the esp will be found through the right ddns address!
I need esp to find the server that is running a ddns address.
Develo
@devyte
Isn't that just a normal dns lookup? Hostbyname or something, if mem serves
Clemens Kirchgatterer
@everslick
dynamic dns is just DNS from the hostname lookup POV. but don't confuse wit mDNS, which is a different thing.
rodrigocirilo
@rodrigocirilo
see my esp is a client that connects to a c # application that is the server, the site that is the server is a fixed IP so my search for this IP. has worked. it happens that the ip will not be fixed anymore it will be dynamic and for my esp the server will have to search for a ddns and what I want to know with the noble colleagues is which the command to use. currently it looks like this: Client.connect(server, Port)) the server is a IP,
I want to change this ip to my ddns example
Testddns.dyndns.com