These are chat archives for esp8266/Arduino

9th
Aug 2015
Neil Kolban
@nkolban
Aug 09 2015 16:41
Is there a reason that ESP8266mDNS is not using the Espressif SDK supplied functions for mDNS?
Ivan Grokhotkov
@igrr
Aug 09 2015 18:27
regarding warnings in Eclipse — if you can fix them and submit, that's fine. I'm not using Eclipse myself so it's unlikely I will fix them if you report.
re mDNS — our library was written before espressif added mDNS APIs
Neil Kolban
@nkolban
Aug 09 2015 18:29

I was just looking at forking the project just now ... the sort of warnings I get would be fixed by:
From ...
if(_end < _begin && size_to_read > _bufend - _begin) {

To ...
if(_end < _begin && size_to_read > (size_t)(_bufend - _begin)) {

If you are willing to accept these kinds of changes, I'll be happy to assist

Ivan Grokhotkov
@igrr
Aug 09 2015 18:30
ok, that's fine. if you submit that, I'll merge.
Neil Kolban
@nkolban
Aug 09 2015 18:30
awesome ... thank you sir ... I'll start working through the warnings now
Ivan Grokhotkov
@igrr
Aug 09 2015 18:32
regarding SPIFFS — mkspiffs generates an image of SPIFFS filesystem. you can write it to flash using esptool, for instance
this will be integrated into IDE
Neil Kolban
@nkolban
Aug 09 2015 18:32
I am guessing that one needs the address of where the image starts?
Me No Dev
@me-no-dev
Aug 09 2015 18:32
you can find it in the boards.txt
SPIFFS_start
it is different on each option/flash size
Neil Kolban
@nkolban
Aug 09 2015 18:34
I think I will have to study SPIFFS some more before I ask any more questions :-) ... I'll write it up in my notes for the future.
Ive been studying and writing up the Arduino ESP libraries so there should be a ton of new coverage in the next release of the notes.
Neil Kolban
@nkolban
Aug 09 2015 18:58

How does this logic work?

static void twi_delay(unsigned char v){
unsigned int i;
unsigned int reg;
for(i=0;i<v;i++) reg = GPI;
}

The compiler complains that we assign to reg but never read from it ... I'm wonder if its safe to replace "reg = GPI;" with "GPI;"?
Ivan Grokhotkov
@igrr
Aug 09 2015 19:07
or maybe (void) GPI;
Neil Kolban
@nkolban
Aug 09 2015 19:08
I used a #pragma to ignore the error ... I do NOT want to break logic :-)
Okly ... I issues a pull-request ... we now have a 100% clean compile on the Arduino Eclipse 5 small C source file/header changes.
Neil Kolban
@nkolban
Aug 09 2015 19:14
New topic ... on the Eclipse side of the house, I found that the Make system provides a "--jobs" flag that allows compilations to progress in parallel. This allowed me to utilize 100% of my CPU and reduced a complete rebuild of my Sketch and Arduino libraries from 54 seconds down to 12... dramatic improvement.
Ivan Grokhotkov
@igrr
Aug 09 2015 19:53
is there a way to determine number of jobs to run automatically? like 'ncpu' which is available on some flavors of Linux?
too bad parallel build is not available in Arduino
Neil Kolban
@nkolban
Aug 09 2015 20:42
Does the Arduino build make files?