Skip to content

Commit 7d96ee3

Browse files
committed
V3.11.3 release - rollup of changes from dev branch
1 parent 964178c commit 7d96ee3

14 files changed

+421
-229
lines changed

Adafruit_MCP9808.cpp

Lines changed: 0 additions & 117 deletions
This file was deleted.

Adafruit_MCP9808.h

Lines changed: 0 additions & 65 deletions
This file was deleted.

CHANGELOG

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,38 @@
11
Change Log
22

3-
SC: 20151011
3+
SCL 20160125
4+
-> promoted vD3.11.3 to v3.11.3 stable
5+
6+
vD3.11.3 SCL 20160125
7+
- replace Adafruit_MCP9808 with new MCP9808 code
8+
- fix bug handling negative temperatures from MCP9808
9+
10+
vD3.11.2 SCL 20160120
11+
- fix error displaying negative temperatures... extra - sign leading decimals when negative temperature
12+
13+
vD3.11.1 SCL 20160120
14+
- fix bug in handling negative temperatures from DS3231
15+
16+
vD3.11.0 SCL 20160112
17+
- added RAPI_I2C. Serial RAPI now enabled by RAPI_SERIAL.
18+
*WARNING* RAPI_I2C not tested yet and probably doesn't work
19+
both RAPI_I2C and RAPI_SERIAL may be enabled simultaneously
20+
- call RapiSendEvseState() if POST error
21+
- fix bug, wasn't calling RapiSendEvseState() if HardFault()
22+
- in J1772EvseController::Init() - call RapiSendCommand() with EVSE_STATE_UNKNOWN
23+
24+
SCL 20160111
25+
- change VOLT_PIN to PILOT_PIN
26+
27+
SCL 20151211
28+
- change static inline to inline for wiresend/wirerecv() to fix compiler error
29+
in Arduino 1.6.6
30+
31+
SCL 20151125
32+
- added i2caddr.h
33+
- take Wire.begin() out of RTClib.cpp
34+
35+
SCL: 20151011
436
v3.10.4
537
- vD3.10.4 promoted to stable
638

I2CIO.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ int I2CIO::begin ( uint8_t i2cAddr )
5858
{
5959
_i2cAddr = i2cAddr;
6060

61-
Wire.begin ( );
61+
//don't need - open_evse.ino does it Wire.begin ( );
6262

6363
_initialised = Wire.requestFrom ( _i2cAddr, (uint8_t)1 );
6464

J1772EvseController.cpp

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ uint32_t MovingAverage(uint32_t samp)
140140
#endif // AMMETER
141141

142142
J1772EVSEController::J1772EVSEController() :
143-
adcPilot(VOLT_PIN)
143+
adcPilot(PILOT_PIN)
144144
#ifdef CURRENT_PIN
145145
, adcCurrent(CURRENT_PIN)
146146
#endif
@@ -191,7 +191,9 @@ void J1772EVSEController::Reboot()
191191
void J1772EVSEController::DisabledTest_P(PGM_P message)
192192
{
193193
g_OBD.LcdMsg_P(g_psDisabledTests, message);
194+
#ifndef NOCHECKS
194195
delay(SHOW_DISABLED_DELAY);
196+
#endif
195197
}
196198

197199
void J1772EVSEController::ShowDisabledTests()
@@ -272,6 +274,7 @@ void J1772EVSEController::HardFault()
272274
{
273275
SetHardFault();
274276
g_OBD.Update(OBD_UPD_HARDFAULT);
277+
RapiSendEvseState();
275278
while (1) {
276279
ProcessInputs(); // spin forever or until user resets via menu
277280
// if we're in P12 state, we can recover from the hard fault when EV
@@ -449,7 +452,7 @@ void J1772EVSEController::Disable()
449452
chargingOff();
450453
g_OBD.Update(OBD_UPD_FORCE);
451454
#ifdef RAPI
452-
g_ERP.sendEvseState();
455+
RapiSendEvseState();
453456
#endif // RAPI
454457
}
455458
}
@@ -472,7 +475,7 @@ void J1772EVSEController::Sleep()
472475

473476
g_OBD.Update(OBD_UPD_FORCE);
474477
#ifdef RAPI
475-
g_ERP.sendEvseState();
478+
RapiSendEvseState();
476479
#endif // RAPI
477480
// try to prevent arcing of our relay by waiting for EV to open its contacts first
478481
// use the charge end time variable temporarily to count down
@@ -773,6 +776,11 @@ uint8_t J1772EVSEController::doPost()
773776

774777
void J1772EVSEController::Init()
775778
{
779+
m_EvseState = EVSE_STATE_UNKNOWN;
780+
m_PrevEvseState = EVSE_STATE_UNKNOWN;
781+
782+
RapiSendEvseState(0);
783+
776784
// read settings from EEPROM
777785
uint16_t rflgs = eeprom_read_word((uint16_t*)EOFS_FLAGS);
778786

@@ -879,10 +887,6 @@ void J1772EVSEController::Init()
879887
m_NoGndStart = 0;
880888
#endif // ADVPWR
881889

882-
m_EvseState = EVSE_STATE_UNKNOWN;
883-
m_PrevEvseState = EVSE_STATE_UNKNOWN;
884-
885-
886890
#ifdef ADVPWR
887891

888892
#ifdef FT_READ_AC_PINS
@@ -911,6 +915,7 @@ void J1772EVSEController::Init()
911915
if (fault) {
912916
#ifdef UL_COMPLIANT
913917
// UL wants EVSE to hard fault until power cycle if POST fails
918+
RapiSendEvseState();
914919
while (1) { // spin forever
915920
ProcessInputs();
916921
}
@@ -1357,7 +1362,7 @@ if (TempChkEnabled()) {
13571362
}
13581363

13591364
#ifdef RAPI
1360-
g_ERP.sendEvseState();
1365+
RapiSendEvseState();
13611366
#endif // RAPI
13621367
#ifdef SERDBG
13631368
if (SerDbgEnabled()) {

LiquidTWI2.h

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,6 @@
4343
// (the Panelolu2 encoder bits are subset of these bits)
4444
#define ALL_BUTTON_BITS (BUTTON_UP|BUTTON_DOWN|BUTTON_LEFT|BUTTON_RIGHT|BUTTON_SELECT)
4545

46-
#define MCP23008_ADDRESS 0x20
47-
4846
// registers
4947
#define MCP23008_IODIR 0x00
5048
#define MCP23008_IPOL 0x01
@@ -58,8 +56,6 @@
5856
#define MCP23008_GPIO 0x09
5957
#define MCP23008_OLAT 0x0A
6058

61-
#define MCP23017_ADDRESS 0x20
62-
6359
// registers
6460
#define MCP23017_IODIRA 0x00
6561
#define MCP23017_IPOLA 0x02
@@ -180,7 +176,6 @@ class LiquidTWI2 : public Print {
180176
#endif //defined(MCP23017)&&defined(MCP23008)
181177
}
182178

183-
184179
private:
185180
void send(uint8_t, uint8_t);
186181
#ifdef MCP23017

0 commit comments

Comments
 (0)