1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-19 23:22:16 +03:00

Add missing license headers (#8630)

This commit is contained in:
david gauchard 2022-07-09 19:02:58 +02:00 committed by GitHub
parent 00f5f2acc4
commit a2982f96a4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 94 additions and 2 deletions

View File

@ -1,3 +1,25 @@
/*
LwipIntf.cpp
Arduino interface for lwIP generic callbacks and functions
Original Copyright (c) 2020 esp8266 Arduino All rights reserved.
This file is part of the esp8266 Arduino core environment.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
extern "C" extern "C"
{ {

View File

@ -1,3 +1,25 @@
/*
LwipIntf.h
Arduino interface for lwIP generic callbacks and functions
Original Copyright (c) 2020 esp8266 Arduino All rights reserved.
This file is part of the esp8266 Arduino core environment.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#ifndef _LWIPINTF_H #ifndef _LWIPINTF_H
#define _LWIPINTF_H #define _LWIPINTF_H
@ -28,16 +50,21 @@ public:
IPAddress& netmask, IPAddress& dns1); IPAddress& netmask, IPAddress& dns1);
String hostname(); String hostname();
bool hostname(const String& aHostname) bool hostname(const String& aHostname)
{ {
return hostname(aHostname.c_str()); return hostname(aHostname.c_str());
} }
bool hostname(const char* aHostname); bool hostname(const char* aHostname);
// ESP32 API compatibility // ESP32 API compatibility
bool setHostname(const char* aHostName) bool setHostname(const char* aHostName)
{ {
return hostname(aHostName); return hostname(aHostName);
} }
// ESP32 API compatibility
const char* getHostname(); const char* getHostname();
protected: protected:

View File

@ -1,3 +1,25 @@
/*
LwipIntfCB.cpp
network generic callback implementation
Original Copyright (c) 2020 esp8266 Arduino All rights reserved.
This file is part of the esp8266 Arduino core environment.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#include <LwipIntf.h> #include <LwipIntf.h>
#include <Schedule.h> #include <Schedule.h>

View File

@ -1,9 +1,30 @@
/*
LwipIntfDev.h
Arduino network template class for generic device
Original Copyright (c) 2020 esp8266 Arduino All rights reserved.
This file is part of the esp8266 Arduino core environment.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
#ifndef _LWIPINTFDEV_H #ifndef _LWIPINTFDEV_H
#define _LWIPINTFDEV_H #define _LWIPINTFDEV_H
// TODO: // TODO:
// remove all Serial.print
// unchain pbufs // unchain pbufs
#include <netif/ethernet.h> #include <netif/ethernet.h>