Commit Graph

50 Commits

Author SHA1 Message Date
Hubert Chrzaniuk
6a92a7261e [EGD-2962] Refactor / improve URC handling (#947)
- QIND URC has been extended to support FOTA reply
 - added support for CLIP, CMTI and POWERED DOWN URCs
 - added support for URC responses codes handling
 - created URCHandler abstraction and moved out URC handling from
   cellular service code
 - URC objects are now created by factory on a basis of URC head, rather
   than previous approach where they were created a priori
 - Renamed classes to be consistent with rest of the project
2020-11-05 11:52:39 +01:00
Radoslaw Wicik
2276ceed67 [EGD-3743] Update copyrights in fies 2020-10-20 12:55:10 +02:00
Maciej Gibowicz
d5b0283a0c [EGD-4038] handling incoming calls and sms in sleep mode (#819) 2020-10-19 13:25:39 +02:00
kkleczkowski
4fa2e8d033 [EGD-4101] Temporary removed SMS memory setting. (#850)
Co-authored-by: Kuba Kleczkowski <dd>
2020-10-16 12:36:28 +02:00
Adam
f5f27d642f EGD-2955 EGD-3588 Timers fully refactored & updated (#721)
* Timers now are Application thread safe
* Timers now have consistent API independend of Application (no more c style timers)
* Timers can have either: callback or override onTimer() method - this
  way we can create more complicated timers or just use existing ones
* gui::Timer added via adapter class GuiTimer to decouple sys::Timer
  with gui::Timer
* Fixed race in wrapper
* Updated docs
* fixed using std and cpp_freertos and DataReceivedHandler hidden in Application.hpp
2020-10-02 14:04:57 +02:00
kkleczkowski
250e7ea9c0 Egd 2914 ussd (#729)
* [EGD-2914] Window + base API.

* [EGD-2914] USSD test window changed.

* [EGD-2914] CMUX frames deserialised in dlc channel.

* [EGD-2914] USSD session.

* [EGD-2914] CUSD urc handler.

* [EGD-2914] Simplified USSD test window, sms storage command.

* [EGD-2914] Setting sms storage at modem init.

* [EGD-2914] Changelog.

* [EGD-2914] Style fix.

* [EGD-2914] Style fix again.

* [EGD-2914] Cleanup.

* [EGD-2914] PR applied.

* [EGD-2914] Rebase fixes.

* [EGD-2914] Style fix.

Co-authored-by: Kuba Kleczkowski <dd>
2020-10-01 14:30:22 +02:00
RobertPiet
82fb697c24 [EGD-2460] protection at the moment of conversion added: exception handling or parameter checkup
[EGD-2460] additional stoi/stoul protected; usage of magin_enum; review issues resolved

[EGB-2460] added return when exception caught as mention by Radek
2020-09-11 14:37:56 +02:00
Tomasz Sobkowiak
45773ddfdf [EDG-3415] Handle new line when entering text 2020-09-04 13:12:02 +02:00
alek
9821cd77c6 [EGD-3558] remove memalloc 2020-09-04 11:45:50 +02:00
Alek Rudnik
b4ec5eafb0 [EGD-3384] remove .at from TS0710 (#508) 2020-07-08 12:13:35 +02:00
kkleczkowski
e46d2a2829 Egd 3244 antenna manager (#490)
* [EGD-3244] Service antenna + utils State.

* [EGD-3244] CellularAPI + at::response.

* [EGD-3244-antenna-manager] Changes in application Antenna.

* [EGD-3244-antenna-manager] Changes in antenna app ( antenna switch multicast ).

* [EGD-3244-antenna-manager] Changed Antenna app GUI.

* [EGD-3244-antenna-manager] Basic algorithm.

* [EGD-3244-antenna-manager] Fixes in algorithm.

* [EGD-3244-antenna-manager] Small fixes + service blocking.

* [EGD-3244-antenna-manager] Little cleanup.

* [EGD-3244-antenna-manager] Restored Cellular call in Application Antenna.

* [EGD-3244-antenna-manager] Style fix.

* [EGD-3244-antenna-manager] Sewrvice antenna disabled.

* [EGD-3244-antenna-manager] PR suggestions + linux buil fixed.

* [EGD-3244-antenna-manager] Updated changelog

* [EGD-3244-antenna-manager] Style fix.

* [EGD-3244-antenna-manager] Fixed submodule.

* [EGD-3244-antenna-manager] PR suggestions + toNumeric UT.

* [EGD-3244-antenna-manager] PR suggstions again.

Co-authored-by: Kuba Kleczkowski <dd>
2020-07-07 10:54:47 +02:00
Radoslaw Wicik
806902c1df [EGD-3067] Add FOTA window 2020-06-23 16:11:38 +02:00
kkleczkowski
b70ad6c5fc Egd 3196 small cellular refactor (#365)
* [EGD-3196] Fixed fatals in cellular.

* [EGD-3196] Fixed sms sending.

* [EGD-3196] Fixed timeout in ConfProcedure.

* [EGD-3196] Board type moved to Event Manager.

* [EGD-3196] Event Manager API renamed.

* [EGD-3196] Misiing files.

* [EGD-3196] Fixed modem status message, return code in magnetometer driver, case in modem init procedure.

* [EGD-3196] PR suggestions applied.

* [EGD-3196] Style fix.

* [EGD-3196} GetBoardName -> c_str();

* [EGD-3196] Style fix.

* [EGD-3196] PR suggestions added.

* [EGD-3196] Style fix...

* [EGD-3196] Style fix again.

Co-authored-by: Kuba Kleczkowski <dd>
2020-05-21 16:56:24 +02:00
Kuba Kleczkowski
d8a9d30c8c [EGD-2911-modem-init-rework] PR applied. 2020-05-11 14:04:31 +02:00
Mateusz Grzywacz
192d7c1225 [EGD-2911] modem init - delay URCs until needed 2020-05-11 14:04:31 +02:00
Mateusz Grzywacz
40471b779e [EGD-2911] modem init rework - T3/T4/Linux cold/hot start 2020-05-11 14:04:31 +02:00
Adam Dobrowolski
d204f23859 EGD-2911 Fixed timeout in Baud detection 2020-05-11 14:04:31 +02:00
Adam Dobrowolski
2a432e1891 EGD-2911 changed baudrate detection 2020-05-11 14:04:31 +02:00
Kuba Kleczkowski
6ebae24abd [EGD-2911-modem-init-rework] modem init fixes (cold start) & missing Linux files/implementation 2020-05-11 14:04:31 +02:00
Kuba Kleczkowski
e444bd9ade [EGD-2911-modem-init-rework] Modem power-up hardware specific for T3, T4 & init fixes 2020-05-11 14:04:31 +02:00
Marcin Smoczyński
c47923d70a [EGD-3107] Call number validation
Use specialized class to to pass phone number between apps and services
instead of ambigious std::string. Introduced class (utils::PhoneNumber)
wraps calls to libphonenumber providing more convienient interface.
However using libphonenumber directly may be resource hungry in terms
of stack, heap and cpu usage, so helper class has been introduced to
pass information about phone numbers (utils::PhoneNumber::View). It is
designed to maintain integrity thus can be created from an instance of
utils::PhoneNumber only or moved/copied to.

Add new field to the calllog db holding e164 formatted number. Both
entered and e164 numbers will be needed to be able to match with
contacts correctly.

Add constexpr information about country codes (utils::country).
2020-05-05 00:51:53 +02:00
Radoslaw Wicik
49ca4257da [EGD-3151] Add fixes for SIM detection
Add proper passing SERIAL_PORT info
Convert cmux to unique_ptr in module-cellular
2020-04-27 17:24:24 +02:00
kkleczkowski
b7312fbf07 [EGD-3050-antenna-app-improvements] Added new window in antenna test app, added new command in service-cellular. (#281)
Co-authored-by: Kuba Kleczkowski <dd>
2020-04-09 13:41:43 +02:00
Adam Dobrowolski
106220d75b [FIX] '%s' check build-linux fail fixed 2020-04-08 14:00:45 +02:00
Adam Dobrowolski
abe6813ce6 EGD-3026 Wall Werror and Wextra added to project 2020-03-24 14:17:12 +01:00
Adam Dobrowolski
e4de2a2410 SIM hot swap fixes and system abort on not enabled hot swap feature
* SIM hot swap should now properly show |x| in sim place when there is
  no SIM inserted in selected sim slot
* ServiceCellular now can inform on Fatal state desktop which will
  trigger window `Reboot` with no point of exit
* All windows in Desktop now have name in one place
* Access to cmux channels via enum class instead of String (which is errorprone)
2020-03-19 14:53:03 +01:00
Mateusz Grzywacz
58c11d6ded [EGD-2999] Antenna Select fix 2020-03-19 14:16:44 +01:00
Radoslaw Wicik
a8573a404c Apply new style 2020-03-17 10:03:16 +01:00
Alek-Mudita
dc3d655abe Egd 2566 signal strength indicator (#214)
* [EGD-2566] refactored cellular notification recogniton

* [EGD-2566] add new conversion to dBm

* [EGD-2566] added dBm to bar calculations
some minor fixes connected to signal strength
put static data in event store

* [EGD-2566] removed magic number

* [EGD-2566] PR fixes

* [EGD-2566] PR fixes

* [EGD-2566] missing rebase fix

* [EGD-2566] moved Signal Strength to separate file.

* [EGD-2566] missing return

* [EGD-2566] update signalstrength without message sending

* [EGD-2566]  reverted USE_DAEFAULT_BAUDRATE to 1

* [EGD-2566][fix] missing change for closing  end call window

* [EGD-2566] fix for proper checking for CSQ. Verbose setting of singla strength in Store

* [EGD-2566] fixed inlude in ScopeDTime.

* [EGD-2566]  added mutex in GSM store

* [EGD-2566] missing change

* [EGD-2566] reverted USE_DAEFAULT_BAUDRATE

* [EGD-2566] PR fixy
2020-03-13 16:42:42 +01:00
Adam Dobrowolski
49e2c98126 EGD-2848 Made wait on polling fail in cellular initialization, added AT+CRC to sim init 2020-03-12 15:24:39 +01:00
Adam Dobrowolski
e97a54f7ec EGD-2848 Initialize SIM after unlock 2020-03-12 15:24:39 +01:00
kkleczkowski
358a39b377 [EGD-2945-restored-115200-baudrate] Restored 115200 baudrate. (#224)
* [EGD-2945-restored-115200-baudrate] Restored 115200 baudrate.

* [EGD-2945-restored-115200-baudrate] Define added.

* [EGD-2945-restored-115200-baudrate] Cosmetic change.

Co-authored-by: Kuba Kleczkowski <dd>
2020-03-12 11:59:54 +01:00
Adam Dobrowolski
e363b2f027 EGD-2956 sim swap force on start 2020-03-09 14:47:33 +01:00
Adam Dobrowolski
84eb7a60fb EGD-2956 SIM detection test 2020-03-09 14:47:33 +01:00
kkleczkowski
2868c87322 Egd 2854 antenna test app (#184)
* [EGD-2854-antenna-test-app] Antenna app + window.

* [EGD-2854-antenna-test-app] Cellular API, antenna app gui.

* [EGD-2854-antenna-test-app] Pin mux, small gui improvements.

* [EGD-2854-antenna-test-app] Compilation fix.

* [EGD-2854-antenna-test-app] PR suggestions.
2020-02-25 15:42:03 +01:00
Adam Dobrowolski
4a851263e8 [EGD-2656] All at commands gathered in one place
* at commands in one place, with timeouts set
* commands used with stream->cmd(...) have last execution time and result stored
2020-02-20 08:13:55 +00:00
Adam Dobrowolski
2ba032edb4 [EGD-2571] [FIX] gsm works each time it restarts
[EGD-2571] squash with previous
2020-02-18 07:39:16 +00:00
Adam Dobrowolski
2a57cfccd5 [EGD-2571] SendCommand commonized between ATparser and DLC_channel
* option to handle response based on OK/ERROR
* better return value - Response code & response values
* common parent for common behaviour (TODO add ->cmd(...) to mux channels)
* better logging
* small fixups
2020-02-18 07:39:16 +00:00
pholat
2b275d7951 [EGD-2571] added GSM command sending & small refactor
* added GSM AT commands on 'Commands' channel
* refactor (for better console/script) handling
* docs update
* GSM request asynch send back on uart to requester
2020-02-11 08:41:26 +00:00
Alek-Mudita
ea69daaebc Egd 2420 adding new calllog entry phase2 (#150)
* [EGD-2420] tokenizer refactoring
new class CellularCall

* [EDG-2420] new file added

* [EGD-2420] fixed include

* [EGD-2420] added new ModemCall type and its usage in Sevice Cellular.
missing dep in module-cellular.
Fix in tokenizer.

* [EGD-2420] get calllogrecordID one adding new entry to DB
number as contact name

* [EGD-2420] fixes at DB level api for update and delete
Outgoing call seems to add proper calllog entries now

* [EGD-2420][fix] fix for HF during call before full modem init

* [EGD-2420] incoming and missed calls are handled
code clean-up

* [EGD-2420] ModemCall::to_string

* [EGD-2420] added proper exceptions

* [EGD-2420] minor clean up

* [EGD-2420] split string with multichar delimiter

* [EGD-2420] done some TODOs

* [EGD-2420] PR fixes

* [EGD-2420] separation between cellularcall and cellularservice
PR fixes

* [EGD-2420] duration based on timestamp instead of timer

* [EGD-2420] new to_strings

* [EGD-2420] fixes after rebase

* [EGD-2420] operator<<

* [EGD-2420] changed split params

* [EGD-2420] changed returned db id

* [EGD-2420] comment with explantaion
2020-01-30 12:45:29 +01:00
Alek-Mudita
9bc0e6f3c5 Egd 2420 adding new calllog entry phase 1 (#134)
* [EGD-2420]  minor fix in call app timer

* [EGD-2420] added missing dictionary definitions

* [EGD-2420] removed the same preprocesor defintions

* [fix][EGD-2420] for adding new entry to calllog DB.
It is workaournd as it looks like there is issue with printing 64bit variables in vsnprintf

* [EGD-2420] added new timer for call duration on cellular servcice.

* [EGD-2420] changed unnecessary LOG_ERRORs to LOG_DEBUGs

* [EGD-2420] changed logging levels

* [EGD-2420] added TODO
2020-01-15 15:05:25 +01:00
Alek-Mudita
7ed1fa2f62 Egd 2449 fix for call aborting (#130)
* [fix] checked for proper time ID

* [fix] missing change

* adding proper debugging  possibility

* [fix] added more response validation

* [fix] validatio of the AT+CLCC response

* changed log level

* [fix] added explantation for the fix

* clean up AT command resposne validation methods

* [fix] for aborting call using long press

* added abort() in vApplicationStackOverflowHook

* code review fixes
2020-01-10 16:08:10 +01:00
kkleczkowski
013422e519 Cellular messages (#110)
* WiP on porting sms to new cmux.

* [cellular-messages] WiP concatented messages.

* [cellular-messages] Sending sms and concatenated sms.

* [cellular-messages] WiP concatenated messages.

* [cellular-messages] Fixed deserialising multiple frames.

* [cellular-message] Demo app + cellular api.

* [cellular-message] Added text input selection

* [cellular-messages] Fixed font size.

* .gitignore update

* [cellular-messages] cleanup and rm source/version.hpp.

* [cellular-messages] PR suggestions.

* [cellular-messages] Fixed merge overwrites, rest of PR suggestions.

* [cellular-messages] Pr suggestions.

* [cellular-messages] PR suggestions again.
2019-12-17 09:51:05 +01:00
Alek-Mudita
af3332fd87 Fix hardfault during calling (#106)
* formatting of ServiceCellular::DataReceivedHandler

* [fix] - check if channel is not nullptr

* Minor enhancments and safety checks

* minor clean up

* sprintf removal

* references
2019-12-06 12:18:27 +01:00
Alek-Mudita
8b167d1809 Fix for calling (#91)
* fix for not switching to active call

* Added missing icons during unaswered outgoing call + some error logging

* Added additional logging to AT commands
defult timeout set to 300 ms.
Set different timeouts per each AT command.
Minor code refactoring.

* Added some logging, fixed some timeouts and number of returned tockens.

* commented out not needed log

* Added LOG_CUSTOM logging support. Remove unnecessary LOG_ERRORS.

* set ATA cmd timeout to 90 sec

* PR fixes
2019-11-29 11:18:57 +01:00
Adam Dobrowolski
ab8ef46b98 [EGD-2167] Workaround for crash when no modem on Linux
When there is no modem connected to PC, there is crash, which is not
caused by Read and Write, but somewhere deeper.
2019-11-19 12:53:29 +01:00
Lukasz Skrzypczak
22d42288b4 [EGD-2167] Added signal quality read on startup 2019-11-19 12:53:29 +01:00
Lukasz Skrzypczak
09e70fd107 [EGD-2167] Alek's PR's corrections 2019-11-19 12:53:29 +01:00
Lukasz Skrzypczak
8d2db70e2a [EGD-2167] Merged (consider remove) 2019-11-19 12:53:29 +01:00
RomanKubiak
5e491d4a63 [WiP] [EDG-2167] Working CMUX, call in/out. Code to be cleaned 2019-11-19 12:53:29 +01:00