Commit Graph
53 Commits
Author SHA1 Message Date
Mikael Falkvidd 0b9af6d713 Update cast in msg.set (#1130)
A while ago, MySensors changed to use int32_t
instead of long int (and similar for other data
types). This change was not applied to all examples,
causing some examples to fail compilation for
ESP8266 with the following message:

call of overloaded 'set(long int)' is ambiguous

This update changes the casts to match the new style.
This fixes
https://github.com/mysensors/MySensors/issues/1129
Thanks to https://github.com/henfri for reporting.
2018-05-14 21:32:11 +02:00
Marco Bakera f5ed26c778 Fixed some minor typos in comments (#1082)
* Fixed typo in the username
2018-05-06 20:22:56 +02:00
flopp999 6c9be97fa3 Word corrections (#1114)
* Word corrections
* Removed an enter
Thanks @flopp999 !
2018-05-01 16:57:37 +02:00
tekka bb7766197c Consolidate WiFi defines (#1110)
Great work @tekka007
2018-05-01 16:54:43 +02:00
Mikael Falkvidd f2d9f72cf4 Fix spelling mistakes (#1104) 2018-04-09 23:31:50 +02:00
tekka eaf1b9452b ESP32: Support HW (#865)
This fixes https://github.com/mysensors/MySensors/issues/968
2018-04-07 14:46:01 +02:00
Mikael Falkvidd d1aa419efe Remove faulty wiring instructions from ESP gateways (#1100)
This fixes
https://github.com/mysensors/MySensors/issues/1096

https://www.mysensors.org/build/connect_radio
has been updated to include GPIOn instructions
(in addition to the existing Dn instructions).

Thanks to RWoerz for reporting this discrepancy.

Also, the "barebone" boot wiring has been moved to
http://bit.do/stupidurl
2018-04-07 10:42:52 +02:00
thucar 4d90c00f98 MY_GATEWAY_TINYGSM support. GSM gateway using a modem module (#1097)
Added TinyGSM driver and GatewayGSMMQTTClient example
2018-04-04 16:40:11 +02:00
tekka c805f77f20 AVR: Fix OTA logging (#1074) 2018-03-01 20:27:07 +01:00
d00616 fe42dbdcca Nvm fota (#1018)
* New Firmware OTA for NVM/mcuboot (nRF5)

- Support for mcuboot (nRF5)
- Support for run length encoded data
- Support for smaller FIRMWARE_BLOCK_SIZE, if required

* Update NVM

* New MY_LOCK_MCU for NRF5

* Test with Sensebender GW + Sensebender Micro was successful
2018-02-28 20:03:34 +01:00
Mikael Falkvidd 599c0bada6 ESP8266 Gateway examples: clarify inclusion pin (#1065)
The comment for inclusion mode pin and the definition of
MY_INCLUSION_MODE_BUTTON_PIN did not match.

GPIO5 should be safe to use, while GPIO3 is used for the
UART which might result in conflict.

This fixes
https://github.com/mysensors/MySensors/issues/993
2018-02-22 12:04:03 +01:00
tekka b51981ab3d Fix MY_CORE_ONLY: Initialize HW (#1070) 2018-02-20 12:32:03 +01:00
Kartik Arora 14d8accf37 Add URL option for MQTT broker in example sketch (#1033) 2018-01-30 21:04:37 +01:00
Mikael Falkvidd 06269dd949 Fix cppcheck issues (#1036)
Fixes the following cppcheck issues:
examples/SecretKnockSensor/SecretKnockSensor.ino
305	variableScope	398	style
The scope of the variable 'timeDiff' can be reduced.

examples/SensebenderGatewaySerial/SensebenderGatewaySerial.ino
127	variableScope	398	style
The scope of the variable 'led_state' can be reduced.
2018-01-28 09:31:19 +01:00
tekka a9c49f0210 Harmonize debug outputs (#1002) 2017-12-05 04:03:39 +01:00
Mikael Falkvidd 506d23581d Update RelayActuator example (#973)
Based on feedback from skywatch,
https://forum.mysensors.org/post/78896

We'll need to update the wiring instructions on
https://www.mysensors.org/build/relay as well.
2017-11-17 21:18:15 +01:00
Olivier 5164af7edc ESP8266: Fix example compilation error (#932) 2017-09-19 22:48:54 +02:00
d00616 8412a3d360 New OTA debugging and logging feature (#913) (#913) 2017-09-18 20:58:44 +02:00
d00616 1cd2c6df05 Update radio defines in examples (#901) 2017-07-31 18:37:01 +02:00
Patrick Fallberg 3e75b52c33 Fixed indentations using astyle (#890) 2017-07-07 14:36:14 +02:00
Marcelo Aquino 95d7c003cb Fix UDP on Ethernet gateway (#858)
- Fix UDP send
- Add a default value for MY_IP_GATEWAY_ADDRESS and
  MY_IP_SUBNET_ADDRESS, making them optional when using MY_IP_ADDRESS
- Add support for MY_IP_GATEWAY_ADDRESS and MY_IP_SUBNET_ADDRESS to
  W5100
2017-06-13 22:59:01 +02:00
d00616 e6925f69e8 Update more usage of hwGetentropy() (#869)
* Update more usage of hwGetentropy()

* Add hwGetentropy() to Teensy 3.5/3.6
2017-06-03 21:58:40 +02:00
Marcelo Aquino 28c4f3f19e Signing improvements package (#871)
* Signing support with MAX_PAYLOAD>32

Support in the signing backends to handle configurations
where MAX_PAYLOAD is more than 32 bytes.

Fixes #748

* Support big message signatures

Support for signing messages larger than 32 bytes.
This is not fully testable with the current version of
the library but the change would add theoretical support
for signing any sized messages.

Fixes #749

* Have gw properly indicate whitelisting preferences

If the gateway hold a signing whitelist, inform all
nodes of this requirement and not just nodes that hold
whitelists themselves.

Fixes #806

* Harden security

The flag MY_SIGNING_GW_REQUEST_SIGNATURES_FROM_ALL
has been removed. Gateway will now request signatures
from everyone by default.
In addition to this, no nodes in the network will allow
clearing of signing/whitelisting preferences by OTA
commands by default.
If the old behaviour is needed (suitable for gradual
signing roll out and development purposes) a new flag,
MY_SIGNING_WEAK_SECURITY can be set.

Fixes #807

* Signing debug messages rewritten

All signing related debug has been rewritten to
better match other core debug printouts.
Also, backends are updated to have a smaller
implementation delta.

* Simplified signing option implemented

Enable by MY_SIGNING_SIMPLE_PASSWD. Signing, and signing requirements
will be enabled, as will encryption. Whitelisting is optional.
The value provided to MY_SIGNING_SIMPLE_PASSWD is used as HMAC and AES
key. Whitelists use the first 8 bytes of the password and the ninth
byte from the node ID as serial.
Password is required to be at least 8 characters wide. It is zero
padded if it is not long enough to cover the AES (16 bytes) and HMAC
(32 bytes) keys. It is not recommended to have a password shorter than
32 bytes, and there is no need for a password longer than 32 bytes.

* Add documentation section for signing debug

* Add nRF5 encryption to simple signing option

* Restructure MySigning documentation

* Minor fixes for Linux
2017-05-31 17:13:29 +02:00
d00616 6c12dddf5a Enhance randomness (AVR, ESP8266, Linux, NRF5) (#845)
This commit changes the way random numbers are available
with MySensors.

The AVR platform uses a 32 Bit random seed build from a floating
analog pin. The way of the generation of this seed is FIPS 140-2
compliant.

For support MCU with a fast way to generate random data, the
hwGetentropy() command is now available to allow rapid generation
of random data.

The ESP8266 platform uses the internal random source for randomness
for hwGetentropy() and Arduino's random() function.

The NRF5 platform initializes the pseudo random number generator
from internal hardware number generator. The internal AES-ECB unit
generates random data after filling with HWRNG data by AES-CBC.

On Linux getrandom() is implemented via syscall().

signerAtsha204SoftGetNonce speed:
AVR = ~14000us (sha204Soft)
NRF51 = ~152us (AES-CBC), 1739us (old sha204Soft)
NRF52 = ~31us (AES-CBC), 183us (old sha204Soft)
ESP8266 = ~20us (RANDOM_REG32), 380us (old sha204Soft)

All Nonce results tested for FIPS 140-2 compliance successfully.
2017-05-21 14:12:09 +02:00
Olivier e041bf4d74 NRF5: Updates for Jenkins verifier (#852) 2017-05-21 08:41:11 +02:00
Olivier 818f887926 Polishing code (#803) 2017-04-02 20:03:59 +02:00
Patrick Fallberg 7e6db413c7 Security personalizer rewritten (#794)
* Removed ability to lock data section
* Introduced "guided mode" to simplify process
* Refactored the sketch to be less monolithic
* Print details and instructions in tables
* Use device unique ID as serial when
* Calculate and store personalization checksum
* Print serial in a copy+paste friendly manner (fixes #804)
* Clarify meaning of UART confirmation (fixes #805)
2017-04-02 15:37:21 +02:00
Olivier b132a8a81e Transport update (#722)
* Major transport rework

* Adjust signal report calculations

* Minor driver optimizations

* Implement sanity check in legacy RFM69 driver

* Additional RFM69 rework

* RFM95 encryption

* Polishing
2017-03-28 20:31:08 +02:00
Olivier 7824e12823 I2C eeprom write fix for SAMD (#786)
* I2C eeprom write fix for samd

* Implement extEEPROM library for SAMD
2017-03-06 16:45:58 +01:00
Frédéric FRANCE 7358521566 Fix typo in README (#778) 2017-03-01 20:04:17 +01:00
Olivier b69bba485f Revert "Reduce memory footprint" (#763) 2017-01-31 22:31:00 +01:00
FotoFieber 09de6d8075 Reduce memory footprint (#762)
Allows to run this sketch on an AVR 328 with
all sensors enabled.

Changes:
- use F() macro
- use msg_generic instead of individual variables
2017-01-30 16:48:47 +01:00
Olivier 6bad2c721b Consolidate open PRs for bugfix release (#741) 2017-01-16 20:36:15 +01:00
Olivier 9041c8ba3d Fix getControllerConfig() (#737) 2017-01-15 16:27:49 +01:00
Olivier dd9dff77ed Minor optimizations & code harmonization (#708) 2016-12-28 22:47:41 +01:00
Patrick Fallberg 1040fbebc5 Refactor signing backend (#690)
Cleaned up the AES driver and removed some cppcheck isues
in the process.
2016-12-25 16:12:40 +01:00
Patrick Fallberg 8e1ef13804 Repo restyled using astyle (#683)
The rules are in .tools/astyle/config/style.cfg
and can also be reviewed at
https://www.mysensors.org/view/260#coding-guidelines-core-library
2016-12-07 23:44:29 +01:00
Patrick Fallberg ea65c5b150 Move Doxyfile to repository root (#674)
This makes most tools/plugins for Doxygen work without
much adjustment.
Also resolved some Doxygen warnings.
2016-11-29 11:18:49 +01:00
Marcelo Aquino 76dea1532c RPi: Add support for RS485 transport
Remove serial print from MyTransportRS485.cpp to increase speed.
2016-10-21 09:01:37 -02:00
Thomas Mørch ccabd224a8 Updated comments to reflect HW better 2016-10-13 12:01:03 +02:00
petewill a66a469174 Updated LED documentation
Changed the comments for the LEDs to reflect the 2.0 code changes.
2016-10-08 07:15:40 -06:00
Henrik Ekblad 025e197ba8 Fix include for case sensitive systems
Fix proposed by @RB3rg  in #559
2016-10-01 13:59:56 +02:00
Tom d8c45e9f07 V_Light Deprecated
Change V_Light  for V_Status as V_Light is deprecated as per is
ttps://www.mysensors.org/download/serial_api_20

Change S_Light for S_Binary generic.
2016-09-29 20:02:32 +01:00
Thomas Mørch f8c6156057 Updated sketch with analog check (#580) 2016-09-19 21:14:15 +02:00
Thomas Mørch 15b46f8023 Fixes LED issues as discussed in #562
Removing MY_LED_BLINKING_FEATURE, as we now are
using MY_DEFAULT_LED_xx_PIN defines to enable
LED blinking feature.

updated Gateway sketches to not refer to
MY_LED_BLINKING_FEATURE any more

fixes #562
2016-08-20 09:35:49 +02:00
Olivier 0a8fbe5816 Remove SPI.h and EEPROM.h includes (#555)
* Remove duplicate includes

* Reorder SPI.h include
2016-08-14 14:46:05 +02:00
Mikael Falkvidd git@mjo.se 858b80b6a4 Use bool instead of boolean in examples
In the Arduino IDE, boolean is an alias for bool.
The Arduino IDE might deprecate boolean in the future, see
https://github.com/arduino/Arduino/issues/4673 for details.
2016-08-06 12:03:22 +02:00
Thomas Mørch 88e37e3675 Disabled inclusion button defines
As they can be present in HW Variant files, so to
minimize risk of warnings they are not enabled
2016-08-03 22:48:03 +02:00
Thomas Mørch 3ba13f1c8c Added production SensebenderGW sketch
preHwInit also added to hook into core startup
before hwInit is called
2016-08-02 23:39:18 +02:00
Shiny 0a7208ece0 spelling and grammar fix ups (#515)
Signed-off-by: Brenda Wallace <brenda@wallace.net.nz>
2016-07-17 10:28:57 +02:00