mirror of https://github.com/noisymime/Arduino.git
Originating each outgoing network connection from a different source port (in the Client class of the Ethernet library).
Updating readme and todo.
This commit is contained in:
parent
19c191e002
commit
a4b52f20b5
|
@ -8,6 +8,8 @@ extern "C" {
|
||||||
#include "Client.h"
|
#include "Client.h"
|
||||||
#include "Server.h"
|
#include "Server.h"
|
||||||
|
|
||||||
|
uint16_t Client::_srcport = 0;
|
||||||
|
|
||||||
Client::Client(uint8_t sock) {
|
Client::Client(uint8_t sock) {
|
||||||
_sock = sock;
|
_sock = sock;
|
||||||
}
|
}
|
||||||
|
@ -29,8 +31,10 @@ uint8_t Client::connect() {
|
||||||
if (_sock == 255)
|
if (_sock == 255)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
_srcport++;
|
||||||
|
|
||||||
// XXX: what port should we connect from?
|
// XXX: what port should we connect from?
|
||||||
socket(_sock, Sn_MR_TCP, _port, 0);
|
socket(_sock, Sn_MR_TCP, _port, 1024 + _srcport);
|
||||||
|
|
||||||
if (!::connect(_sock, _ip, _port))
|
if (!::connect(_sock, _ip, _port))
|
||||||
return 0;
|
return 0;
|
||||||
|
|
|
@ -5,6 +5,7 @@
|
||||||
|
|
||||||
class Client : public Print {
|
class Client : public Print {
|
||||||
private:
|
private:
|
||||||
|
static uint16_t _srcport;
|
||||||
uint8_t _sock;
|
uint8_t _sock;
|
||||||
uint8_t *_ip;
|
uint8_t *_ip;
|
||||||
uint16_t _port;
|
uint16_t _port;
|
||||||
|
|
|
@ -65,7 +65,10 @@ UPDATES
|
||||||
any pulse that had already started when the function was called).
|
any pulse that had already started when the function was called).
|
||||||
* Fixing bug in random() that limited the ranges of values generated. Thanks
|
* Fixing bug in random() that limited the ranges of values generated. Thanks
|
||||||
to Mikal Hart.
|
to Mikal Hart.
|
||||||
|
* Modifying delay() to pause for at least the given number of milliseconds.
|
||||||
* Fixing bug in Ethernet library that interfered with use of pins 8 and 9.
|
* Fixing bug in Ethernet library that interfered with use of pins 8 and 9.
|
||||||
|
* Originating each outgoing network connection from a different port (in the
|
||||||
|
Client class of the Ethernet library). Thanks to Paul and joquer.
|
||||||
* Modifying the core, libraries, and bootloader source to support the
|
* Modifying the core, libraries, and bootloader source to support the
|
||||||
ATmega328, but not yet including it in boards menu.
|
ATmega328, but not yet including it in boards menu.
|
||||||
* Updating ATmega168 bootloader to work with standard distributions of avrdude
|
* Updating ATmega168 bootloader to work with standard distributions of avrdude
|
||||||
|
|
13
todo.txt
13
todo.txt
|
@ -1,13 +1,12 @@
|
||||||
0013 arduino
|
0013 arduino
|
||||||
|
|
||||||
Fix TICR0 for ATmega8.
|
|
||||||
Fix delay() comparison to use <= not <.
|
|
||||||
Ethernet library should use a different source port for each outgoing Client connection: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1227978344
|
Ethernet library should use a different source port for each outgoing Client connection: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1227978344
|
||||||
Support atmega328: http://spiffie.org/know/arduino_328/
|
Support atmega328: http://spiffie.org/know/arduino_328/
|
||||||
- add atmega328 to avrdude.conf (on Windows)
|
- add atmega328 to avrdude.conf (on Windows)
|
||||||
|
|
||||||
AVR
|
AVR
|
||||||
|
|
||||||
|
Make Client::_srcport static? http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1227735530
|
||||||
Allow hardcoding of R/W line to ground with LiquidCrystal library.
|
Allow hardcoding of R/W line to ground with LiquidCrystal library.
|
||||||
Improve shiftOut() performance: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1216659239/0
|
Improve shiftOut() performance: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1216659239/0
|
||||||
Add String library.
|
Add String library.
|
||||||
|
@ -123,6 +122,16 @@ Document Wire.endTransmission() return values: http://www.arduino.cc/cgi-bin/yab
|
||||||
|
|
||||||
DOCUMENTATION / EXAMPLES
|
DOCUMENTATION / EXAMPLES
|
||||||
|
|
||||||
|
Photos:
|
||||||
|
- Loop
|
||||||
|
- Analog Input (potentiometer and LDR on analog input 0)
|
||||||
|
Consistency:
|
||||||
|
- ledpin vs. ledPin
|
||||||
|
- value vs. val
|
||||||
|
Add a Brightness example where an analog input controls the analog output.
|
||||||
|
Graph example should use an intermediate variable.
|
||||||
|
Button example says pin 7 but uses pin 2.
|
||||||
|
Split Loop example in two (one that does loops, another that does arrays).
|
||||||
Add LiquidCrystal library examples.
|
Add LiquidCrystal library examples.
|
||||||
Add Ethernet library examples.
|
Add Ethernet library examples.
|
||||||
Add Wire library examples.
|
Add Wire library examples.
|
||||||
|
|
Loading…
Reference in New Issue