Search found 59 matches
- Tue Apr 04, 2017 1:34 pm
- Forum: Sample Code
- Topic: [Video] ESP32 - DS1307 real time clock
- Replies: 14
- Views: 31140
Re: [Video] ESP32 - DS1307 real time clock
Good idea, but still no go. Below I have my code. I print the time before and after. char buff[100]; time_t now; strftime (buff, 100, "%Y-%m-%dT%H:%M:%S.000", localtime (&now)); printf("Time at first: %s\n",buff); int doWrite = 1; ESP_LOGD(tag, ">> ds1307"); time_t readTime = time(NULL); ESP_LOGD(ta...
- Tue Apr 04, 2017 12:06 am
- Forum: Sample Code
- Topic: [Video] ESP32 - DS1307 real time clock
- Replies: 14
- Views: 31140
Re: [Video] ESP32 - DS1307 real time clock
I've tried a couple of different ways, but I'm not sure how to get seconds since epoch (1970). struct tm tm; tm.tm_sec = bcdToInt(data[0]); tm.tm_min = bcdToInt(data[1]); tm.tm_hour = bcdToInt(data[2]); tm.tm_mday = bcdToInt(data[4]); tm.tm_mon = bcdToInt(data[5]) - 1; // 0-11 - Note: The month on t...
- Mon Apr 03, 2017 4:50 pm
- Forum: Sample Code
- Topic: [Video] ESP32 - DS1307 real time clock
- Replies: 14
- Views: 31140
Re: [Video] ESP32 - DS1307 real time clock
Great video! I am currently using the same code with a DS1339U-33. Everything is working fine, except how do I set the time of the ESP32 after I read it from the RTC after a boot?
Thanks.
Thanks.
- Wed Mar 29, 2017 6:36 pm
- Forum: General Discussion
- Topic: Porting Code and File Organization
- Replies: 7
- Views: 10005
Re: Porting Code and File Organization
I contacted libssh, and they said I need OpenSSL like you said. They said libssh has a strong dependency on libcrypto from OpenSSL or libgcrypt. Are either of these available? Without them, libssh will not compile.
Thank.
Thank.
- Mon Mar 27, 2017 2:57 pm
- Forum: General Discussion
- Topic: Porting Code and File Organization
- Replies: 7
- Views: 10005
Re: Porting Code and File Organization
In libssh/component.mk, try: CODE: SELECT ALL COMPONENT_ADD_INCLUDEDIRS := include This way "libssh/libssh.h" can be found relative to the "components/libssh/include" directory. That removed the missing "libssh/libssh.h" error. It then threw an error fatal error: sys/select.h: No such file or direc...
- Fri Mar 24, 2017 3:26 pm
- Forum: General Discussion
- Topic: Porting Code and File Organization
- Replies: 7
- Views: 10005
Re: Porting Code and File Organization
Angus, Thanks so much. COMPONENT_SRCDIRS worked perfect for me. I am still having a hard time getting the libssh library to work. I created the components directory and put the libssh directory there. my_project/components/libssh I added the component.mk file which contains: COMPONENT_ADD_INCLUDEDIR...
- Wed Mar 22, 2017 11:36 pm
- Forum: General Discussion
- Topic: Porting Code and File Organization
- Replies: 7
- Views: 10005
Porting Code and File Organization
I am using Eclipse to develop, and currently everything is located in the main directory. When I create a subdirectory and move my .c files to that subdirectory, the compiler gives an "undefined reference to function_name()" error. This means, as I understand, that the .c file in the subdirectory is...
- Tue Mar 14, 2017 7:14 pm
- Forum: General Discussion
- Topic: SSH Client
- Replies: 13
- Views: 32072
Re: SSH Client
I followed the example you gave, and it worked for the mongoose. When I tried to do the same for libssh, I ran into issues. I created a directory in my project directory called components, cloned libssh into the components directory, added the file component.mk, and included the library in my projec...
- Fri Mar 10, 2017 2:59 pm
- Forum: General Discussion
- Topic: SSH Client
- Replies: 13
- Views: 32072
Re: SSH Client
They do support telnet, but I am not sure about TLS over telnet. I'll have to confirm. If so, should I use a library like this one? https://github.com/seanmiddleditch/libtelnet How exactly do I get the LibSSH or LibSSH2 library to work on the ESP32? Or any external library for that matter? I use ecl...
- Wed Mar 08, 2017 12:51 am
- Forum: General Discussion
- Topic: SSH Client
- Replies: 13
- Views: 32072
SSH Client
I have have a wireless range extender that I would like to configure with the ESP32. I can ssh into the range extender and update configuration files. Is there anyway to ssh into a linux box from the ESP32? The idea is that I can have the ESP32 look for the default SSID of the range extender. Once i...