Wykres commitów

889 Commity (93afc71e2e17530e51da924eaeb8332dbc6664fe)

Autor SHA1 Wiadomość Data
Jm Casler f75a256631 Merge branch 'master' of https://github.com/mc-hamster/Meshtastic-device 2020-10-07 22:02:59 -07:00
Jm Casler 4f659b7563 Initial check in of HTTPS server for #452
This switches from the espressif web server to esp32_https_server. Both HTTPS and HTTP have been migrated. On board SSL key generation.
2020-10-07 22:02:53 -07:00
Kevin Hester 7a4b8cde11 keep rf95 max power at 20 dBm so users don't smoke their boards 2020-10-08 10:51:31 +08:00
Kevin Hester 113859e791 increase sx1272 max power
+#define MAX_POWER 27
 // if we use 20 we are limited to 1% duty cycle or hw might overheat.  For continuous operation set a limit of 17
+// In theory up to 27 dBm is possible, but the modules installed in most radios can cope with a max of 20.  So BIG WARNING
+// if you set power to something higher than 17 or 20 you might fry your board.
2020-10-08 09:57:59 +08:00
Kevin Hester 023f1c24fb RTC: add notion of 'quality' for different time sources
Allow use of mesh based time until a GPS time arrives
2020-10-08 07:46:20 +08:00
Kevin Hester f00d07baa3 RTC: pull rtc code into own file for cleanup 2020-10-08 07:28:57 +08:00
Kevin Hester 62c228b986 gps: don't stop lock attempts just because the main cpu is sleeping 2020-10-08 06:23:53 +08:00
Kevin Hester 1a3cc40c7e sx1262 better to check for header because preamble might never result in irq 2020-10-08 06:23:05 +08:00
Kevin Hester bdcd5c3981 allow reporting # sats before we ahve a fix 2020-10-08 06:22:25 +08:00
Kevin Hester fc82e872d6 don't require gps to have lock before we'll trust GPS time 2020-10-08 05:23:52 +08:00
Kevin Hester b47c54b5b6 keep lora radio totally unpowered when in deep-sleep 2020-10-07 17:52:44 +08:00
Kevin Hester c0c83ad389 If we are not supposed to share locations make sure phone doesn't either 2020-10-07 17:46:25 +08:00
Kevin Hester eca7242a1f fix NRF52 build 2020-10-07 14:00:59 +08:00
Kevin Hester 269f90c510 Force GPS power to zero when in deep sleep 2020-10-07 13:44:17 +08:00
Kevin Hester 7a5832ab8a SX1262: fix serious bug with detecting if we have a rx packet in progress
Could cause hangs on the way into sleep (and enormous power consumption).
Instead of checking for rx packet length (which only changes at completion)
check if we've received preamble bits but haven't yet received a completed
packet interrupt.

notes:


wait to sleep loop problem
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
Can not send yet, busyRx
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0

vs normal run
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
radio wait to sleep, txEmpty=0
Starting low level send (id=0x53fe1dd0 Fr0xe5 To0xff, WantAck0, HopLim3 encrypted)
Completed sending (id=0x53fe1dd0 Fr0xe5 To0xff, WantAck0, HopLim3 encrypted)
2020-10-07 13:43:51 +08:00
Kevin Hester 044cc26340 #376 use power off command instead of killing gps power per manual 9.5 2020-10-07 11:44:30 +08:00
Kevin Hester 4ccd03623f bug #376: disable the "wake on serial" feature, because it causes
bogus wakes on TBEAMS because the USB->SERIAL chip pulls the RX input
to ground.  This feature is no longer needed because in !isRouter
nodes we force the node to never sleep anyways when on USB power.

    // this doesn't work on TBEAMs when the USB is depowered (causes bogus interrupts)
    // So we disable this "wake on serial" feature - because now when a TBEAM (only) has power connected it
    // never tries to go to sleep if the user is using the API
    // gpio_wakeup_enable((gpio_num_t)SERIAL0_RX_GPIO, GPIO_INTR_LOW_LEVEL);
2020-10-06 14:24:08 +08:00
Kevin Hester 7854a22fbf bug #376 - stop using pmu IRQ - we don't need it and it causes LS wakes 2020-10-06 12:45:19 +08:00
Kevin Hester 943d5cb08d bug #376 we were not staying in light sleep as long as intended 2020-10-06 11:48:53 +08:00
Kevin Hester 7480eb1826 Change to use zeros for timeout values that are 'default' 2020-10-06 09:43:00 +08:00
Kevin Hester c32c97c389 TBEAM 1.1 has an extra controllable LED - blink that also 2020-10-06 08:20:06 +08:00
BeardyWalrus b4b1b24c84 always need double press, even if you dont have a screen 2020-10-05 20:13:04 -04:00
Kevin Hester ef146fc0b5 bug #376 - wip time only mode now works 2020-10-06 06:27:46 +08:00
Kevin Hester f6861a8fe2 bug #376 wip - we now minimize comms to gps to save power 2020-10-06 06:07:30 +08:00
Kevin Hester 736642455f bug #376 wip - we now respect the new gps_operating_mode pref. 2020-10-06 05:34:56 +08:00
Kevin Hester 3c1c11e439 bug #376 wip - we now kill gps power when it is supposed to be asleep 2020-10-05 15:29:26 +08:00
Kevin Hester b072eec4ac wip for #376 2020-10-05 14:43:44 +08:00
BeardyWalrus 4d7cd0a09d conditional on needing ESP32 bluetooth header loaded 2020-10-03 17:23:36 -04:00
BeardyWalrus b38bcffafb Merge branch 'master' of https://github.com/BeardyWalrus/Meshtastic-device 2020-10-03 17:02:19 -04:00
BeardyWalrus 530432411e revised fix for #357
Now supports default password for devices with no display, and override with double press of user button
2020-10-03 17:02:17 -04:00
geeksville bacc6caf04 wip gps power fixes #376 2020-10-01 09:17:43 -07:00
geeksville d66cede7fc Merge branch 'eink' into power 2020-10-01 07:51:01 -07:00
geeksville 3a638090a2 update protos for #376 2020-09-30 07:47:16 -07:00
BeardyWalrus 5150d15997
Merge branch 'master' into master 2020-09-29 19:57:01 -04:00
BeardyWalrus 7d6dbcfa3f Update BluetoothUtil.cpp
fix for #357
use presence of ssd1306 display to set display functionality for bluetooth security.
2020-09-29 19:51:39 -04:00
Kevin Hester cfb9a600e4
Merge branch 'master' into eink 2020-09-29 14:14:10 -07:00
Jm Casler 423cbc2c6d Added frequency information to debug output (#447) and cleanup of screen.cpp and meshwifi.cpp 2020-09-29 00:59:26 -07:00
geeksville 124a82888d add power testing notes for eink 2020-09-28 17:38:36 -07:00
geeksville fec7a6bf17 add air530 gps sleep support 2020-09-28 17:04:19 -07:00
geeksville bc50b39a3b put eink screen to sleep to save power 2020-09-28 16:08:52 -07:00
geeksville a0fd83428f eink use RESET button as regular button instead 2020-09-28 13:10:27 -07:00
geeksville e5d4fbb164 fix pins per email eink 2020-09-28 13:03:54 -07:00
Jm Casler 848760e5bf Set device hostname with hardwire ID #445 2020-09-27 00:55:41 -07:00
Jm Casler 5ebac0cd54 Merge branch 'master' of https://github.com/mc-hamster/Meshtastic-device 2020-09-26 23:38:22 -07:00
Jm Casler 9b4079317b Give more details of why wifi is disconnected 2020-09-26 23:37:58 -07:00
Jm Casler fd62edbcab
Merge branch 'master' into master 2020-09-26 18:44:53 -07:00
Jm Casler b5361ef89f Display gps altitude on display #443 2020-09-26 18:37:51 -07:00
geeksville 648589ed16 translate important parts of the Air530 datasheet to english 2020-09-26 18:16:32 -07:00
geeksville 28ec0e310d make bat voltage sensing work on eink 2020-09-26 18:13:16 -07:00
geeksville 956d9e96f2 Merge branch 'eink' of https://github.com/geeksville/Meshtastic-esp32 into eink 2020-09-26 13:49:54 -07:00
geeksville 266ba03bb7 route debug output back to the CDC-ACM device instead of JLINK 2020-09-26 13:49:22 -07:00
Kevin Hester 04c54840f4
Merge branch 'master' into eink 2020-09-26 12:58:13 -07:00
geeksville d7fbcf89bf cleanup todo eink now ready to merge 2020-09-26 12:36:11 -07:00
geeksville a8b1bc735a remove debugging code eink gps now works 2020-09-26 12:12:50 -07:00
geeksville ba8c640d6e eink leds kinda work now 2020-09-26 10:53:02 -07:00
geeksville d88d2780f4 eink display now kinda works 2020-09-26 09:40:48 -07:00
Jm Casler 6f444ed4b5 Accidently left #include "nimble/BluetoothUtil.h" in screen 2020-09-26 00:03:23 -07:00
Jm Casler 28119bf1bf Fix for #439 and some cleanup 2020-09-26 00:01:02 -07:00
geeksville 2996c7c8e2 Make tcp API now work. Sample usage and caveats below:
Sample usage:

First configure device to use @mc-hamster's new wifi stuff:
meshtastic --set wifi_ssid mylanname --set wifi_password mylanpassword

Then reboot the device (so wifi starts up).

(assuming device was assigned addr 192.168.81.45)
meshtastic --info --host 192.168.81.45
(See the usual device info you previously had to get over USB)

Caveats:

* Currently we are limiting to one active TCP connection open at once, if
you open a new session the old one is closed automatically
* There are no access controls/authentication needed to open a TCP
connection to the device
* Currently main.cpp is kinda dumb about how we should schedule work and
we rely on too many helper loop() functions.  Very soon in my queue
(related to all the other cleanup) is to add a basic notion of coroutines,
so that we can get away from freertos threads and this old school arduino
loop function.  Once that cleanup happens we can the a) have much lower
battery consumption (always) and b) super fast response for all operations.
2020-09-25 16:18:30 -07:00
geeksville d1c3078698 shrink guard for channel settings lock 2020-09-25 12:52:26 -07:00
geeksville 3e5f81bf2a move region into userpreferences, to end region specific firmwares 2020-09-25 12:52:08 -07:00
geeksville 1a064a4666 Merge remote-tracking branch 'root/master' 2020-09-25 09:19:58 -07:00
geeksville 6f77244af3 eink wip notes 2020-09-25 09:14:00 -07:00
geeksville a79aff4778 WIP - I think some pins are wrong, waiting for new schematic 2020-09-24 16:36:07 -07:00
Jm Casler fed4dfd410
Merge pull request #435 from mc-hamster/master
Update dev-wifi from my fork
2020-09-24 11:15:47 -07:00
Jm Casler 0d3b8bdb22 Note not to file bugs 2020-09-24 11:07:30 -07:00
Jm Casler ce7fa65595 David's latest changes to the HTML UI 2020-09-23 19:04:12 -07:00
geeksville 9c0a0ad220 Add stubs so that portduino can build with wifi. cc @mc-hamster 2020-09-23 17:22:17 -07:00
Jm Casler b39f6c96bd Merge remote-tracking branch 'origin/dev-wifi' 2020-09-22 22:00:07 -07:00
Jm Casler 10b24c0269 Initial check-in of David's UI 2020-09-22 21:01:31 -07:00
geeksville 3352fae64c fix #371 allow button while using API. also don't let tbeams sleep if they have USB power 2020-09-21 12:41:39 -07:00
comgram 55cb0c52ee Add Korean Frequency 2020-09-21 16:10:20 +09:00
Jm Casler d890068acb dev-wifi: Detailed error reporting of reason why WiFi didn't connect #424 2020-09-19 21:58:21 -07:00
Jm Casler 5cbe06c2b0
Merge pull request #419 from geeksville/dev-wifi
Add API server on port 4403 (kinda a WIP, seems to work but I haven't
2020-09-19 17:25:24 -07:00
Jm Casler 377f0bda5d Add more detail on the connection status on the screen #422 2020-09-19 17:15:03 -07:00
Jm Casler 464a42258f Fix for "Wifi in station mode sometimes enters loops of repeatedly joining... #420"
Fix for Wifi in station mode sometimes enters loops of repeatedly joining... #420
2020-09-19 16:38:59 -07:00
geeksville 9e9c50e6d8 Add API server on port 4403 (kinda a WIP, seems to work but I haven't
finished the python client code)
2020-09-19 12:54:49 -07:00
Jm Casler 945f726b65 Merge branch 'master' of https://github.com/mc-hamster/Meshtastic-device 2020-09-19 12:50:46 -07:00
Jm Casler 7c44daf8f4 pushing my chances to personal branch so i can get the changes from the laptop 2020-09-19 12:50:43 -07:00
Jm Casler c57a9a8613 Update from my laptop 2020-09-19 11:24:55 -07:00
geeksville 3c0429deee Add new factory_reset preferences option clients can set 2020-09-19 11:19:42 -07:00
Jm Casler 6e3b22c624 Stub for a handler of the root (/) of the web server with a html table and form for chat 2020-09-18 20:42:35 -07:00
Jm Casler 82fbedbf41 Auto formatting of meshwifi.cpp 2020-09-18 18:51:42 -07:00
Jm Casler 65fc1cf4a6 Moved handleDNSResponse into handleWebResponse and used the autoformatter 2020-09-18 18:29:16 -07:00
Jm Casler 4d72afebe6 Soft AP and basic captive portal done. 2020-09-18 18:16:58 -07:00
Jm Casler 362d8cb831
Merge branch 'master' into dev-wifi 2020-09-18 18:02:56 -07:00
Jm Casler b203c95dd1 changes for soft ap + captive portal 2020-09-18 15:33:03 -07:00
geeksville 6e5e5822aa Make wifi optional and exclude from nrf52 builds 2020-09-18 10:48:39 -07:00
Kevin Hester 5fb0bf2575
Merge branch 'master' into anz 2020-09-18 10:19:43 -07:00
geeksville d3e28e3e2c Merge branch 'dev' 2020-09-17 11:20:41 -07:00
r51n 91305c2c84
add AU/NZ channel definitions 2020-09-17 12:02:38 +00:00
Jm Casler 48dd6d388d Merge branch 'master' of https://github.com/mc-hamster/Meshtastic-device 2020-09-16 23:16:19 -07:00
Jm Casler 64710a6a04 renamed reconnectWiFi to initWifi 2020-09-16 23:16:11 -07:00
Jm Casler c83ff03d66
Merge pull request #4 from meshtastic/master
Updating form head
2020-09-16 22:51:19 -07:00
Jm Casler 73b47a78aa Clean up and added comments about the esp32 sdk bug 2020-09-16 22:31:07 -07:00
Jm Casler 493b25f23e Final checkin of WiFi and basic HTTP server 2020-09-16 20:15:00 -07:00
geeksville fc20f658e6 Fix #362 by @a-f-G-U-C - I was mispelling NMEA ;-) 2020-09-16 09:22:03 -07:00
geeksville 8e988cc926 fix #397 from @a-f-G-U-C - bogus GPS positions during locking could be reported
btw - from my read of the NMEA, the lowest value that means 'has a valid
position' is 1 not 2.  But I only know this because you pointed me at
it ;-)

Thanks!
2020-09-16 09:18:44 -07:00
geeksville 8c240b59f6 fix #393. immediately save node db to disk if user changes name 2020-09-16 09:08:35 -07:00
geeksville 3e64d8439d Merge branch 'master' into dev 2020-09-15 21:13:24 -07:00
geeksville 435c955acd make hash prototype a bit stricter 2020-09-15 21:05:57 -07:00
Jm Casler c656a95a84
Merge pull request #3 from meshtastic/master
Update from meshtastic main
2020-09-15 20:34:30 -07:00
Jm Casler 27ad8472c1 remove ssid info from configuration.h 2020-09-15 20:24:58 -07:00
Jm Casler 3fcd4a61aa commenting out the strcpy to manually set the wifi info. 2020-09-15 20:24:03 -07:00
geeksville c6d93d1a28 fix #346 limit tx power in japan 2020-09-15 18:54:50 -07:00
geeksville 7d4058f49d let users set 20 dBm if they wish 2020-09-15 18:00:21 -07:00
geeksville 31fc8fafec make default power level radio chipset specific 2020-09-15 17:55:33 -07:00
Jm Casler 066d9d48a4 New method to deinit the wifi stack. 2020-09-14 20:27:49 -07:00
Jm Casler f5c939fb10 Fix to turn WiFi back on after the bluetooth radio is reenabled. 2020-09-13 22:22:49 -07:00
Jm Casler e508306395 Refactoring to break out HTTP from WiFi 2020-09-13 16:58:36 -07:00
Jm Casler f129b458ad Initial Checkin for WiFi and HTTP Server Framework 2020-09-12 21:43:41 -07:00
Jm Casler b6f71ca1db Update screen.cpp for for crash when gps gets lock
Update screen.cpp for for crash when gps gets a lock
2020-09-11 22:17:45 -07:00
geeksville 92df77f228 Merge remote-tracking branch 'root/master' into dev 2020-09-11 18:15:13 -07:00
geeksville 1cd81208c0 Merge remote-tracking branch 'root/master' 2020-09-10 10:11:15 -07:00
geeksville ee27c15c2c likely fix for bug #373. fix #339. great gps fixes from @a-f-G-U-C
fixes described in bug #376
2020-09-10 09:25:10 -07:00
Garret Kelly 48256d6e9e Fix compilation without a BUTTON_PIN definition 2020-09-08 15:22:49 -04:00
geeksville c007302564 fix #363 gps altitude - based on tip by @a-f-G-U-C 2020-09-08 10:28:53 -07:00
geeksville 0a9f7147f3 probably fix #341 enable internal pullup on lora-v2 button 2020-09-08 10:25:37 -07:00
geeksville 46ba36511a Merge branch 'portduino' into dev
# Conflicts:
#	platformio.ini
2020-09-07 16:31:17 -07:00
geeksville f3d38d84c9 fix nrf52 build 2020-09-07 13:03:37 -07:00
geeksville f8bb6bbcb4 try to bang on SPI from simulator 2020-09-06 16:32:13 -07:00
geeksville e0d5b9dce1 use simradio on portduino 2020-09-06 16:09:07 -07:00
geeksville 94e4b30125 add crude sim getmacaddr 2020-09-06 16:07:32 -07:00
geeksville 2a067e7f6b make gps optional. Portduino almost works in sim! 2020-09-06 14:45:43 -07:00
geeksville b8d39845cf portduino now links! 2020-09-06 09:24:08 -07:00
Jm Casler 49dea6d6bd Update Screen.cpp
Added commnets for concepts for future TODO work.
2020-09-05 22:36:57 -07:00
Jm Casler 7d4c6c7086 Update Screen.cpp
- Changed "No Satellite Lock" to "No GPS Lock"
- Fixed bug when there's no battery. Now shows "USB"
- Tested on tlora-v1
2020-09-05 14:41:00 -07:00
geeksville fefd3d78f3 Portduino WIP now compiles but does not link 2020-09-05 12:34:48 -07:00
Jm Casler f41a77c46d Initial add of status screen
Initial add of the status screen.

TODO:
- Get status of the BT Radio
- Display something on line 3
2020-09-05 09:30:18 -07:00
geeksville 6a475d8288 WIP 2020-09-04 17:23:17 -07:00
geeksville c629b94333 portduino WIP 2020-09-04 15:03:22 -07:00
geeksville 6cdaf8c600 fix #349 channel suffix letter didn't match between device and phone 2020-08-30 12:38:15 -07:00
geeksville c370eb4a88 allow restarting failed upgrades (fixes an android autobug report) 2020-08-30 12:21:05 -07:00
geeksville 8dc4492ba3 add taiwan frequencies 2020-08-30 12:20:43 -07:00
geeksville 901cc536ef less logspam 2020-08-29 15:17:32 -07:00
geeksville dffb6c2f06 If display is on on the @BigCorvus board and we xmit the board browns out? 2020-08-28 17:38:23 -07:00
geeksville 7f214ffbb0 TFT kinda correct now - but slow because of bit banging 2020-08-28 15:33:33 -07:00
geeksville e049eac38a TFT display kinda draws stuff (badly) 2020-08-28 15:06:52 -07:00
geeksville 338445d175 basic init of the Corvus TFT display works 2020-08-28 14:24:22 -07:00
geeksville 79498580b1 If LORA32 battery voltage is super low, assume no battery installed 2020-08-27 14:46:59 -07:00
geeksville af046e7dbd bug #322 - ttgo lora32 deep sleep
oh - I think I found the problem (probably)!  we were isolating gpio12 (which isn't used on other boards) to save power during sleep.  gpio12 is the button for this board. @thomslik would you mind pulling this commit and seeing if it works better?
2020-08-26 14:00:10 -07:00
geeksville 5c40378805 fix #336 don't send battery status on nodes without batteries 2020-08-25 13:00:55 -07:00
geeksville 780b7e3628 don't show battery status on boards that can't sense that #336 2020-08-25 12:48:47 -07:00
geeksville f62e6793c5 Fix #333 screens were redrawing when they should not
thanks @drewsed for the clear report - made it easy to repro/fix
due to refactoring/cleanup a couple of weeks back
2020-08-25 12:08:18 -07:00
geeksville de196810a2 add debugging for SNR values on SX1262 2020-08-25 12:06:36 -07:00
geeksville 7b09fbe049 fix #327 side effect noticed by @smarti2019 2020-08-22 09:06:54 -07:00
geeksville a90bab5455 this seems bad - this value was not inited if it wasn't in bss 2020-08-21 10:56:54 -07:00
geeksville ff885ef215 Merge remote-tracking branch 'root/post1' 2020-08-21 10:50:49 -07:00
geeksville d7a1cef046 fix #327 always factory reset the GPS once 2020-08-21 10:14:03 -07:00
geeksville ca75dcd64d Add support for SX1262 based TBEAMs, see below for more details.
We probe dynamically for the SX1262 or RF95 based radios on TBEAM1.0
boards now.  If either is present it will be used.
2020-08-20 15:42:36 -07:00