Compare commits

...

202 Commits

Author SHA1 Message Date
15ca153a3e fix resources.qrc 2025-04-20 23:28:34 +03:00
9a79ad1cc4 Convert icons to png 2025-04-20 23:26:30 +03:00
tza
e3f4b852a1 Working version 2025-04-20 20:05:20 +00:00
9f3135066d fix hpp 2025-04-20 21:46:45 +03:00
b27dcec0b9 websocket client boilerplate 2025-04-20 20:06:35 +03:00
25c3c5171c add stacked widget 2025-04-20 19:44:41 +03:00
da5c247339 remove mute/volume from header 2025-04-20 18:21:53 +03:00
f92bd9b3f7 remove mute stuff 2025-04-20 17:59:06 +03:00
da0193dd19 remove leftover volume stuff 2025-04-20 17:50:34 +03:00
7e940ef815 fix oldmenudummy 2025-04-20 17:41:02 +03:00
a3656500e7 add bt now playing and radio 2025-04-20 17:30:30 +03:00
Matthew Hilton
82bffdb514
Merge pull request #24 from SonOfGib/AAP-1.6-crankshaft
Aap 1.6 crankshaft
2025-03-26 21:07:56 +00:00
SonOfGib
160b1552a6
Merge remote-tracking branch 'opencardev/crankshaft-ng' into AAP-1.6-crankshaft 2025-03-26 16:06:08 -04:00
SonOfGib
05a4a0a7d7
Various tweaks
* Fix bluetooth service issues when running on linux pc (experimental.)
* Service factory changes to disable bluetooth and wifi (commented out)
* Include boost logs library.
2025-02-26 20:02:23 -05:00
matt
e1940b90a6
Added CoC 2025-02-07 23:02:12 +00:00
Simon Dean
17d4bfbcda Backport LibGPS updates a79d155bd658eff85036f0d7d29486faac0bf3cc
Backport and merge artefacts from
a5cdf161ad1aefcda5425b5bef56032e1c510219
2025-01-08 18:09:54 +00:00
Simon Dean
d19a4438ca Merge branch 'crankshaft-ng' of https://github.com/opencardev/openauto into crankshaft-ng
# Conflicts:
#	include/f1x/openauto/autoapp/Configuration/Configuration.hpp
#	include/f1x/openauto/autoapp/Configuration/IConfiguration.hpp
#	src/autoapp/Configuration/Configuration.cpp
#	src/autoapp/Service/AndroidAutoEntity.cpp
#	src/autoapp/Service/SensorService.cpp
#	src/autoapp/Service/ServiceFactory.cpp
#	src/autoapp/UI/SettingsWindow.cpp
2025-01-08 17:27:25 +00:00
Matthew Hilton
1a74e9f8d9
Merge pull request #22 from opencardev/fix_libgps
Added libgps fix to support api version >7 and lower.
2025-01-08 00:00:25 +00:00
Matthew Hilton
fb618c0049
Merge pull request #21 from SonOfGib/crankshaft-ng
Disable Wifi Projection + Fix assistant hang/missing audio.
2025-01-07 23:08:31 +00:00
SonOfGib
075c356122
Wireless projection should default to true.
* When ini file was not present, the default value was set to false instead of true.
2025-01-07 18:06:00 -05:00
matt
a79d155bd6
Added libgps fix to support api version >7 and lower. 2025-01-07 23:05:19 +00:00
Simon Dean
64b9c1370f Switch back to CrankShaft branding 2025-01-07 22:35:28 +00:00
Simon Dean
f456ce8dfa Merge remote-tracking branch 'origin/JourneyOS' into crankshaft-ng
# Conflicts:
#	CMakeLists.txt
#	include/f1x/openauto/autoapp/Projection/IVideoOutput.hpp
#	include/f1x/openauto/autoapp/Projection/InputEvent.hpp
#	include/f1x/openauto/autoapp/Service/AndroidAutoEntity.hpp
#	include/f1x/openauto/autoapp/Service/AudioInputService.hpp
#	include/f1x/openauto/autoapp/Service/AudioService.hpp
#	include/f1x/openauto/autoapp/Service/BluetoothService.hpp
#	include/f1x/openauto/autoapp/Service/InputService.hpp
#	include/f1x/openauto/autoapp/Service/MediaSink/GuidanceAudioService.hpp
#	include/f1x/openauto/autoapp/Service/MediaSink/MediaAudioService.hpp
#	include/f1x/openauto/autoapp/Service/MediaSink/VideoService.hpp
#	include/f1x/openauto/autoapp/Service/Sensor/SensorService.hpp
#	include/f1x/openauto/autoapp/Service/VideoService.hpp
#	include/f1x/openauto/autoapp/Service/WifiService.hpp
#	include/f1x/openauto/btservice/AndroidBluetoothServer.hpp
#	src/autoapp/Service/AndroidAutoEntity.cpp
#	src/autoapp/Service/MediaAudioService.cpp
#	src/autoapp/Service/SensorService.cpp
#	src/autoapp/Service/ServiceFactory.cpp
#	src/autoapp/Service/SpeechAudioService.cpp
#	src/autoapp/Service/SystemAudioService.cpp
#	src/autoapp/Service/WifiService.cpp
#	src/autoapp/autoapp.cpp
#	src/btservice/AndroidBluetoothServer.cpp
2025-01-07 22:08:57 +00:00
Sean Gibson
a5cdf161ad Disable Wifi Projection + Fix assistant hang/missing audio. (#2)
* Bonus: Fix assistant hang/missing audio.

* Add new wireless projection config section.
* Add check box to disable/enable wireless projection. Checking this box causes the service factory to skip the bluetooth and wifi services.
2025-01-06 21:11:17 -05:00
Matthew Hilton
5da1376565
Merge pull request #19 from SonOfGib/sonofgib-newdev
SonOfGib Fixes
2024-12-30 22:40:17 +00:00
Simon Dean
880ec80d31 Merge branch 'JourneyOS-DisableUpdates' into Bluetooth-Reworking 2024-11-29 22:14:03 +00:00
Simon Dean
d97edf539b BugFix finalisation of re-worked btservice for Bluetooth Handling.
Redeclare function scoped variables to be on on class object for persistent handling in memory.
2024-11-29 22:13:44 +00:00
Simon Dean
c5ac7113c8 Remove System Updates during transition and swap name from CrankShaft to Journey: Temporary 2024-11-27 11:29:35 +00:00
Simon Dean
361e1467b7 Move remaining Bluetooth Signals to BtService to prevent overlaps. 2024-11-27 11:27:12 +00:00
Simon Dean
28caa06b09 Remove concept of Local and Remote Bluetooth Devices.
They both essentially do the same thing - to return the hardware address, and show whether the adapter is available.

Remove RemoteBluetoothDevice, merge into LocalBluetoothDevice

Introduce routine to SettingsWindow to bring in list of adapters.
2024-11-27 10:02:01 +00:00
Simon Dean
478526b953 Reformat Code 2024-11-27 09:53:07 +00:00
Simon Dean
7f38e16983 Resolve display issue where if Raspberry Pi thinks both HDMI and LCD are enabled, the display width is appearing as two side by side monitors (double width) rather than just using the physical width of the screen. 2024-11-21 13:06:48 +00:00
Simon Dean
b327bd69b2 Added support for new services provided by AASDK and AAP Protocol version 1.6.
Add extensive logging
Add logo for forked version
Resolve display issue where if Raspberry Pi thinks both HDMI and LCD are enabled, the display width is appearing as two side by side monitors (double width) rather than  just using the physical width of the screen.
2024-11-21 13:06:19 +00:00
Simon Dean
e669277eb4 Rename WifiProjectionStatus.cpp to WifiProjectionService.cpp 2024-11-13 15:10:14 +00:00
Simon Dean
173225970f Remove logging. Bolster WifiProjection 2024-11-13 15:09:20 +00:00
Simon Dean
be8c0ab9cd Compiles and Builds, but problems with Video, WiFi Projection and Bluetooth. 2024-11-13 12:25:09 +00:00
Simon Dean
4e36ff016f Add logo for forked version 2024-11-08 12:56:38 +00:00
Simon Dean
406368d8dd Populate WifiProjectionStatus.cpp, NavigationStatusService.cpp 2024-11-08 12:55:54 +00:00
Simon Dean
68759ee2fa Add extensive logging 2024-11-07 17:18:43 +00:00
Simon Dean
5a2a305c04 All modifications for AAP 1.6 2024-11-04 13:51:11 +00:00
SonOfGib
e3aa777467
WIFI service
* Changes to WIFI service to handle messages from Android Auto. This fixes issues reported with AA > 12.6.
* Modifications to support aasdk proto updates.
* Docker cross compile build for RPI.
* Boost log filtering via `openauto-logs.ini` file
2024-10-29 18:50:11 -04:00
SonOfGib
35005a0e54
Readme notes about building.
* Libgps version update
2024-10-24 22:46:07 -04:00
SonOfGib
cdf1992637
Back to libgps 3.17 2024-10-18 21:50:24 -04:00
SonOfGib
f1976fe76c
Fix broken include. 2024-10-18 21:16:17 -04:00
SonOfGib
9faa119a14
Remove wifi service. 2024-10-17 21:28:09 -04:00
Sean Gibson
cc193045b4
Ignore idea files and Clion build folder. 2023-09-06 16:14:02 -04:00
dice14u
9ea379fa8e Make the opencardev aasdk work with newdev 2023-06-16 00:17:32 -04:00
dice14u
dd2c0a445e using aasdk nextdev 2023-06-15 13:10:57 -04:00
Matthew Hilton
0f317bdc3f
Merge pull request #15 from DanielHerr/media-key-handling
Enhanced Media Key Handling
2022-12-15 20:22:54 +00:00
Daniel Herr
8613351fc3
Enhanced Media Key Handling 2022-07-30 22:13:21 -04:00
Matthew Hilton
4e9574ce1f
Create LICENSE 2021-07-10 11:38:42 +01:00
Matthew Hilton
0e84c362b1
Merge pull request #11 from egisz/keyboard-ui
Keyboard support in openauto
2020-11-02 22:21:15 +00:00
egisz
d7fb716975 more fixes to keyboard handling 2020-10-31 07:39:16 +00:00
egisz
e90d99a2ea fix building warnings 2020-10-31 06:12:46 +00:00
egisz
34f8f0759a add 1 and 2 key to settings menu as TAB 2020-10-30 18:01:39 +00:00
egisz
2592d3a6f8 keyboard support in main window, esc key in settings 2020-10-30 17:54:47 +00:00
Matthew Hilton
bc04598aee
Merge pull request #10 from matt2005/csng-alpha55
Csng alpha55
2020-10-13 21:02:52 +01:00
matt
d5e16bc4aa
Added wifi fixes @presslab-us
added Bluetooth fixes @presslab-us
Added local GPS device support @presslab-us
2020-10-11 00:27:14 +01:00
matt
fd3a00a8e3
[QT]
QT 5.15 fixes for alignment errors
2020-10-10 23:28:58 +01:00
matt
2b367721a7
fix compiler errors 2020-10-10 23:28:30 +01:00
matt
c18f0edeb5
[libusb]
Resolve compiler errors
2020-10-10 23:27:37 +01:00
hawkeyexp
fd5ce7ac07 Bringup pre5 2019-06-10 11:38:47 +02:00
hawkeyexp
bfabfd1822 AA Exit fix / Button visibility 2019-03-02 13:01:28 +01:00
hawkeyexp
1020069646 Experimental: Allow higher ping/pong diff 2019-01-29 19:38:11 +01:00
hawkeyexp
5b9ebd7bd4 latest dev 2019-01-28 13:16:17 +01:00
hawkeyexp
03c1518baf update to latest 2019-01-26 20:03:07 +01:00
hawkeyexp
4ebdcd935f update latest dev 2019-01-20 11:00:44 +01:00
hawkeyexp
c63494334b Add new triggers 2019-01-17 15:44:33 +01:00
hawkeyexp
b6c705544b latest dev 2019-01-16 20:45:41 +01:00
hawkeyexp
e653923eb6 Fixes / Apply alpha to old style menu 2019-01-06 11:09:32 +01:00
hawkeyexp
0307adafe8 Latest changes 2019-01-05 00:58:30 +01:00
hawkeyexp
2ed095eed5 Add settings for brightness control / Auto Play / Add CSSTORAGE info / Switchable cursor 2018-12-21 17:38:37 +01:00
hawkeyexp
db48323a19 Add try catch to prevent from exceptions / Add country code to settings / Fix exit in wifi mode 2018-12-17 16:03:48 +01:00
hawkeyexp
f16c3fe54c Cleanup code / Add auto close safety 2018-12-13 17:13:02 +01:00
hawkeyexp
e4ab3e0a29 Make wallpaper eq external / Add disable rtc day/night 2018-12-10 15:30:44 +01:00
hawkeyexp
43bab5a782 Latest fixes 2018-12-07 20:34:49 +01:00
hawkeyexp
60564c0e98 Make tsl2561 configurable / fixes day/night manvirrr 2018-12-07 15:26:47 +01:00
hawkeyexp
1ff179eca4 Remove alpha slider mainwindow / add brightness day/night control to settings / update system notify 2018-12-06 21:19:57 +01:00
hawkeyexp
a7fb685a65 Fix visible conditions 2018-12-06 14:56:05 +01:00
hawkeyexp
fe62796cc9 Fixes / Merge changes from manvirrr 2018-12-06 14:18:22 +01:00
hawkeyexp
fabcc84896 Cleanup assets / Update png format 2018-12-06 00:47:36 +01:00
hawkeyexp
95a329f33d Fix day/night sensor polling 2018-12-05 19:42:39 +01:00
hawkeyexp
cd36c39037 Try day/night code from manvirrr 2018-12-05 15:38:26 +01:00
hawkeyexp
14662664ed latest dev 2018-12-05 13:09:36 +01:00
hawkeyexp
802393d427 Make lux values switchable via setings 2018-11-30 13:32:24 +01:00
hawkeyexp
c30bdeb20b Add day/night by gpio / gui fixes / lux values to gui / video stop by go back 2018-11-30 12:34:23 +01:00
hawkeyexp
3621a20cda Fix label 2018-11-24 15:30:18 +01:00
hawkeyexp
cc2e3d67ba More dynamic gui / player autoplay / add lightsensor to hw setup 2018-11-24 15:24:45 +01:00
hawkeyexp
a06504a2a5 Add player bg / config values for auto play etc / code cnsolidate / clanups 2018-11-21 15:25:47 +01:00
hawkeyexp
6f4defef40 Switch back to system / fix usb detect after settings change 2018-11-15 15:00:47 +01:00
hawkeyexp
5f0d26e64a Remove obsolete usb dialog 2018-11-14 13:50:42 +01:00
hawkeyexp
a87a3eef82 latest 2018-11-14 13:42:38 +01:00
hawkeyexp
e5c031774e Rework triggers / usb /network 2018-11-03 12:17:59 +01:00
hawkeyexp
4e2ebcdd4a Fix startup bug in usb mode 2018-10-23 18:52:04 +02:00
hawkeyexp
03ad005f80 Gui bg rework / remove build id 2018-10-19 22:36:55 +02:00
hawkeyexp
360ffeb6f9 adjust settings menu 2018-10-19 04:04:59 +02:00
hawkeyexp
28180b6efa Add sdoc / Add display wake lock while playing media 2018-10-17 00:43:47 +02:00
hawkeyexp
d1a30439c6 Text correction 2018-10-16 15:25:19 +02:00
hawkeyexp
f3fe0e7e77 Add skip usb detect / start rework system to qprocess 2018-10-12 04:00:40 +02:00
hawkeyexp
ea285c84b0 Optimize settings layout/resizes 2018-10-08 14:50:23 +02:00
hawkeyexp
e3c055984a Add audiotest to gui 2018-10-05 18:53:02 +02:00
hawkeyexp
7d044eee09 Force unmount 2018-10-05 17:19:55 +02:00
hawkeyexp
d81b2c4a69 Add aa wifi entity detect 2018-09-30 18:20:24 +02:00
hawkeyexp
902d450e21 Add blackscreen option for custom commands 2018-09-30 00:52:24 +02:00
hawkeyexp
4d90184c22 Add display blank option 2018-09-29 01:05:37 +02:00
hawkeyexp
0c9600e6e3 Extend settings text / add mp4a 2018-09-28 20:31:00 +02:00
Marc Hillesheim
eeeaef1f4f Add wma for testing 2018-09-27 21:39:49 +02:00
hawkeyexp
bd03a47901 Change mount point 2018-09-27 18:27:53 +02:00
hawkeyexp
2f387c6096 Rework for usb drive handling 2018-09-27 15:56:19 +02:00
hawkeyexp
5234599c90 Implement taglib and use in filescan / player | Extend supported media 2018-09-24 12:14:27 +02:00
hawkeyexp
90ccf5b55a Extend supported filetypes / resize controls 2018-09-23 15:19:45 +02:00
hawkeyexp
be2fb2ccb3 Revert mark current track / Mark last played track on stop 2018-09-22 14:35:32 +02:00
hawkeyexp
d2feacddad Mark current playing track selected 2018-09-22 14:05:06 +02:00
hawkeyexp
5ff5327f43 Rework player usage 2018-09-22 13:29:25 +02:00
hawkeyexp
c7772617a3 Add album next/prev and optimize gui 2018-09-21 13:20:22 +02:00
hawkeyexp
f2e27a8d64 Add mediapaths to settings / gui reworks 2018-09-21 00:15:16 +02:00
hawkeyexp
e26022190e Gui optimize and folder handling player 2018-09-20 17:56:03 +02:00
hawkeyexp
b84aed1f55 Add folder select and scan 2018-09-19 19:35:34 +02:00
hawkeyexp
9a4f1e7080 initial mp3 bringup 2018-09-18 22:16:28 +02:00
hawkeyexp
1b743ef129 Add ntp sync button / optimize timer remove sleep 2018-09-17 13:29:13 +02:00
hawkeyexp
3a7e7593ff latest dev 2018-09-13 14:57:07 +02:00
hawkeyexp
0703904ca1 latest dev 2018-09-10 09:39:49 +02:00
hawkeyexp
72397d880e Reworked settings menu / switchable button alpha and gui toggle 2018-09-07 03:15:36 +02:00
hawkeyexp
873b1e2dde add lost wifi button 2018-09-05 03:03:16 +02:00
hawkeyexp
3a74f7fa1d Bugfixes 2018-09-04 21:41:35 +02:00
hawkeyexp
0bba0e5612 Rework with new gui 2018-08-31 14:08:38 +02:00
hawkeyexp
baae26932c Add bluetooth pair button 2018-08-17 16:13:44 +02:00
hawkeyexp
ed37925b51 Resize label 2018-08-15 23:13:11 +02:00
hawkeyexp
63d784dcbe Add bluetooth stuff 2018-08-15 20:04:53 +02:00
hawkeyexp
4a7fbae6f6 Revert wifi setup which caused breaks / Include cam setup 2018-08-11 14:50:07 +02:00
hawkeyexp
46c2cb075c Change delimater for bug prevention 2018-08-10 22:53:07 +02:00
hawkeyexp
bd36d87bdb Remove testline 2018-08-09 18:08:18 +02:00
hawkeyexp
dcc0c01586 Some rework for custom brightness & slider 2018-08-08 14:52:30 +02:00
hawkeyexp
b7ce5de716 Use brightness values from crankshaft_env.sh / Optimize Handling custom brightness 2018-08-08 02:13:34 +02:00
hawkeyexp
c2990c2421 Fix audioinjector preselection 2018-08-07 22:13:39 +02:00
hawkeyexp
96eeba4ad9 Enable optional hardware setup / Hotfix ignition shutdown 2018-08-07 02:42:29 +02:00
hawkeyexp
10516c7017 Show black bg if kodi is running 2018-08-06 16:10:54 +02:00
hawkeyexp
e936f7439d Show custom brightness command in gui 2018-08-06 13:12:31 +02:00
hawkeyexp
bf69ef7e8a Complete wifi setup / Add Hotspot setup 2018-08-06 01:18:25 +02:00
hawkeyexp
ac5b130e3b Rearange gui / Add wifi setup 2018-08-05 23:24:22 +02:00
hawkeyexp
84f7fafe3a Include external shutdown trigger 2018-08-03 01:42:18 +02:00
hawkeyexp
8fbdd32abb Add ignition_pin/delay to gui 2018-08-02 13:36:46 +02:00
hawkeyexp
2ace4e9198 Resize and pos debug button 2018-07-30 14:14:04 +02:00
hawkeyexp
27799aef76 Fix missing remove: Some reworks and handling changes 2018-07-29 18:17:21 +02:00
hawkeyexp
d6b7bee928 Some reworks and handling changes 2018-07-29 18:15:14 +02:00
hawkeyexp
b8bbddabe0 Fix stupid bug with debug button 2018-07-28 08:31:14 +02:00
hawkeyexp
ba068c0aab Some cosmetics / Lock button during save 2018-07-27 13:40:14 +02:00
hawkeyexp
a64f3341f2 Init debug mode via gui 2018-07-25 20:39:35 +02:00
hawkeyexp
a1472a2546 Optimize custom brightness command 2018-07-25 13:54:20 +02:00
hawkeyexp
26b371385a Init custom brightness command 2018-07-24 22:11:02 +02:00
hawkeyexp
e1fcfdf85e Last fix pulseaudio volume restore 2018-07-23 21:24:19 +02:00
hawkeyexp
2b17b51bb5 Allow disable timers / include iqaudio 2018-07-23 09:37:06 +02:00
hawkeyexp
44acc8ac0a Fixes 2018-07-21 20:35:05 +02:00
hawkeyexp
43d6bee314 Include hardware setup 2018-07-21 17:46:27 +02:00
hawkeyexp
2feff5396e Rework audio setup pulseaudio / system interaction 2018-07-18 16:44:40 +02:00
hawkeyexp
093e79cd7a Release sound card handling 2018-07-16 07:58:21 +02:00
hawkeyexp
c82ea93668 Init sound card handling 2018-07-15 08:48:52 +02:00
hawkeyexp
42ee3289d1 Adjust settings 2018-07-13 21:27:09 +02:00
hawkeyexp
ef00744823 [settings] Extend system config 2018-07-12 13:43:35 +02:00
hawkeyexp
7d889bd58a [gui] Adjust controls layout 2018-07-09 10:51:59 +02:00
hawkeyexp
3514384742 Latest changes 2018-07-09 00:07:37 +02:00
hawkeyexp
9816a04557 Init CS-NG Tab 2018-07-05 08:54:39 +02:00
hawkeyexp
7be4d7db35 [gui] Reduce sleep 2018-07-01 19:59:10 +02:00
hawkeyexp
a2fb124df6 [gui][load] Fix high cpu load / optimizing 2018-07-01 18:29:53 +02:00
hawkeyexp
01fbd163f0 [gui] Fix sliderbug 2018-07-01 04:41:21 +02:00
hawkeyexp
7875c511b5 [gui] Add font usage 2018-06-28 14:58:35 +02:00
hawkeyexp
ff89fe6f11 [gui] Add phone connected string 2018-06-26 20:45:46 +02:00
hawkeyexp
9d60eba90e Add version strings to gui 2018-06-25 20:34:17 +02:00
hawkeyexp
dbfb482c9f [gui][script] rework reboot 2018-06-25 20:34:08 +02:00
hawkeyexp
c72958438f [gui][script] Rearcam / reworks / kodi button / shutdown/reboot buttons 2018-06-22 00:08:36 +02:00
hawkeyexp
3a59525055 [gui][script] Dashcam / Reworks 2018-06-16 02:04:05 +02:00
hawkeyexp
77cdf52cd2 [gui] Rework wallpapers / finish auto day/night switch 2018-06-13 21:09:55 +02:00
hawkeyexp
c8dd7f48ff [gui] Close slider on switching day/night 2018-06-05 16:55:09 +02:00
hawkeyexp
a1f010fa5b [gui] Add dev mode background 2018-06-05 15:53:29 +02:00
hawkeyexp
3f241ee283 [gui] Add clock 2018-05-26 16:31:31 +02:00
hawkeyexp
aa5851442c [gui] Rework brightness slider 2018-05-25 21:53:50 +02:00
hawkeyexp
2deaedbe07 [code] change call of script day/night 2018-05-24 03:18:53 +02:00
hawkeyexp
bdf2befaa2 [code] Announce day / night mode to android auto 2018-05-23 19:53:32 +02:00
hawkeyexp
5440d0e3b0 [gui][script] Switchable day/night mode 2018-05-23 18:11:31 +02:00
Marc Hillesheim
ed96372595 [gui] Make button view forceable 2018-05-21 17:04:50 +02:00
Marc Hillesheim
db2d0e0bd6 [gui][script] Add camera button 2018-05-21 17:03:06 +02:00
Marc Hillesheim
f9ae6f02c9 Revert "[code-cs] add crankshaft plug/unplug scripts"
This reverts commit df8f8f6cb47ccd18c0b9d7e5609e3f762a590ff3.
2018-05-21 16:41:52 +02:00
Marc Hillesheim
77f6f8c30d [gui] Update button images / rework layout 2018-05-21 16:35:44 +02:00
Huan Truong
5d154138bb Merge remote-tracking branch 'f1xpl/master' into HEAD 2018-05-12 05:20:42 -04:00
michal.szwaj
cfb6ebfee1 Create service package 2018-05-04 04:41:28 -04:00
michal.szwaj
84de27cc02 Cleanup entity creation 2018-05-04 04:41:28 -04:00
michal.szwaj
cc062f57e1 Inject list of services instead of service factory 2018-05-04 04:41:28 -04:00
michal.szwaj
bd0264501a Inject messenger to the entity 2018-05-04 04:41:28 -04:00
michal.szwaj
57b10e086a Split ping method to send and schedule 2018-05-04 04:41:28 -04:00
michal.szwaj
a8d8a83e12 Standarize behavior of pinger cancel 2018-05-04 04:41:28 -04:00
michal.szwaj
b50e1d658e Fix invalid inheritance of enable_shared_from_this 2018-05-04 04:41:28 -04:00
michal.szwaj
d93baa88cb Draft of ping implementation 2018-05-04 04:41:28 -04:00
michal.szwaj
05df5328cd Set socket options to detect broken connection 2018-05-04 04:41:28 -04:00
michal.szwaj
2f0bf11e4b Adjust audio device buffer size 2018-05-04 04:41:28 -04:00
Michal Szwaj
f8de16c714 Update Readme.md 2018-05-04 04:41:28 -04:00
michal.szwaj
1fd7b6f529 Use specialized erase_begin to remove read data from sequential buffer 2018-05-04 04:41:28 -04:00
Huan Truong
df8f8f6cb4 [code-cs] add crankshaft plug/unplug scripts 2018-05-04 04:41:28 -04:00
Huan Truong
88f61a3c4d [code] fix hide cursor procedure 2018-05-04 04:41:28 -04:00
Huan Truong
46dcd609bd [tweak] make QT audio default backend instead of RtAudio 2018-05-04 04:41:28 -04:00
Huan Truong
eed0c9b35b [code] more debugging for touchscreen detection 2018-05-04 04:41:28 -04:00
Huan Truong
099f14d3de [config] added touchscreen auto-detection 2018-03-31 01:49:00 -04:00
Huan Truong
16a09529e8 [GUI] New assets and functionalities to Crankshaft 2018-03-31 00:12:32 -04:00
196 changed files with 30565 additions and 4440 deletions

5
.gitignore vendored
View File

@ -1,4 +1,9 @@
# Add any directories, files, or patterns you don't want to be tracked by version control
lib/
bin/
build/
.vscode/
openauto.ini
CMakeLists.txt.user
/cmake-build-*/
.idea/

View File

@ -1,66 +1,119 @@
cmake_minimum_required(VERSION 3.5.1)
project(openauto CXX)
message(STATUS "OpenAuto")
option(NOPI "Build for Non Raspberry Pi" OFF)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
set(CMAKE_AUTORCC ON)
set(base_directory ${CMAKE_CURRENT_SOURCE_DIR})
set(resources_directory ${base_directory}/assets)
set(sources_directory ${base_directory}/src)
set(include_directory ${base_directory}/include)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${base_directory}/lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${base_directory}/lib)
# Set Compile Versions
set(OPENAUTO_BUILD_DATE 20241124) # Binary Release Build Date
set(OPENAUTO_BUILD_MAJOR_RELEASE 4) # Binary Release Build Major Number
set(OPENAUTO_BUILD_MINOR_RELEASE 1) # Binary Release Build Minor Number
set(OPENAUTO_BUILD_INCREMENTAL 0) # Binary Build Version - Increment for Each Build
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${base_directory}/bin)
set(EXECUTABLE_OUTPUT_PATH ${base_directory}/bin)
set(Boost_USE_STATIC_LIBS OFF)
set(Boost_USE_MULTITHREADED ON)
set(Boost_USE_STATIC_RUNTIME OFF)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake_modules/")
SET(CMAKE_CXX_STANDARD 14)
# Configure CMAKE
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS_INIT} -Wall -pedantic -fPIC")
set(CMAKE_CXX_FLAGS_DEBUG "-g -O0")
set(CMAKE_CXX_FLAGS_RELEASE "-g -O3")
# Default to Release mode unless overridden with -DCMAKE_BUILD_TYPE=Debug on cmake command
if(NOT CMAKE_BUILD_TYPE)
message(STATUS "Forcing Release build type")
set(CMAKE_BUILD_TYPE Release CACHE STRING "Choose the type of build." FORCE)
set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,-rpath,/usr/local/qt5/lib")
# Set the possible values of build type for cmake-gui
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo")
endif()
# Paths
set(resources_directory ${CMAKE_CURRENT_SOURCE_DIR}/assets)
set(sources_directory ${CMAKE_CURRENT_SOURCE_DIR}/src)
set(include_directory ${CMAKE_CURRENT_SOURCE_DIR}/include)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/lib)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/bin)
set(EXECUTABLE_OUTPUT_PATH ${CMAKE_CURRENT_SOURCE_DIR}/bin)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake_modules/")
# Configure Boost
set(Boost_USE_STATIC_LIBS OFF)
set(Boost_USE_MULTITHREADED ON)
set(Boost_USE_STATIC_RUNTIME OFF)
add_definitions(-DBOOST_ALL_DYN_LINK)
find_package(Boost REQUIRED COMPONENTS system log OPTIONAL_COMPONENTS unit_test_framework)
find_package(libusb-1.0 REQUIRED)
find_package(Qt5 COMPONENTS Multimedia MultimediaWidgets Bluetooth)
find_package(Protobuf REQUIRED)
find_package(OpenSSL REQUIRED)
find_package(rtaudio REQUIRED)
if(CMAKE_BUILD_TYPE STREQUAL "Release")
message(STATUS "Disabling Boost DEBUG logs")
add_definitions(-DNDEBUG)
endif()
if (WIN32)
set(WINSOCK2_LIBRARIES "ws2_32")
endif (WIN32)
if(RPI3_BUILD)
if (DEFINED NOPI)
message(STATUS "Configuring for Non-Raspberry Pi")
else()
message(STATUS "Configuring for RaspberryPi")
add_definitions(-DUSE_OMX -DOMX_SKIP64BIT -DRASPBERRYPI3)
set(BCM_HOST_LIBRARIES "/opt/vc/lib/libbcm_host.so")
set(BCM_HOST_INCLUDE_DIRS "/opt/vc/include")
set(ILCLIENT_INCLUDE_DIRS "/opt/vc/src/hello_pi/libs/ilclient")
set(ILCLIENT_LIBRARIES "/opt/vc/src/hello_pi/libs/ilclient/libilclient.a;/opt/vc/lib/libvcos.so;/opt/vc/lib/libvcilcs.a;/opt/vc/lib/libvchiq_arm.so")
endif(RPI3_BUILD)
endif ()
# Building on a Mac requires Abseil
if(CMAKE_SYSTEM_NAME STREQUAL "Darwin") # macOS
message(STATUS "MacOS System Detected")
add_definitions(-DMAC_OS)
find_package(protobuf REQUIRED CONFIG)
find_package(absl REQUIRED)
set(CMAKE_PREFIX_PATH "/usr/local/opt/qt@5" ${CMAKE_PREFIX_PATH})
list(APPEND CMAKE_PREFIX_PATH /usr/local/opt/util-linux)
list(APPEND CMAKE_PREFIX_PATH /usr/local/opt/taglib)
include(FindProtobuf)
else ()
find_package(Protobuf REQUIRED)
endif ()
find_package(aap_protobuf REQUIRED)
find_package(aasdk REQUIRED)
find_package(Boost REQUIRED COMPONENTS system log_setup log OPTIONAL_COMPONENTS unit_test_framework)
find_package(libusb-1.0 REQUIRED)
find_package(Qt5 REQUIRED COMPONENTS DBus Multimedia MultimediaWidgets Bluetooth Network WebSockets)
find_package(OpenSSL REQUIRED)
find_package(rtaudio REQUIRED)
find_package(taglib REQUIRED)
find_package(blkid REQUIRED)
find_package(gps REQUIRED)
include_directories(${CMAKE_CURRENT_BINARY_DIR}
${Qt5Multimedia_INCLUDE_DIRS}
${Qt5MultimediaWidgets_INCLUDE_DIRS}
${Qt5Widgets_INCLUDE_DIRS}
${Qt5Bluetooth_INCLUDE_DIRS}
${Qt5Network_INCLUDE_DIRS}
${Boost_INCLUDE_DIRS}
${LIBUSB_1_INCLUDE_DIRS}
${PROTOBUF_INCLUDE_DIR}
${OPENSSL_INCLUDE_DIR}
${RTAUDIO_INCLUDE_DIRS}
${AASDK_PROTO_INCLUDE_DIRS}
${AASDK_INCLUDE_DIRS}
${TAGLIB_INCLUDE_DIRS}
${BLKID_INCLUDE_DIRS}
${BCM_HOST_INCLUDE_DIRS}
${ILCLIENT_INCLUDE_DIRS}
${include_directory})
${include_directory}
${PROTOBUF_INCLUDE_DIR}
${AAP_PROTOBUF_INCLUDE_DIR}
${AASDK_INCLUDE_DIR})
link_directories(${CMAKE_LIBRARY_OUTPUT_DIRECTORY})
@ -68,33 +121,58 @@ set(common_include_directory ${include_directory}/f1x/openauto/Common)
set(autoapp_sources_directory ${sources_directory}/autoapp)
set(autoapp_include_directory ${include_directory}/f1x/openauto/autoapp)
file(GLOB_RECURSE autoapp_source_files ${autoapp_sources_directory}/*.ui ${autoapp_sources_directory}/*.cpp ${autoapp_include_directory}/*.hpp ${common_include_directory}/*.hpp ${resources_directory}/*.qrc)
file(GLOB_RECURSE autoapp_source_files ${autoapp_sources_directory}/*.ui ${autoapp_sources_directory}/*.cpp ${autoapp_include_directory}/*.hpp ${autoapp_include_directory}/*.h ${common_include_directory}/*.hpp ${resources_directory}/*.qrc)
add_executable(autoapp ${autoapp_source_files})
target_link_libraries(autoapp
target_include_directories(autoapp PUBLIC ${AAP_PROTOBUF_INCLUDE_DIR} ${AASDK_INCLUDE_DIR})
target_link_libraries(autoapp PUBLIC
libusb
Qt5::WebSockets
${Boost_LIBRARIES}
${Qt5DBus_LIBRARIES}
${Qt5Multimedia_LIBRARIES}
${Qt5MultimediaWidgets_LIBRARIES}
${Qt5Bluetooth_LIBRARIES}
${LIBUSB_1_LIBRARIES}
${PROTOBUF_LIBRARIES}
${Qt5Network_LIBRARIES}
${BCM_HOST_LIBRARIES}
${ILCLIENT_LIBRARIES}
${WINSOCK2_LIBRARIES}
${RTAUDIO_LIBRARIES}
${AASDK_PROTO_LIBRARIES}
${AASDK_LIBRARIES})
${TAGLIB_LIBRARIES}
${BLKID_LIBRARIES}
${GPS_LIBRARIES}
${PROTOBUF_LIBRARIES}
${AAP_PROTOBUF_LIB_DIR}
${AASDK_LIB_DIR})
set(PROGRAM_VERSION_STRING "${OPENAUTO_BUILD_MAJOR_RELEASE}.${OPENAUTO_BUILD_MINOR_RELEASE}.${OPENAUTO_BUILD_INCREMENTAL}+${OPENAUTO_BUILD_DATE}")
message(STATUS "Project Version: ${PROGRAM_VERSION_STRING}")
set(btservice_sources_directory ${sources_directory}/btservice)
set(btservice_include_directory ${include_directory}/f1x/openauto/btservice)
file(GLOB_RECURSE btservice_source_files ${btservice_sources_directory}/*.cpp ${btservice_include_directory}/*.hpp ${common_include_directory}/*.hpp)
file(GLOB_RECURSE btservice_source_files ${btservice_sources_directory}/*.cpp ${btservice_include_directory}/*.hpp ${autoapp_sources_directory}/Configuration/*.cpp ${autoapp_includes_directory}/Configuration/*.hpp ${common_include_directory}/*.hpp)
add_executable(btservice ${btservice_source_files})
add_executable(btservice ${btservice_source_files}
src/btservice/BluetoothHandler.cpp)
target_link_libraries(btservice
target_link_libraries(btservice PUBLIC
${Boost_LIBRARIES}
${Qt5Bluetooth_LIBRARIES}
${Qt5Network_LIBRARIES}
${Qt5MultimediaWidgets_LIBRARIES}
${PROTOBUF_LIBRARIES}
${AASDK_PROTO_LIBRARIES})
${AAP_PROTOBUF_LIB_DIR})
set_target_properties(autoapp
PROPERTIES VERSION ${PROGRAM_VERSION_STRING} SOVERSION ${OPENAUTO_BUILD_INCREMENTAL})
# Install rules
#install(TARGETS autoapp btservice
# EXPORT aasdkTargets
# RUNTIME DESTINATION bin
#)

3
Dockerfile Normal file
View File

@ -0,0 +1,3 @@
FROM scratch
ADD rootfs.tar.xz /
CMD ["bash"]

674
LICENSE Normal file
View File

@ -0,0 +1,674 @@
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
Preamble
The GNU General Public License is a free, copyleft license for
software and other kinds of works.
The licenses for most software and other practical works are designed
to take away your freedom to share and change the works. By contrast,
the GNU General Public License is intended to guarantee your freedom to
share and change all versions of a program--to make sure it remains free
software for all its users. We, the Free Software Foundation, use the
GNU General Public License for most of our software; it applies also to
any other work released this way by its authors. You can apply it to
your programs, too.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
them if you wish), that you receive source code or can get it if you
want it, that you can change the software or use pieces of it in new
free programs, and that you know you can do these things.
To protect your rights, we need to prevent others from denying you
these rights or asking you to surrender the rights. Therefore, you have
certain responsibilities if you distribute copies of the software, or if
you modify it: responsibilities to respect the freedom of others.
For example, if you distribute copies of such a program, whether
gratis or for a fee, you must pass on to the recipients the same
freedoms that you received. You must make sure that they, too, receive
or can get the source code. And you must show them these terms so they
know their rights.
Developers that use the GNU GPL protect your rights with two steps:
(1) assert copyright on the software, and (2) offer you this License
giving you legal permission to copy, distribute and/or modify it.
For the developers' and authors' protection, the GPL clearly explains
that there is no warranty for this free software. For both users' and
authors' sake, the GPL requires that modified versions be marked as
changed, so that their problems will not be attributed erroneously to
authors of previous versions.
Some devices are designed to deny users access to install or run
modified versions of the software inside them, although the manufacturer
can do so. This is fundamentally incompatible with the aim of
protecting users' freedom to change the software. The systematic
pattern of such abuse occurs in the area of products for individuals to
use, which is precisely where it is most unacceptable. Therefore, we
have designed this version of the GPL to prohibit the practice for those
products. If such problems arise substantially in other domains, we
stand ready to extend this provision to those domains in future versions
of the GPL, as needed to protect the freedom of users.
Finally, every program is threatened constantly by software patents.
States should not allow patents to restrict development and use of
software on general-purpose computers, but in those that do, we wish to
avoid the special danger that patents applied to a free program could
make it effectively proprietary. To prevent this, the GPL assures that
patents cannot be used to render the program non-free.
The precise terms and conditions for copying, distribution and
modification follow.
TERMS AND CONDITIONS
0. Definitions.
"This License" refers to version 3 of the GNU General Public License.
"Copyright" also means copyright-like laws that apply to other kinds of
works, such as semiconductor masks.
"The Program" refers to any copyrightable work licensed under this
License. Each licensee is addressed as "you". "Licensees" and
"recipients" may be individuals or organizations.
To "modify" a work means to copy from or adapt all or part of the work
in a fashion requiring copyright permission, other than the making of an
exact copy. The resulting work is called a "modified version" of the
earlier work or a work "based on" the earlier work.
A "covered work" means either the unmodified Program or a work based
on the Program.
To "propagate" a work means to do anything with it that, without
permission, would make you directly or secondarily liable for
infringement under applicable copyright law, except executing it on a
computer or modifying a private copy. Propagation includes copying,
distribution (with or without modification), making available to the
public, and in some countries other activities as well.
To "convey" a work means any kind of propagation that enables other
parties to make or receive copies. Mere interaction with a user through
a computer network, with no transfer of a copy, is not conveying.
An interactive user interface displays "Appropriate Legal Notices"
to the extent that it includes a convenient and prominently visible
feature that (1) displays an appropriate copyright notice, and (2)
tells the user that there is no warranty for the work (except to the
extent that warranties are provided), that licensees may convey the
work under this License, and how to view a copy of this License. If
the interface presents a list of user commands or options, such as a
menu, a prominent item in the list meets this criterion.
1. Source Code.
The "source code" for a work means the preferred form of the work
for making modifications to it. "Object code" means any non-source
form of a work.
A "Standard Interface" means an interface that either is an official
standard defined by a recognized standards body, or, in the case of
interfaces specified for a particular programming language, one that
is widely used among developers working in that language.
The "System Libraries" of an executable work include anything, other
than the work as a whole, that (a) is included in the normal form of
packaging a Major Component, but which is not part of that Major
Component, and (b) serves only to enable use of the work with that
Major Component, or to implement a Standard Interface for which an
implementation is available to the public in source code form. A
"Major Component", in this context, means a major essential component
(kernel, window system, and so on) of the specific operating system
(if any) on which the executable work runs, or a compiler used to
produce the work, or an object code interpreter used to run it.
The "Corresponding Source" for a work in object code form means all
the source code needed to generate, install, and (for an executable
work) run the object code and to modify the work, including scripts to
control those activities. However, it does not include the work's
System Libraries, or general-purpose tools or generally available free
programs which are used unmodified in performing those activities but
which are not part of the work. For example, Corresponding Source
includes interface definition files associated with source files for
the work, and the source code for shared libraries and dynamically
linked subprograms that the work is specifically designed to require,
such as by intimate data communication or control flow between those
subprograms and other parts of the work.
The Corresponding Source need not include anything that users
can regenerate automatically from other parts of the Corresponding
Source.
The Corresponding Source for a work in source code form is that
same work.
2. Basic Permissions.
All rights granted under this License are granted for the term of
copyright on the Program, and are irrevocable provided the stated
conditions are met. This License explicitly affirms your unlimited
permission to run the unmodified Program. The output from running a
covered work is covered by this License only if the output, given its
content, constitutes a covered work. This License acknowledges your
rights of fair use or other equivalent, as provided by copyright law.
You may make, run and propagate covered works that you do not
convey, without conditions so long as your license otherwise remains
in force. You may convey covered works to others for the sole purpose
of having them make modifications exclusively for you, or provide you
with facilities for running those works, provided that you comply with
the terms of this License in conveying all material for which you do
not control copyright. Those thus making or running the covered works
for you must do so exclusively on your behalf, under your direction
and control, on terms that prohibit them from making any copies of
your copyrighted material outside their relationship with you.
Conveying under any other circumstances is permitted solely under
the conditions stated below. Sublicensing is not allowed; section 10
makes it unnecessary.
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
No covered work shall be deemed part of an effective technological
measure under any applicable law fulfilling obligations under article
11 of the WIPO copyright treaty adopted on 20 December 1996, or
similar laws prohibiting or restricting circumvention of such
measures.
When you convey a covered work, you waive any legal power to forbid
circumvention of technological measures to the extent such circumvention
is effected by exercising rights under this License with respect to
the covered work, and you disclaim any intention to limit operation or
modification of the work as a means of enforcing, against the work's
users, your or third parties' legal rights to forbid circumvention of
technological measures.
4. Conveying Verbatim Copies.
You may convey verbatim copies of the Program's source code as you
receive it, in any medium, provided that you conspicuously and
appropriately publish on each copy an appropriate copyright notice;
keep intact all notices stating that this License and any
non-permissive terms added in accord with section 7 apply to the code;
keep intact all notices of the absence of any warranty; and give all
recipients a copy of this License along with the Program.
You may charge any price or no price for each copy that you convey,
and you may offer support or warranty protection for a fee.
5. Conveying Modified Source Versions.
You may convey a work based on the Program, or the modifications to
produce it from the Program, in the form of source code under the
terms of section 4, provided that you also meet all of these conditions:
a) The work must carry prominent notices stating that you modified
it, and giving a relevant date.
b) The work must carry prominent notices stating that it is
released under this License and any conditions added under section
7. This requirement modifies the requirement in section 4 to
"keep intact all notices".
c) You must license the entire work, as a whole, under this
License to anyone who comes into possession of a copy. This
License will therefore apply, along with any applicable section 7
additional terms, to the whole of the work, and all its parts,
regardless of how they are packaged. This License gives no
permission to license the work in any other way, but it does not
invalidate such permission if you have separately received it.
d) If the work has interactive user interfaces, each must display
Appropriate Legal Notices; however, if the Program has interactive
interfaces that do not display Appropriate Legal Notices, your
work need not make them do so.
A compilation of a covered work with other separate and independent
works, which are not by their nature extensions of the covered work,
and which are not combined with it such as to form a larger program,
in or on a volume of a storage or distribution medium, is called an
"aggregate" if the compilation and its resulting copyright are not
used to limit the access or legal rights of the compilation's users
beyond what the individual works permit. Inclusion of a covered work
in an aggregate does not cause this License to apply to the other
parts of the aggregate.
6. Conveying Non-Source Forms.
You may convey a covered work in object code form under the terms
of sections 4 and 5, provided that you also convey the
machine-readable Corresponding Source under the terms of this License,
in one of these ways:
a) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by the
Corresponding Source fixed on a durable physical medium
customarily used for software interchange.
b) Convey the object code in, or embodied in, a physical product
(including a physical distribution medium), accompanied by a
written offer, valid for at least three years and valid for as
long as you offer spare parts or customer support for that product
model, to give anyone who possesses the object code either (1) a
copy of the Corresponding Source for all the software in the
product that is covered by this License, on a durable physical
medium customarily used for software interchange, for a price no
more than your reasonable cost of physically performing this
conveying of source, or (2) access to copy the
Corresponding Source from a network server at no charge.
c) Convey individual copies of the object code with a copy of the
written offer to provide the Corresponding Source. This
alternative is allowed only occasionally and noncommercially, and
only if you received the object code with such an offer, in accord
with subsection 6b.
d) Convey the object code by offering access from a designated
place (gratis or for a charge), and offer equivalent access to the
Corresponding Source in the same way through the same place at no
further charge. You need not require recipients to copy the
Corresponding Source along with the object code. If the place to
copy the object code is a network server, the Corresponding Source
may be on a different server (operated by you or a third party)
that supports equivalent copying facilities, provided you maintain
clear directions next to the object code saying where to find the
Corresponding Source. Regardless of what server hosts the
Corresponding Source, you remain obligated to ensure that it is
available for as long as needed to satisfy these requirements.
e) Convey the object code using peer-to-peer transmission, provided
you inform other peers where the object code and Corresponding
Source of the work are being offered to the general public at no
charge under subsection 6d.
A separable portion of the object code, whose source code is excluded
from the Corresponding Source as a System Library, need not be
included in conveying the object code work.
A "User Product" is either (1) a "consumer product", which means any
tangible personal property which is normally used for personal, family,
or household purposes, or (2) anything designed or sold for incorporation
into a dwelling. In determining whether a product is a consumer product,
doubtful cases shall be resolved in favor of coverage. For a particular
product received by a particular user, "normally used" refers to a
typical or common use of that class of product, regardless of the status
of the particular user or of the way in which the particular user
actually uses, or expects or is expected to use, the product. A product
is a consumer product regardless of whether the product has substantial
commercial, industrial or non-consumer uses, unless such uses represent
the only significant mode of use of the product.
"Installation Information" for a User Product means any methods,
procedures, authorization keys, or other information required to install
and execute modified versions of a covered work in that User Product from
a modified version of its Corresponding Source. The information must
suffice to ensure that the continued functioning of the modified object
code is in no case prevented or interfered with solely because
modification has been made.
If you convey an object code work under this section in, or with, or
specifically for use in, a User Product, and the conveying occurs as
part of a transaction in which the right of possession and use of the
User Product is transferred to the recipient in perpetuity or for a
fixed term (regardless of how the transaction is characterized), the
Corresponding Source conveyed under this section must be accompanied
by the Installation Information. But this requirement does not apply
if neither you nor any third party retains the ability to install
modified object code on the User Product (for example, the work has
been installed in ROM).
The requirement to provide Installation Information does not include a
requirement to continue to provide support service, warranty, or updates
for a work that has been modified or installed by the recipient, or for
the User Product in which it has been modified or installed. Access to a
network may be denied when the modification itself materially and
adversely affects the operation of the network or violates the rules and
protocols for communication across the network.
Corresponding Source conveyed, and Installation Information provided,
in accord with this section must be in a format that is publicly
documented (and with an implementation available to the public in
source code form), and must require no special password or key for
unpacking, reading or copying.
7. Additional Terms.
"Additional permissions" are terms that supplement the terms of this
License by making exceptions from one or more of its conditions.
Additional permissions that are applicable to the entire Program shall
be treated as though they were included in this License, to the extent
that they are valid under applicable law. If additional permissions
apply only to part of the Program, that part may be used separately
under those permissions, but the entire Program remains governed by
this License without regard to the additional permissions.
When you convey a copy of a covered work, you may at your option
remove any additional permissions from that copy, or from any part of
it. (Additional permissions may be written to require their own
removal in certain cases when you modify the work.) You may place
additional permissions on material, added by you to a covered work,
for which you have or can give appropriate copyright permission.
Notwithstanding any other provision of this License, for material you
add to a covered work, you may (if authorized by the copyright holders of
that material) supplement the terms of this License with terms:
a) Disclaiming warranty or limiting liability differently from the
terms of sections 15 and 16 of this License; or
b) Requiring preservation of specified reasonable legal notices or
author attributions in that material or in the Appropriate Legal
Notices displayed by works containing it; or
c) Prohibiting misrepresentation of the origin of that material, or
requiring that modified versions of such material be marked in
reasonable ways as different from the original version; or
d) Limiting the use for publicity purposes of names of licensors or
authors of the material; or
e) Declining to grant rights under trademark law for use of some
trade names, trademarks, or service marks; or
f) Requiring indemnification of licensors and authors of that
material by anyone who conveys the material (or modified versions of
it) with contractual assumptions of liability to the recipient, for
any liability that these contractual assumptions directly impose on
those licensors and authors.
All other non-permissive additional terms are considered "further
restrictions" within the meaning of section 10. If the Program as you
received it, or any part of it, contains a notice stating that it is
governed by this License along with a term that is a further
restriction, you may remove that term. If a license document contains
a further restriction but permits relicensing or conveying under this
License, you may add to a covered work material governed by the terms
of that license document, provided that the further restriction does
not survive such relicensing or conveying.
If you add terms to a covered work in accord with this section, you
must place, in the relevant source files, a statement of the
additional terms that apply to those files, or a notice indicating
where to find the applicable terms.
Additional terms, permissive or non-permissive, may be stated in the
form of a separately written license, or stated as exceptions;
the above requirements apply either way.
8. Termination.
You may not propagate or modify a covered work except as expressly
provided under this License. Any attempt otherwise to propagate or
modify it is void, and will automatically terminate your rights under
this License (including any patent licenses granted under the third
paragraph of section 11).
However, if you cease all violation of this License, then your
license from a particular copyright holder is reinstated (a)
provisionally, unless and until the copyright holder explicitly and
finally terminates your license, and (b) permanently, if the copyright
holder fails to notify you of the violation by some reasonable means
prior to 60 days after the cessation.
Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.
Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, you do not qualify to receive new licenses for the same
material under section 10.
9. Acceptance Not Required for Having Copies.
You are not required to accept this License in order to receive or
run a copy of the Program. Ancillary propagation of a covered work
occurring solely as a consequence of using peer-to-peer transmission
to receive a copy likewise does not require acceptance. However,
nothing other than this License grants you permission to propagate or
modify any covered work. These actions infringe copyright if you do
not accept this License. Therefore, by modifying or propagating a
covered work, you indicate your acceptance of this License to do so.
10. Automatic Licensing of Downstream Recipients.
Each time you convey a covered work, the recipient automatically
receives a license from the original licensors, to run, modify and
propagate that work, subject to this License. You are not responsible
for enforcing compliance by third parties with this License.
An "entity transaction" is a transaction transferring control of an
organization, or substantially all assets of one, or subdividing an
organization, or merging organizations. If propagation of a covered
work results from an entity transaction, each party to that
transaction who receives a copy of the work also receives whatever
licenses to the work the party's predecessor in interest had or could
give under the previous paragraph, plus a right to possession of the
Corresponding Source of the work from the predecessor in interest, if
the predecessor has it or can get it with reasonable efforts.
You may not impose any further restrictions on the exercise of the
rights granted or affirmed under this License. For example, you may
not impose a license fee, royalty, or other charge for exercise of
rights granted under this License, and you may not initiate litigation
(including a cross-claim or counterclaim in a lawsuit) alleging that
any patent claim is infringed by making, using, selling, offering for
sale, or importing the Program or any portion of it.
11. Patents.
A "contributor" is a copyright holder who authorizes use under this
License of the Program or a work on which the Program is based. The
work thus licensed is called the contributor's "contributor version".
A contributor's "essential patent claims" are all patent claims
owned or controlled by the contributor, whether already acquired or
hereafter acquired, that would be infringed by some manner, permitted
by this License, of making, using, or selling its contributor version,
but do not include claims that would be infringed only as a
consequence of further modification of the contributor version. For
purposes of this definition, "control" includes the right to grant
patent sublicenses in a manner consistent with the requirements of
this License.
Each contributor grants you a non-exclusive, worldwide, royalty-free
patent license under the contributor's essential patent claims, to
make, use, sell, offer for sale, import and otherwise run, modify and
propagate the contents of its contributor version.
In the following three paragraphs, a "patent license" is any express
agreement or commitment, however denominated, not to enforce a patent
(such as an express permission to practice a patent or covenant not to
sue for patent infringement). To "grant" such a patent license to a
party means to make such an agreement or commitment not to enforce a
patent against the party.
If you convey a covered work, knowingly relying on a patent license,
and the Corresponding Source of the work is not available for anyone
to copy, free of charge and under the terms of this License, through a
publicly available network server or other readily accessible means,
then you must either (1) cause the Corresponding Source to be so
available, or (2) arrange to deprive yourself of the benefit of the
patent license for this particular work, or (3) arrange, in a manner
consistent with the requirements of this License, to extend the patent
license to downstream recipients. "Knowingly relying" means you have
actual knowledge that, but for the patent license, your conveying the
covered work in a country, or your recipient's use of the covered work
in a country, would infringe one or more identifiable patents in that
country that you have reason to believe are valid.
If, pursuant to or in connection with a single transaction or
arrangement, you convey, or propagate by procuring conveyance of, a
covered work, and grant a patent license to some of the parties
receiving the covered work authorizing them to use, propagate, modify
or convey a specific copy of the covered work, then the patent license
you grant is automatically extended to all recipients of the covered
work and works based on it.
A patent license is "discriminatory" if it does not include within
the scope of its coverage, prohibits the exercise of, or is
conditioned on the non-exercise of one or more of the rights that are
specifically granted under this License. You may not convey a covered
work if you are a party to an arrangement with a third party that is
in the business of distributing software, under which you make payment
to the third party based on the extent of your activity of conveying
the work, and under which the third party grants, to any of the
parties who would receive the covered work from you, a discriminatory
patent license (a) in connection with copies of the covered work
conveyed by you (or copies made from those copies), or (b) primarily
for and in connection with specific products or compilations that
contain the covered work, unless you entered into that arrangement,
or that patent license was granted, prior to 28 March 2007.
Nothing in this License shall be construed as excluding or limiting
any implied license or other defenses to infringement that may
otherwise be available to you under applicable patent law.
12. No Surrender of Others' Freedom.
If conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot convey a
covered work so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you may
not convey it at all. For example, if you agree to terms that obligate you
to collect a royalty for further conveying from those to whom you convey
the Program, the only way you could satisfy both those terms and this
License would be to refrain entirely from conveying the Program.
13. Use with the GNU Affero General Public License.
Notwithstanding any other provision of this License, you have
permission to link or combine any covered work with a work licensed
under version 3 of the GNU Affero General Public License into a single
combined work, and to convey the resulting work. The terms of this
License will continue to apply to the part which is the covered work,
but the special requirements of the GNU Affero General Public License,
section 13, concerning interaction through a network will apply to the
combination as such.
14. Revised Versions of this License.
The Free Software Foundation may publish revised and/or new versions of
the GNU General Public License from time to time. Such new versions will
be similar in spirit to the present version, but may differ in detail to
address new problems or concerns.
Each version is given a distinguishing version number. If the
Program specifies that a certain numbered version of the GNU General
Public License "or any later version" applies to it, you have the
option of following the terms and conditions either of that numbered
version or of any later version published by the Free Software
Foundation. If the Program does not specify a version number of the
GNU General Public License, you may choose any version ever published
by the Free Software Foundation.
If the Program specifies that a proxy can decide which future
versions of the GNU General Public License can be used, that proxy's
public statement of acceptance of a version permanently authorizes you
to choose that version for the Program.
Later license versions may give you additional or different
permissions. However, no additional obligations are imposed on any
author or copyright holder as a result of your choosing to follow a
later version.
15. Disclaimer of Warranty.
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. Limitation of Liability.
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
SUCH DAMAGES.
17. Interpretation of Sections 15 and 16.
If the disclaimer of warranty and limitation of liability provided
above cannot be given local legal effect according to their terms,
reviewing courts shall apply local law that most closely approximates
an absolute waiver of all civil liability in connection with the
Program, unless a warranty or assumption of liability accompanies a
copy of the Program in return for a fee.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Programs
If you develop a new program, and you want it to be of the greatest
possible use to the public, the best way to achieve this is to make it
free software which everyone can redistribute and change under these terms.
To do so, attach the following notices to the program. It is safest
to attach them to the start of each source file to most effectively
state the exclusion of warranty; and each file should have at least
the "copyright" line and a pointer to where the full notice is found.
<one line to give the program's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
Also add information on how to contact you by electronic and paper mail.
If the program does terminal interaction, make it output a short
notice like this when it starts in an interactive mode:
<program> Copyright (C) <year> <name of author>
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
This is free software, and you are welcome to redistribute it
under certain conditions; type `show c' for details.
The hypothetical commands `show w' and `show c' should show the appropriate
parts of the General Public License. Of course, your program's commands
might be different; for a GUI interface, you would use an "about box".
You should also get your employer (if you work as a programmer) or school,
if any, to sign a "copyright disclaimer" for the program, if necessary.
For more information on this, and how to apply and follow the GNU GPL, see
<https://www.gnu.org/licenses/>.
The GNU General Public License does not permit incorporating your program
into proprietary programs. If your program is a subroutine library, you
may consider it more useful to permit linking proprietary applications with
the library. If this is what you want to do, use the GNU Lesser General
Public License instead of this License. But first, please read
<https://www.gnu.org/licenses/why-not-lgpl.html>.

View File

@ -1,6 +1,8 @@
# OpenAuto
[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](code_of_conduct.md)
### Support project
[![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=R4HXE5ESDR4U4)
@ -48,5 +50,24 @@ Copyrights (c) 2018 f1x.studio (Michal Szwaj)
- Broadcom ilclient from RaspberryPI 3 firmware
- OpenMAX IL API
### Building
#### Amd64
Install the packages specified in the [prebuilts](https://github.com/opencardev/prebuilts) repository. Qt5 is required, versions packaged in modern Ubuntu and Debian
seem to work fine.
You will also likely need to install the udev rules from `prebuilts`
You need to point some CMAKE variables at your `aasdk` files.
```text
-DAASDK_INCLUDE_DIRS=<path_to_aasdk_repo>/include
-DAASDK_LIBRARIES=<path_to_aasdk_repo>/lib/libaasdk.so
DAASDK_PROTO_INCLUDE_DIRS=<path_to_aasdk_build>
-DAASDK_PROTO_LIBRARIES=<path_to_aasdk_repo>/lib/libaasdk_proto.so
```
#### Raspberry Pi
Just run the scripts in the `prebuilts` repository for `aasdk` and `openauto`. It is possible to cross compile if your raspberry pi is too slow to compile the code itself.
However, its easiest to just develop on a more capable `amd64` device.
### Remarks
**This software is not certified by Google Inc. It is created for R&D purposes and may not work as expected by the original authors. Do not use while driving. You use this software at your own risk.**

15
RELEASE.txt Normal file
View File

@ -0,0 +1,15 @@
Release Notes
20241124 - 4.1.0 - Bluetooth Updates
* Rename BluetootAdapterType to BluetoothAdapterType, and change from NONE, LOCAL, REMOTE to NONE, LOCAL, EXTERNAL to better match available settings
* getLocalAddress() on Dummy, Local and Remote bluetooth changed to getAdapterAddress()
* Removed RemoteBluetoothDevice replacing all references with LocalBluetoothDevice. RemoteBluetoothDevice is a wrapper essentially with all pairing work handled by btservice.
* Pairing overlaps between btservice and LocalBluetoothDevice - removed duplicated elements from LocalBluetoothDevice to rely on btservice.
* Swap Bluetooth dropdown in Settings from none, builtin or external, to showing a list of detected Bluetooth Adapters. Write hardware address to config file.
20241121 - 4.0.0 - AAP 1.6 Support
* Added support for new services provided by AASDK and AAP Protocol version 1.6.
* Add extensive logging
* Add logo for forked version
* Resolve display issue where if Raspberry Pi thinks both HDMI and LCD are enabled, the display width is appearing as two side by side monitors (double width) rather than just using the physical width of the screen.

BIN
assets/Roboto-Regular.ttf Normal file

Binary file not shown.

BIN
assets/aausb-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

BIN
assets/aawifi-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

BIN
assets/album-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

BIN
assets/album.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 896 B

BIN
assets/artist.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 935 B

BIN
assets/back-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 340 B

BIN
assets/black.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 452 B

BIN
assets/bluetooth.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 931 B

BIN
assets/brightness-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 687 B

BIN
assets/bug-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 701 B

BIN
assets/camera-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 391 B

BIN
assets/coverlogo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
assets/cursor-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB

BIN
assets/day-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 812 B

BIN
assets/eye-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 631 B

BIN
assets/home-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 660 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.3 KiB

BIN
assets/ico_info.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 438 B

After

Width:  |  Height:  |  Size: 310 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.5 KiB

BIN
assets/ico_warning.png Executable file → Normal file

Binary file not shown.

Before

Width:  |  Height:  |  Size: 751 B

After

Width:  |  Height:  |  Size: 550 B

BIN
assets/journey.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 93 KiB

BIN
assets/list-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 870 B

BIN
assets/lock-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 496 B

BIN
assets/mp3-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 752 B

BIN
assets/next-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 390 B

BIN
assets/nextbig-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

BIN
assets/night-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 589 B

BIN
assets/pause-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 242 B

BIN
assets/play-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 369 B

BIN
assets/player-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 433 B

BIN
assets/power-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 658 B

BIN
assets/prev-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 394 B

BIN
assets/prevbig-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

BIN
assets/radio.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 816 B

BIN
assets/rearcam-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 416 B

BIN
assets/reboot-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 560 B

BIN
assets/record-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 332 B

BIN
assets/recordactive-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 477 B

View File

@ -1,8 +1,48 @@
<RCC>
<qresource prefix="/">
<file>ico_androidauto.png</file>
<file>ico_warning.png</file>
<file>ico_setting.png</file>
<file>ico_info.png</file>
<file>radio.png</file>
<file>song.png</file>
<file>bluetooth.png</file>
<file>artist.png</file>
<file>album.png</file>
<file>aausb-hot.png</file>
<file>aawifi-hot.png</file>
<file>cursor-hot.png</file>
<file>power-hot.png</file>
<file>settings-hot.png</file>
<file>sleep-hot.png</file>
<file>wifi-hot.png</file>
<file>brightness-hot.png</file>
<file>camera-hot.png</file>
<file>day-hot.png</file>
<file>night-hot.png</file>
<file>record-hot.png</file>
<file>stop-hot.png</file>
<file>save-hot.png</file>
<file>reboot-hot.png</file>
<file>back-hot.png</file>
<file>rearcam-hot.png</file>
<file>recordactive-hot.png</file>
<file>lock-hot.png</file>
<file>volume-hot.png</file>
<file>bug-hot.png</file>
<file>eye-hot.png</file>
<file>skin-hot.png</file>
<file>mp3-hot.png</file>
<file>play-hot.png</file>
<file>prev-hot.png</file>
<file>next-hot.png</file>
<file>pause-hot.png</file>
<file>prevbig-hot.png</file>
<file>nextbig-hot.png</file>
<file>list-hot.png</file>
<file>home-hot.png</file>
<file>player-hot.png</file>
<file>coverlogo.png</file>
<file>black.png</file>
<file>album-hot.png</file>
<file>Roboto-Regular.ttf</file>
</qresource>
</RCC>

BIN
assets/save-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 370 B

BIN
assets/settings-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 678 B

BIN
assets/skin-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 686 B

BIN
assets/sleep-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 665 B

BIN
assets/song.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 821 B

BIN
assets/stop-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 239 B

BIN
assets/volume-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 685 B

BIN
assets/wifi-hot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 782 B

49
buildenv/Dockerfile Normal file
View File

@ -0,0 +1,49 @@
FROM debian:buster AS prebuilts
COPY ./buildenv/pi_binaries/buster.tar.gz buster.tar.gz
COPY ./buildenv/pi_binaries/aasdk_armhf.deb aasdk_armhf.deb
RUN apt-get update &&\
apt-get -y install cmake build-essential git zip &&\
git clone https://github.com/SonOfGib/prebuilts.git &&\
mkdir qt5 &&\
cat prebuilts/qt5/Qt_5151_armv7l_OpenGLES2.tar.xz* > Qt5_OpenGLES2.tar.xz
FROM debian:buster AS openauto
COPY --from=prebuilts Qt5_OpenGLES2.tar.xz Qt5_OpenGLES2.tar.xz
COPY --from=prebuilts buster.tar.gz buster.tar.gz
COPY --from=prebuilts aasdk_armhf.deb aasdk_armhf.deb
RUN dpkg --add-architecture armhf &&\
apt-get update &&\
apt-get -y install cmake build-essential git &&\
apt-get -y install gcc-arm-linux-gnueabihf cpp-arm-linux-gnueabihf g++-arm-linux-gnueabihf protobuf-compiler &&\
apt-get -y install gcc-8-base:armhf libc6:armhf libgcc1:armhf libicu63:armhf libidn2-0:armhf libstdc++6:armhf libunistring2:armhf pulseaudio:armhf librtaudio-dev:armhf libgps-dev:armhf libblkid-dev:armhf libtag1-dev:armhf libgles2-mesa-dev:armhf libdouble-conversion-dev:armhf &&\
tar -xf Qt5_OpenGLES2.tar.xz -C / &&\
tar -xf buster.tar.gz -C /
# These are all the libboost requirements. It would be shorter if libboost-log-dev wasn't a disaster that's being dealt with manually.
RUN apt-get install -y libprotobuf-dev libusb-1.0.0-dev libssl-dev libboost-dev libboost-system-dev libboost-atomic1.67.0 libboost-chrono1.67.0 libboost-date-time1.67.0 libboost-filesystem1.67.0 libboost-regex1.67.0 libboost-thread1.67.0 libboost-filesystem1.67-dev libboost-thread1.67-dev libboost-date-time1.67-dev &&\
apt-get install -y libprotobuf-dev:armhf libusb-1.0.0-dev:armhf libssl-dev:armhf libboost-dev:armhf libboost-system-dev:armhf libboost-atomic1.67.0:armhf libboost-chrono1.67.0:armhf libboost-date-time1.67.0:armhf libboost-filesystem1.67.0:armhf libboost-regex1.67.0:armhf libboost-system1.67.0:armhf libboost-thread1.67.0:armhf libboost-filesystem1.67-dev:armhf libboost-thread1.67-dev:armhf libboost-date-time1.67-dev:armhf
COPY / /src
WORKDIR /src
# Import resources
COPY ./buildenv/patch-libboost-log-deb.sh /src/resources/patch-libboost-log-deb.sh
COPY ./buildenv/entrypoint.sh /entrypoint.sh
# Patch libboost-log-dev and install
RUN chmod +x ./resources/patch-libboost-log-deb.sh
RUN ./resources/patch-libboost-log-deb.sh
# Make Executable
RUN chmod +x /entrypoint.sh
WORKDIR /
RUN dpkg-deb -xv aasdk_armhf.deb /
WORKDIR /src
ENTRYPOINT ["/bin/bash", "/entrypoint.sh"]

16
buildenv/cross-compile.md Normal file
View File

@ -0,0 +1,16 @@
### RPI Cross Compile
The docker image in this folder is intended to be used to cross compile `openauto` without having to configure your
host pc with multiarch or installing a toolchain.
#### Setup
The `openauto` build for RPI3 requires some files from the PI, as well as aasdk libraries compiled for amrhf.
- RPI files should be compressed to `buildenv/pi_binaries/buster.tar.gz`. The files required in the archive should
match the path/files in the `if(RPI3_BUILD)` section of `CMakeLists.txt`
- Copy the `.deb` file from `aasdk` docker cross compile build and place it in `buildenv/pi_binaries/aasdk_armhf.dev`
#### Build
```bash
cd buildenv
sudo docker compose up --build
```
Binary files will then be available in `buildenv/release`.

View File

@ -0,0 +1,7 @@
services:
openauto-build:
build:
context: ../
dockerfile: buildenv/Dockerfile
volumes:
- ./release/:/release/

14
buildenv/entrypoint.sh Normal file
View File

@ -0,0 +1,14 @@
#!/bin/bash
# Clear out the /build directory
mkdir build;
cd build;
cmake -DCMAKE_BUILD_TYPE=Release -DRPI3_BUILD=true -DCROSS_COMPILE_ARMHF=true -DAASDK_INCLUDE_DIRS=/usr/include/aasdk -DAASDK_LIBRARIES=/usr/lib/libaasdk.so -DAASDK_PROTO_INCLUDE_DIRS=/usr/include/aasdk_proto -DAASDK_PROTO_LIBRARIES=/usr/lib/libaasdk_proto.so ../
make -j4
cd ../bin
# Move it to release
rm -f /release/autoapp
rm -f /release/btservice
mv autoapp /release
mv btservice /release

View File

@ -0,0 +1,46 @@
# All this because of a packaging bug in libboost-log-dev
# 'Multi-Arch: same' is not present in the control file of Debian packages, all the way up to Sid
# Rather than recompiling the parent libbost suite, download the 6 packages, extract, edit, and repackage.
# https://bugs.debian.org/cgi-bin/pkgreport.cgi?package=libboost-log-dev
apt-get -y install --download-only libboost-log-dev:amd64 libboost-log1.67.0:amd64 libboost-log1.67-dev:amd64
apt-get -y install --download-only libboost-log-dev:armhf libboost-log1.67.0:armhf libboost-log1.67-dev:armhf
mkdir -p /tmp/armhf/libboost-log-dev/
dpkg-deb -x /var/cache/apt/archives/libboost-log-dev_1.67.0.1_armhf.deb /tmp/armhf/libboost-log-dev/
dpkg-deb -e /var/cache/apt/archives/libboost-log-dev_1.67.0.1_armhf.deb /tmp/armhf/libboost-log-dev/DEBIAN/
sed -i '/^Priority: optional/a Multi-Arch: same' /tmp/armhf/libboost-log-dev/DEBIAN/control
dpkg-deb -b /tmp/armhf/libboost-log-dev/ /tmp/libboost-log-dev_1.67.0.1_armhf.deb
mkdir -p /tmp/amd64/libboost-log-dev/
dpkg-deb -x /var/cache/apt/archives/libboost-log-dev_1.67.0.1_amd64.deb /tmp/amd64/libboost-log-dev/
dpkg-deb -e /var/cache/apt/archives/libboost-log-dev_1.67.0.1_amd64.deb /tmp/amd64/libboost-log-dev/DEBIAN/
sed -i '/^Priority: optional/a Multi-Arch: same' /tmp/amd64/libboost-log-dev/DEBIAN/control
dpkg-deb -b /tmp/amd64/libboost-log-dev/ /tmp/libboost-log-dev_1.67.0.1_amd64.deb
mkdir -p /tmp/armhf/libboost-log1.67-dev/
dpkg-deb -x /var/cache/apt/archives/libboost-log1.67-dev_1.67.0-13+deb10u1_armhf.deb /tmp/armhf/libboost-log1.67-dev/
dpkg-deb -e /var/cache/apt/archives/libboost-log1.67-dev_1.67.0-13+deb10u1_armhf.deb /tmp/armhf/libboost-log1.67-dev/DEBIAN/
sed -i '/^Priority: optional/a Multi-Arch: same' /tmp/armhf/libboost-log1.67-dev/DEBIAN/control
dpkg-deb -b /tmp/armhf/libboost-log1.67-dev/ /tmp/libboost-log1.67-dev_1.67.0-13+deb10u1_armhf.deb
mkdir -p /tmp/amd64/libboost-log1.67-dev/
dpkg-deb -x /var/cache/apt/archives/libboost-log1.67-dev_1.67.0-13+deb10u1_amd64.deb /tmp/amd64/libboost-log1.67-dev/
dpkg-deb -e /var/cache/apt/archives/libboost-log1.67-dev_1.67.0-13+deb10u1_amd64.deb /tmp/amd64/libboost-log1.67-dev/DEBIAN/
sed -i '/^Priority: optional/a Multi-Arch: same' /tmp/amd64/libboost-log1.67-dev/DEBIAN/control
dpkg-deb -b /tmp/amd64/libboost-log1.67-dev/ /tmp/libboost-log1.67-dev_1.67.0-13+deb10u1_amd64.deb
mkdir -p /tmp/armhf/libboost-log1.67.0/
dpkg-deb -x /var/cache/apt/archives/libboost-log1.67.0_1.67.0-13+deb10u1_armhf.deb /tmp/armhf/libboost-log1.67.0/
dpkg-deb -e /var/cache/apt/archives/libboost-log1.67.0_1.67.0-13+deb10u1_armhf.deb /tmp/armhf/libboost-log1.67.0/DEBIAN/
sed -i '/^Priority: optional/a Multi-Arch: same' /tmp/armhf/libboost-log1.67.0/DEBIAN/control
dpkg-deb -b /tmp/armhf/libboost-log1.67.0/ /tmp/libboost-log1.67.0_1.67.0-13+deb10u1_armhf.deb
mkdir -p /tmp/amd64/libboost-log1.67.0/
dpkg-deb -x /var/cache/apt/archives/libboost-log1.67.0_1.67.0-13+deb10u1_amd64.deb /tmp/amd64/libboost-log1.67.0/
dpkg-deb -e /var/cache/apt/archives/libboost-log1.67.0_1.67.0-13+deb10u1_amd64.deb /tmp/amd64/libboost-log1.67.0/DEBIAN/
sed -i '/^Priority: optional/a Multi-Arch: same' /tmp/amd64/libboost-log1.67.0/DEBIAN/control
dpkg-deb -b /tmp/amd64/libboost-log1.67.0/ /tmp/libboost-log1.67.0_1.67.0-13+deb10u1_amd64.deb
dpkg -i /tmp/libboost*.deb

2
buildenv/pi_binaries/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
*
!.gitignore

2
buildenv/release/.gitignore vendored Normal file
View File

@ -0,0 +1,2 @@
*
!.gitignore

View File

@ -0,0 +1,55 @@
if (AAP_PROTOBUF_LIB_DIRS AND AAP_PROTOBUF_INCLUDE_DIRS)
# in cache already
message(STATUS "aap_protobuf is cached")
set(AAP_PROTOBUF_FOUND TRUE)
else (AAP_PROTOBUF_LIB_DIRS AND AAP_PROTOBUF_INCLUDE_DIRS)
find_path(AAP_PROTOBUF_INCLUDE_DIR
NAMES
channel/control/GalConstants.pb.h
PATHS
/usr/include
/usr/local/include
/opt/local/include
/sw/include
PATH_SUFFIXES
aap_protobuf
)
find_library(AAP_PROTOBUF_LIB_DIR
NAMES
aap_protobuf libaap_protobuf
PATHS
/usr/lib
/usr/local/lib
/opt/local/lib
/sw/lib
)
set(AAP_PROTOBUF_INCLUDE_DIRS
${AAP_PROTOBUF_INCLUDE_DIR}
)
set(AAP_PROTOBUF_LIB_DIRS
${AAP_PROTOBUF_LIB_DIR}
)
if (AAP_PROTOBUF_INCLUDE_DIRS AND AAP_PROTOBUF_LIB_DIRS)
set(AAP_PROTOBUF_FOUND TRUE)
endif (AAP_PROTOBUF_INCLUDE_DIRS AND AAP_PROTOBUF_LIB_DIRS)
if (AAP_PROTOBUF_FOUND)
message(STATUS "SUCCESS. Found: aap_protobuf:")
message(STATUS " - Includes: ${AAP_PROTOBUF_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${AAP_PROTOBUF_LIB_DIRS}")
add_library(aap_protobuf INTERFACE)
target_include_directories(aap_protobuf SYSTEM INTERFACE ${AAP_PROTOBUF_INCLUDE_DIR})
target_link_libraries(aap_protobuf INTERFACE ${AAP_PROTOBUF_LIB_DIR})
else (AAP_PROTOBUF_FOUND)
message(STATUS " - Includes: ${AAP_PROTOBUF_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${AAP_PROTOBUF_LIB_DIRS}")
message(FATAL_ERROR "Could not locate aap_protobuf")
endif (AAP_PROTOBUF_FOUND)
# show the AAP_PROTOBUF_INCLUDE_DIRS and AAP_PROTOBUF_LIB_DIRS variables only in the advanced view
mark_as_advanced(AAP_PROTOBUF_INCLUDE_DIRS AAP_PROTOBUF_LIB_DIRS)
endif (AAP_PROTOBUF_LIB_DIRS AND AAP_PROTOBUF_INCLUDE_DIRS)

View File

@ -0,0 +1,55 @@
if (AASDK_LIB_DIRS AND AASDK_INCLUDE_DIRS)
# in cache already
message(STATUS "aasdk cached")
set(AASDK_FOUND TRUE)
else (AASDK_LIB_DIRS AND AASDK_INCLUDE_DIRS)
find_path(AASDK_INCLUDE_DIR
NAMES
Version.hpp
PATHS
/usr/include
/usr/local/include
/opt/local/include
/sw/include
PATH_SUFFIXES
aasdk
)
find_library(AASDK_LIB_DIR
NAMES
aasdk libaasdk
PATHS
/usr/lib
/usr/local/lib
/opt/local/lib
/sw/lib
)
set(AASDK_INCLUDE_DIRS
${AASDK_INCLUDE_DIR}
)
set(AASDK_LIB_DIRS
${AASDK_LIB_DIR}
)
if (AASDK_INCLUDE_DIRS AND AASDK_LIB_DIRS)
set(AASDK_FOUND TRUE)
endif (AASDK_INCLUDE_DIRS AND AASDK_LIB_DIRS)
if (AASDK_FOUND)
message(STATUS "Found aasdk:")
message(STATUS " - Includes: ${AASDK_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${AASDK_LIB_DIRS}")
add_library(aasdk INTERFACE)
target_include_directories(aasdk SYSTEM INTERFACE ${AASDK_INCLUDE_DIR})
target_link_libraries(aasdk INTERFACE ${AASDK_LIB_DIR})
else (AASDK_FOUND)
message(STATUS " - Includes: ${AASDK_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${AASDK_LIB_DIRS}")
message(FATAL_ERROR "Could not find aasdk")
endif (AASDK_FOUND)
# show the AASDK_INCLUDE_DIRS and AASDK_LIB_DIRS variables only in the advanced view
mark_as_advanced(AASDK_INCLUDE_DIRS AASDK_LIB_DIRS)
endif (AASDK_LIB_DIRS AND AASDK_INCLUDE_DIRS)

View File

@ -0,0 +1,70 @@
#
# This file is part of openauto project.
# Copyright (C) 2018 f1x.studio (Michal Szwaj)
#
# openauto is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
# openauto is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with openauto. If not, see <http://www.gnu.org/licenses/>.
#
if (BLKID_LIBRARIES AND BLKID_INCLUDE_DIRS)
# in cache already
set(BLKID_FOUND TRUE)
else (BLKID_LIBRARIES AND BLKID_INCLUDE_DIRS)
find_path(BLKID_INCLUDE_DIR
NAMES
blkid.h
PATHS
/usr/include
/usr/local/include
/opt/local/include
/sw/include
PATH_SUFFIXES
blkid
)
find_library(BLKID_LIBRARY
NAMES
blkid
PATHS
/usr/lib
/usr/local/lib
/opt/local/lib
/sw/lib
)
set(BLKID_INCLUDE_DIRS
${BLKID_INCLUDE_DIR}
)
set(BLKID_LIBRARIES
${BLKID_LIBRARY}
)
if (BLKID_INCLUDE_DIRS AND BLKID_LIBRARIES)
set(BLKID_FOUND TRUE)
endif (BLKID_INCLUDE_DIRS AND BLKID_LIBRARIES)
if (BLKID_FOUND)
if (NOT blkid_FIND_QUIETLY)
message(STATUS "Found blkid:")
message(STATUS " - Includes: ${BLKID_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${BLKID_LIBRARIES}")
endif (NOT blkid_FIND_QUIETLY)
else (BLKID_FOUND)
if (blkid_FIND_REQUIRED)
message(FATAL_ERROR "Could not find blkid")
endif (blkid_FIND_REQUIRED)
endif (BLKID_FOUND)
mark_as_advanced(BLKID_INCLUDE_DIRS BLKID_LIBRARIES)
endif (BLKID_LIBRARIES AND BLKID_INCLUDE_DIRS)

View File

@ -0,0 +1,70 @@
#
# This file is part of openauto project.
# Copyright (C) 2018 f1x.studio (Michal Szwaj)
#
# openauto is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
# openauto is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with openauto. If not, see <http://www.gnu.org/licenses/>.
#
if (GPS_LIBRARIES AND GPS_INCLUDE_DIRS)
# in cache already
set(GPS_FOUND TRUE)
else (GPS_LIBRARIES AND GPS_INCLUDE_DIRS)
find_path(GPS_INCLUDE_DIR
NAMES
gps.h
PATHS
/usr/include
/usr/local/include
/opt/local/include
/sw/include
PATH_SUFFIXES
gps
)
find_library(GPS_LIBRARY
NAMES
gps
PATHS
/usr/lib
/usr/local/lib
/opt/local/lib
/sw/lib
)
set(GPS_INCLUDE_DIRS
${GPS_INCLUDE_DIR}
)
set(GPS_LIBRARIES
${GPS_LIBRARY}
)
if (GPS_INCLUDE_DIRS AND GPS_LIBRARIES)
set(GPS_FOUND TRUE)
endif (GPS_INCLUDE_DIRS AND GPS_LIBRARIES)
if (GPS_FOUND)
if (NOT gps_FIND_QUIETLY)
message(STATUS "Found gps:")
message(STATUS " - Includes: ${GPS_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${GPS_LIBRARIES}")
endif (NOT gps_FIND_QUIETLY)
else (GPS_FOUND)
if (gps_FIND_REQUIRED)
message(FATAL_ERROR "Could not find gps")
endif (gps_FIND_REQUIRED)
endif (GPS_FOUND)
mark_as_advanced(GPS_INCLUDE_DIRS GPS_LIBRARIES)
endif (GPS_LIBRARIES AND GPS_INCLUDE_DIRS)

View File

@ -85,11 +85,14 @@ else (LIBUSB_1_LIBRARIES AND LIBUSB_1_INCLUDE_DIRS)
message(STATUS "Found libusb-1.0:")
message(STATUS " - Includes: ${LIBUSB_1_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${LIBUSB_1_LIBRARIES}")
add_library(libusb INTERFACE)
target_include_directories(libusb SYSTEM INTERFACE ${LIBUSB_1_INCLUDE_DIR})
target_link_libraries(libusb INTERFACE ${LIBUSB_1_LIBRARY})
endif (NOT libusb_1_FIND_QUIETLY)
else (LIBUSB_1_FOUND)
if (libusb_1_FIND_REQUIRED)
if (libusb-1.0_FIND_REQUIRED)
message(FATAL_ERROR "Could not find libusb")
endif (libusb_1_FIND_REQUIRED)
endif (libusb-1.0_FIND_REQUIRED)
endif (LIBUSB_1_FOUND)
# show the LIBUSB_1_INCLUDE_DIRS and LIBUSB_1_LIBRARIES variables only in the advanced view

View File

@ -0,0 +1,70 @@
#
# This file is part of openauto project.
# Copyright (C) 2018 f1x.studio (Michal Szwaj)
#
# openauto is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
# openauto is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with openauto. If not, see <http://www.gnu.org/licenses/>.
#
if (TAGLIB_LIBRARIES AND TAGLIB_INCLUDE_DIRS)
# in cache already
set(TAGLIB_FOUND TRUE)
else (TAGLIB_LIBRARIES AND TAGLIB_INCLUDE_DIRS)
find_path(TAGLIB_INCLUDE_DIR
NAMES
taglib.h
PATHS
/usr/include
/usr/local/include
/opt/local/include
/sw/include
PATH_SUFFIXES
taglib
)
find_library(TAGLIB_LIBRARY
NAMES
tag taglib libtag
PATHS
/usr/lib
/usr/local/lib
/opt/local/lib
/sw/lib
)
set(TAGLIB_INCLUDE_DIRS
${TAGLIB_INCLUDE_DIR}
)
set(TAGLIB_LIBRARIES
${TAGLIB_LIBRARY} -ltag
)
if (TAGLIB_INCLUDE_DIRS AND TAGLIB_LIBRARIES)
set(TAGLIB_FOUND TRUE)
endif (TAGLIB_INCLUDE_DIRS AND TAGLIB_LIBRARIES)
if (TAGLIB_FOUND)
if (NOT taglib_FIND_QUIETLY)
message(STATUS "Found taglib:")
message(STATUS " - Includes: ${TAGLIB_INCLUDE_DIRS}")
message(STATUS " - Libraries: ${TAGLIB_LIBRARIES}")
endif (NOT taglib_FIND_QUIETLY)
else (TAGLIB_FOUND)
if (taglib_FIND_REQUIRED)
message(FATAL_ERROR "Could not find taglib")
endif (taglib_FIND_REQUIRED)
endif (TAGLIB_FOUND)
mark_as_advanced(TAGLIB_INCLUDE_DIRS TAGLIB_LIBRARIES)
endif (TAGLIB_LIBRARIES AND TAGLIB_INCLUDE_DIRS)

133
code_of_conduct.md Normal file
View File

@ -0,0 +1,133 @@
# Contributor Covenant Code of Conduct
## Our Pledge
We as members, contributors, and leaders pledge to make participation in our
community a harassment-free experience for everyone, regardless of age, body
size, visible or invisible disability, ethnicity, sex characteristics, gender
identity and expression, level of experience, education, socio-economic status,
nationality, personal appearance, race, caste, color, religion, or sexual
identity and orientation.
We pledge to act and interact in ways that contribute to an open, welcoming,
diverse, inclusive, and healthy community.
## Our Standards
Examples of behavior that contributes to a positive environment for our
community include:
* Demonstrating empathy and kindness toward other people
* Being respectful of differing opinions, viewpoints, and experiences
* Giving and gracefully accepting constructive feedback
* Accepting responsibility and apologizing to those affected by our mistakes,
and learning from the experience
* Focusing on what is best not just for us as individuals, but for the overall
community
Examples of unacceptable behavior include:
* The use of sexualized language or imagery, and sexual attention or advances of
any kind
* Trolling, insulting or derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or email address,
without their explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting
## Enforcement Responsibilities
Community leaders are responsible for clarifying and enforcing our standards of
acceptable behavior and will take appropriate and fair corrective action in
response to any behavior that they deem inappropriate, threatening, offensive,
or harmful.
Community leaders have the right and responsibility to remove, edit, or reject
comments, commits, code, wiki edits, issues, and other contributions that are
not aligned to this Code of Conduct, and will communicate reasons for moderation
decisions when appropriate.
## Scope
This Code of Conduct applies within all community spaces, and also applies when
an individual is officially representing the community in public spaces.
Examples of representing our community include using an official email address,
posting via an official social media account, or acting as an appointed
representative at an online or offline event.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be
reported to the community leaders responsible for enforcement at [let us know][CONTACT].
All complaints will be reviewed and investigated promptly and fairly.
All community leaders are obligated to respect the privacy and security of the
reporter of any incident.
## Enforcement Guidelines
Community leaders will follow these Community Impact Guidelines in determining
the consequences for any action they deem in violation of this Code of Conduct:
### 1. Correction
**Community Impact**: Use of inappropriate language or other behavior deemed
unprofessional or unwelcome in the community.
**Consequence**: A private, written warning from community leaders, providing
clarity around the nature of the violation and an explanation of why the
behavior was inappropriate. A public apology may be requested.
### 2. Warning
**Community Impact**: A violation through a single incident or series of
actions.
**Consequence**: A warning with consequences for continued behavior. No
interaction with the people involved, including unsolicited interaction with
those enforcing the Code of Conduct, for a specified period of time. This
includes avoiding interactions in community spaces as well as external channels
like social media. Violating these terms may lead to a temporary or permanent
ban.
### 3. Temporary Ban
**Community Impact**: A serious violation of community standards, including
sustained inappropriate behavior.
**Consequence**: A temporary ban from any sort of interaction or public
communication with the community for a specified period of time. No public or
private interaction with the people involved, including unsolicited interaction
with those enforcing the Code of Conduct, is allowed during this period.
Violating these terms may lead to a permanent ban.
### 4. Permanent Ban
**Community Impact**: Demonstrating a pattern of violation of community
standards, including sustained inappropriate behavior, harassment of an
individual, or aggression toward or disparagement of classes of individuals.
**Consequence**: A permanent ban from any sort of public interaction within the
community.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
version 2.1, available at
[https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1].
Community Impact Guidelines were inspired by
[Mozilla's code of conduct enforcement ladder][Mozilla CoC].
For answers to common questions about this code of conduct, see the FAQ at
[https://www.contributor-covenant.org/faq][FAQ]. Translations are available at
[https://www.contributor-covenant.org/translations][translations].
[homepage]: https://www.contributor-covenant.org
[v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
[Mozilla CoC]: https://github.com/mozilla/diversity
[FAQ]: https://www.contributor-covenant.org/faq
[translations]: https://www.contributor-covenant.org/translations
[CONTACT]: mailto:info@getcrankshaft.com

View File

@ -20,4 +20,5 @@
#include <boost/log/trivial.hpp>
#define OPENAUTO_LOG(severity) BOOST_LOG_TRIVIAL(severity) << "[OpenAuto] "
#define OPENAUTO_LOG_CONTEXT "" //"(" << typeid(*this).name() << "::" << __func__ << ")"
#define OPENAUTO_LOG(severity) BOOST_LOG_TRIVIAL(severity) << "[OpenAuto] " << OPENAUTO_LOG_CONTEXT

View File

@ -18,11 +18,11 @@
#pragma once
#include <f1x/aasdk/USB/IUSBHub.hpp>
#include <f1x/aasdk/USB/IConnectedAccessoriesEnumerator.hpp>
#include <f1x/aasdk/USB/USBWrapper.hpp>
#include <f1x/aasdk/TCP/ITCPWrapper.hpp>
#include <f1x/aasdk/TCP/ITCPEndpoint.hpp>
#include <aasdk/USB/IUSBHub.hpp>
#include <aasdk/USB/IConnectedAccessoriesEnumerator.hpp>
#include <aasdk/USB/USBWrapper.hpp>
#include <aasdk/TCP/ITCPWrapper.hpp>
#include <aasdk/TCP/ITCPEndpoint.hpp>
#include <f1x/openauto/autoapp/Service/IAndroidAutoEntityEventHandler.hpp>
#include <f1x/openauto/autoapp/Service/IAndroidAutoEntityFactory.hpp>
@ -44,7 +44,10 @@ public:
void waitForUSBDevice();
void start(aasdk::tcp::ITCPEndpoint::SocketPointer socket);
void stop();
void pause();
void resume();
void onAndroidAutoQuit() override;
bool disableAutostartEntity = false;
private:
using std::enable_shared_from_this<App>::shared_from_this;
@ -56,12 +59,17 @@ private:
boost::asio::io_service& ioService_;
aasdk::usb::USBWrapper& usbWrapper_;
aasdk::tcp::ITCPWrapper& tcpWrapper_;
boost::asio::ip::tcp::acceptor acceptor_;
boost::asio::io_service::strand strand_;
service::IAndroidAutoEntityFactory& androidAutoEntityFactory_;
aasdk::usb::IUSBHub::Pointer usbHub_;
aasdk::usb::IConnectedAccessoriesEnumerator::Pointer connectedAccessoriesEnumerator_;
service::IAndroidAutoEntity::Pointer androidAutoEntity_;
bool isStopped_;
void startServerSocket();
void handleNewClient(std::shared_ptr<boost::asio::ip::tcp::socket> socket, const boost::system::error_code &err);
};
}

View File

@ -18,23 +18,15 @@
#pragma once
namespace f1x
{
namespace openauto
{
namespace autoapp
{
namespace configuration
{
enum class BluetoothAdapterType
{
namespace f1x::openauto::autoapp::configuration {
enum class BluetoothAdapterType {
NONE,
LOCAL,
REMOTE
EXTERNAL
};
}
}
}
}
}

View File

@ -20,6 +20,11 @@
#include <boost/property_tree/ini_parser.hpp>
#include <f1x/openauto/autoapp/Configuration/IConfiguration.hpp>
#include <iostream>
#include <string>
#include <fstream>
#include <stdio.h>
namespace f1x
{
@ -39,15 +44,55 @@ public:
void reset() override;
void save() override;
bool hasTouchScreen() const override;
void setHandednessOfTrafficType(HandednessOfTrafficType value) override;
HandednessOfTrafficType getHandednessOfTrafficType() const override;
void showClock(bool value) override;
bool showClock() const override;
aasdk::proto::enums::VideoFPS::Enum getVideoFPS() const override;
void setVideoFPS(aasdk::proto::enums::VideoFPS::Enum value) override;
aasdk::proto::enums::VideoResolution::Enum getVideoResolution() const override;
void setVideoResolution(aasdk::proto::enums::VideoResolution::Enum value) override;
void showBigClock(bool value) override;
bool showBigClock() const override;
void oldGUI(bool value) override;
bool oldGUI() const override;
void setAlphaTrans(size_t value) override;
size_t getAlphaTrans() const override;
void hideMenuToggle(bool value) override;
bool hideMenuToggle() const override;
void hideAlpha(bool value) override;
bool hideAlpha() const override;
void showLux(bool value) override;
bool showLux() const override;
void showCursor(bool value) override;
bool showCursor() const override;
void hideBrightnessControl(bool value) override;
bool hideBrightnessControl() const override;
void showNetworkinfo(bool value) override;
bool showNetworkinfo() const override;
void hideWarning(bool value) override;
bool hideWarning() const override;
std::string getMp3MasterPath() const override;
void setMp3MasterPath(const std::string& value) override;
std::string getMp3SubFolder() const override;
void setMp3SubFolder(const std::string& value) override;
int32_t getMp3Track() const override;
void setMp3Track(int32_t value) override;
bool mp3AutoPlay() const override;
void mp3AutoPlay(bool value) override;
bool showAutoPlay() const override;
void showAutoPlay(bool value) override;
bool instantPlay() const override;
void instantPlay(bool value) override;
QString getCSValue(QString searchString) const override;
QString readFileContent(QString fileName) const override;
QString getParamFromFile(QString fileName, QString searchString) const override;
aap_protobuf::service::media::sink::message::VideoFrameRateType getVideoFPS() const override;
void setVideoFPS(aap_protobuf::service::media::sink::message::VideoFrameRateType value) override;
aap_protobuf::service::media::sink::message::VideoCodecResolutionType getVideoResolution() const override;
void setVideoResolution(aap_protobuf::service::media::sink::message::VideoCodecResolutionType value) override;
size_t getScreenDPI() const override;
void setScreenDPI(size_t value) override;
void setOMXLayerIndex(int32_t value) override;
@ -57,46 +102,97 @@ public:
bool getTouchscreenEnabled() const override;
void setTouchscreenEnabled(bool value) override;
bool playerButtonControl() const override;
void playerButtonControl(bool value) override;
ButtonCodes getButtonCodes() const override;
void setButtonCodes(const ButtonCodes& value) override;
BluetoothAdapterType getBluetoothAdapterType() const override;
void setBluetoothAdapterType(BluetoothAdapterType value) override;
std::string getBluetoothRemoteAdapterAddress() const override;
void setBluetoothRemoteAdapterAddress(const std::string& value) override;
std::string getBluetoothAdapterAddress() const override;
void setBluetoothAdapterAddress(const std::string& value) override;
bool getWirelessProjectionEnabled() const override;
void setWirelessProjectionEnabled(bool value) override;
bool musicAudioChannelEnabled() const override;
void setMusicAudioChannelEnabled(bool value) override;
bool speechAudioChannelEnabled() const override;
void setSpeechAudioChannelEnabled(bool value) override;
bool guidanceAudioChannelEnabled() const override;
void setGuidanceAudioChannelEnabled(bool value) override;
bool systemAudioChannelEnabled() const override;
void setSystemAudioChannelEnabled(bool value) override;
bool telephonyAudioChannelEnabled() const override;
void setTelephonyAudioChannelEnabled(bool value) override;
AudioOutputBackendType getAudioOutputBackendType() const override;
void setAudioOutputBackendType(AudioOutputBackendType value) override;
private:
void readButtonCodes(boost::property_tree::ptree& iniConfig);
void insertButtonCode(boost::property_tree::ptree& iniConfig, const std::string& buttonCodeKey, aasdk::proto::enums::ButtonCode::Enum buttonCode);
void insertButtonCode(boost::property_tree::ptree& iniConfig, const std::string& buttonCodeKey, aap_protobuf::service::media::sink::message::KeyCode buttonCode);
void writeButtonCodes(boost::property_tree::ptree& iniConfig);
HandednessOfTrafficType handednessOfTrafficType_;
bool showClock_;
aasdk::proto::enums::VideoFPS::Enum videoFPS_;
aasdk::proto::enums::VideoResolution::Enum videoResolution_;
bool showBigClock_;
bool oldGUI_;
size_t alphaTrans_;
bool hideMenuToggle_;
bool hideAlpha_;
bool showLux_;
bool showCursor_;
bool hideBrightnessControl_;
bool showNetworkinfo_;
bool hideWarning_;
std::string mp3MasterPath_;
std::string mp3SubFolder_;
int32_t mp3Track_;
bool mp3AutoPlay_;
bool showAutoPlay_;
bool instantPlay_;
aap_protobuf::service::media::sink::message::VideoFrameRateType videoFPS_;
aap_protobuf::service::media::sink::message::VideoCodecResolutionType videoResolution_;
size_t screenDPI_;
int32_t omxLayerIndex_;
QRect videoMargins_;
bool enableTouchscreen_;
bool enablePlayerControl_;
ButtonCodes buttonCodes_;
BluetoothAdapterType bluetoothAdapterType_;
std::string bluetoothRemoteAdapterAddress_;
bool musicAudioChannelEnabled_;
bool speechAudiochannelEnabled_;
std::string bluetoothAdapterAddress_;
bool wirelessProjectionEnabled_;
bool _audioChannelEnabledMedia;
bool _audioChannelEnabledGuidance;
bool _audioChannelEnabledSystem;
bool _audioChannelEnabledTelephony;
AudioOutputBackendType audioOutputBackendType_;
static const std::string cConfigFileName;
static const std::string cGeneralShowClockKey;
static const std::string cGeneralShowBigClockKey;
static const std::string cGeneralOldGUIKey;
static const std::string cGeneralAlphaTransKey;
static const std::string cGeneralHideMenuToggleKey;
static const std::string cGeneralHideAlphaKey;
static const std::string cGeneralShowLuxKey;
static const std::string cGeneralShowCursorKey;
static const std::string cGeneralHideBrightnessControlKey;
static const std::string cGeneralShowNetworkinfoKey;
static const std::string cGeneralHideWarningKey;
static const std::string cGeneralHandednessOfTrafficTypeKey;
static const std::string cGeneralMp3MasterPathKey;
static const std::string cGeneralMp3SubFolderKey;
static const std::string cGeneralMp3TrackKey;
static const std::string cGeneralMp3AutoPlayKey;
static const std::string cGeneralShowAutoPlayKey;
static const std::string cGeneralInstantPlayKey;
static const std::string cVideoFPSKey;
static const std::string cVideoResolutionKey;
static const std::string cVideoScreenDPIKey;
@ -104,14 +200,19 @@ private:
static const std::string cVideoMarginWidth;
static const std::string cVideoMarginHeight;
static const std::string cAudioMusicAudioChannelEnabled;
static const std::string cAudioSpeechAudioChannelEnabled;
static const std::string cAudioChannelMediaEnabled;
static const std::string cAudioChannelGuidanceEnabled;
static const std::string cAudioChannelSystemEnabled;
static const std::string cAudioChannelTelephonyEnabled;
static const std::string cAudioOutputBackendType;
static const std::string cBluetoothAdapterTypeKey;
static const std::string cBluetoothRemoteAdapterAddressKey;
static const std::string cBluetoothAdapterAddressKey;
static const std::string cBluetoothWirelessProjectionEnabledKey;
static const std::string cInputEnableTouchscreenKey;
static const std::string cInputEnablePlayerControlKey;
static const std::string cInputPlayButtonKey;
static const std::string cInputPauseButtonKey;
static const std::string cInputTogglePlayButtonKey;
@ -128,6 +229,7 @@ private:
static const std::string cInputScrollWheelButtonKey;
static const std::string cInputBackButtonKey;
static const std::string cInputEnterButtonKey;
static const std::string cInputNavButtonKey;
};
}

View File

@ -20,10 +20,10 @@
#include <string>
#include <QRect>
#include <aasdk_proto/VideoFPSEnum.pb.h>
#include <aasdk_proto/VideoResolutionEnum.pb.h>
#include <aasdk_proto/ButtonCodeEnum.pb.h>
#include <f1x/openauto/autoapp/Configuration/BluetootAdapterType.hpp>
#include <aap_protobuf/service/media/sink/message/VideoFrameRateType.pb.h>
#include <aap_protobuf/service/media/sink/message/VideoCodecResolutionType.pb.h>
#include <aap_protobuf/service/media/sink/message/KeyCode.pb.h>
#include <f1x/openauto/autoapp/Configuration/BluetoothAdapterType.hpp>
#include <f1x/openauto/autoapp/Configuration/HandednessOfTrafficType.hpp>
#include <f1x/openauto/autoapp/Configuration/AudioOutputBackendType.hpp>
@ -40,7 +40,7 @@ class IConfiguration
{
public:
typedef std::shared_ptr<IConfiguration> Pointer;
typedef std::vector<aasdk::proto::enums::ButtonCode::Enum> ButtonCodes;
typedef std::vector<aap_protobuf::service::media::sink::message::KeyCode> ButtonCodes;
virtual ~IConfiguration() = default;
@ -48,15 +48,54 @@ public:
virtual void reset() = 0;
virtual void save() = 0;
virtual bool hasTouchScreen() const = 0;
virtual void setHandednessOfTrafficType(HandednessOfTrafficType value) = 0;
virtual HandednessOfTrafficType getHandednessOfTrafficType() const = 0;
virtual void showClock(bool value) = 0;
virtual bool showClock() const = 0;
virtual void showBigClock(bool value) = 0;
virtual bool showBigClock() const = 0;
virtual void oldGUI(bool value) = 0;
virtual bool oldGUI() const = 0;
virtual void setAlphaTrans(size_t value) = 0;
virtual size_t getAlphaTrans() const = 0;
virtual void hideMenuToggle(bool value) = 0;
virtual bool hideMenuToggle() const = 0;
virtual void hideAlpha(bool value) = 0;
virtual bool hideAlpha() const = 0;
virtual void showLux(bool value) = 0;
virtual bool showLux() const = 0;
virtual void showCursor(bool value) = 0;
virtual bool showCursor() const = 0;
virtual void hideBrightnessControl(bool value) = 0;
virtual bool hideBrightnessControl() const = 0;
virtual void showNetworkinfo(bool value) = 0;
virtual bool showNetworkinfo() const = 0;
virtual void hideWarning(bool value) = 0;
virtual bool hideWarning() const = 0;
virtual aasdk::proto::enums::VideoFPS::Enum getVideoFPS() const = 0;
virtual void setVideoFPS(aasdk::proto::enums::VideoFPS::Enum value) = 0;
virtual aasdk::proto::enums::VideoResolution::Enum getVideoResolution() const = 0;
virtual void setVideoResolution(aasdk::proto::enums::VideoResolution::Enum value) = 0;
virtual std::string getMp3MasterPath() const = 0;
virtual void setMp3MasterPath(const std::string& value) = 0;
virtual std::string getMp3SubFolder() const = 0;
virtual void setMp3SubFolder(const std::string& value) = 0;
virtual int32_t getMp3Track() const = 0;
virtual void setMp3Track(int32_t value) = 0;
virtual bool mp3AutoPlay() const = 0;
virtual void mp3AutoPlay(bool value) = 0;
virtual bool showAutoPlay() const = 0;
virtual void showAutoPlay(bool value) = 0;
virtual bool instantPlay() const = 0;
virtual void instantPlay(bool value) = 0;
virtual QString getCSValue(QString searchString) const = 0;
virtual QString readFileContent(QString fileName) const = 0;
virtual QString getParamFromFile(QString fileName, QString searchString) const = 0;
virtual aap_protobuf::service::media::sink::message::VideoFrameRateType getVideoFPS() const = 0;
virtual void setVideoFPS(aap_protobuf::service::media::sink::message::VideoFrameRateType value) = 0;
virtual aap_protobuf::service::media::sink::message::VideoCodecResolutionType getVideoResolution() const = 0;
virtual void setVideoResolution(aap_protobuf::service::media::sink::message::VideoCodecResolutionType value) = 0;
virtual size_t getScreenDPI() const = 0;
virtual void setScreenDPI(size_t value) = 0;
virtual void setOMXLayerIndex(int32_t value) = 0;
@ -66,18 +105,26 @@ public:
virtual bool getTouchscreenEnabled() const = 0;
virtual void setTouchscreenEnabled(bool value) = 0;
virtual bool playerButtonControl() const = 0;
virtual void playerButtonControl(bool value) = 0;
virtual ButtonCodes getButtonCodes() const = 0;
virtual void setButtonCodes(const ButtonCodes& value) = 0;
virtual BluetoothAdapterType getBluetoothAdapterType() const = 0;
virtual void setBluetoothAdapterType(BluetoothAdapterType value) = 0;
virtual std::string getBluetoothRemoteAdapterAddress() const = 0;
virtual void setBluetoothRemoteAdapterAddress(const std::string& value) = 0;
virtual std::string getBluetoothAdapterAddress() const = 0;
virtual void setBluetoothAdapterAddress(const std::string& value) = 0;
virtual bool getWirelessProjectionEnabled() const = 0;
virtual void setWirelessProjectionEnabled(bool value) = 0;
virtual bool musicAudioChannelEnabled() const = 0;
virtual void setMusicAudioChannelEnabled(bool value) = 0;
virtual bool speechAudioChannelEnabled() const = 0;
virtual void setSpeechAudioChannelEnabled(bool value) = 0;
virtual bool guidanceAudioChannelEnabled() const = 0;
virtual void setGuidanceAudioChannelEnabled(bool value) = 0;
virtual bool systemAudioChannelEnabled() const = 0;
virtual void setSystemAudioChannelEnabled(bool value) = 0;
virtual bool telephonyAudioChannelEnabled() const = 0;
virtual void setTelephonyAudioChannelEnabled(bool value) = 0;
virtual AudioOutputBackendType getAudioOutputBackendType() const = 0;
virtual void setAudioOutputBackendType(AudioOutputBackendType value) = 0;
};

View File

@ -34,8 +34,7 @@ class DummyBluetoothDevice: public IBluetoothDevice
public:
void stop() override;
bool isPaired(const std::string& address) const override;
void pair(const std::string& address, PairingPromise::Pointer promise) override;
std::string getLocalAddress() const override;
std::string getAdapterAddress() const override;
bool isAvailable() const override;
};

View File

@ -19,8 +19,8 @@
#pragma once
#include <memory>
#include <f1x/aasdk/IO/Promise.hpp>
#include <f1x/aasdk/Common/Data.hpp>
#include <aasdk/IO/Promise.hpp>
#include <aasdk/Common/Data.hpp>
namespace f1x
{

View File

@ -19,8 +19,8 @@
#pragma once
#include <memory>
#include <f1x/aasdk/Messenger/Timestamp.hpp>
#include <f1x/aasdk/Common/Data.hpp>
#include <aasdk/Messenger/Timestamp.hpp>
#include <aasdk/Common/Data.hpp>
namespace f1x
{

View File

@ -16,7 +16,7 @@
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#include <f1x/aasdk/IO/Promise.hpp>
#include <aasdk/IO/Promise.hpp>
#pragma once
@ -37,8 +37,7 @@ public:
virtual void stop() = 0;
virtual bool isPaired(const std::string& address) const = 0;
virtual void pair(const std::string& address, PairingPromise::Pointer promise) = 0;
virtual std::string getLocalAddress() const = 0;
virtual std::string getAdapterAddress() const = 0;
virtual bool isAvailable() const = 0;
};

View File

@ -19,7 +19,7 @@
#pragma once
#include <QRect>
#include <f1x/aasdk/IO/Promise.hpp>
#include <aasdk/IO/Promise.hpp>
#include <f1x/openauto/autoapp/Projection/InputEvent.hpp>
namespace f1x
@ -37,7 +37,7 @@ class IInputDevice
{
public:
typedef std::shared_ptr<IInputDevice> Pointer;
typedef std::vector<aasdk::proto::enums::ButtonCode::Enum> ButtonCodes;
typedef std::vector<aap_protobuf::service::media::sink::message::KeyCode> ButtonCodes;
virtual ~IInputDevice() = default;
virtual void start(IInputDeviceEventHandler& eventHandler) = 0;

View File

@ -20,9 +20,10 @@
#include <memory>
#include <QRect>
#include <aasdk_proto/VideoFPSEnum.pb.h>
#include <aasdk_proto/VideoResolutionEnum.pb.h>
#include <f1x/aasdk/Common/Data.hpp>
#include <aasdk/Common/Data.hpp>
#include <aasdk/Messenger/Timestamp.hpp>
#include <aap_protobuf/service/media/sink/message/VideoFrameRateType.pb.h>
#include <aap_protobuf/service/media/sink/message/VideoCodecResolutionType.pb.h>
namespace f1x
{
@ -43,12 +44,14 @@ public:
virtual bool open() = 0;
virtual bool init() = 0;
virtual void write(uint64_t timestamp, const aasdk::common::DataConstBuffer& buffer) = 0;
virtual void write(aasdk::messenger::Timestamp::ValueType timestamp, const aasdk::common::DataConstBuffer& buffer) = 0;
virtual void stop() = 0;
virtual aasdk::proto::enums::VideoFPS::Enum getVideoFPS() const = 0;
virtual aasdk::proto::enums::VideoResolution::Enum getVideoResolution() const = 0;
virtual aap_protobuf::service::media::sink::message::VideoFrameRateType getVideoFPS() const = 0;
virtual aap_protobuf::service::media::sink::message::VideoCodecResolutionType getVideoResolution() const = 0;
virtual size_t getScreenDPI() const = 0;
virtual QRect getVideoMargins() const = 0;
};
}

View File

@ -18,9 +18,9 @@
#pragma once
#include <aasdk_proto/ButtonCodeEnum.pb.h>
#include <aasdk_proto/TouchActionEnum.pb.h>
#include <f1x/aasdk/IO/Promise.hpp>
#include <aap_protobuf/service/media/sink/message/KeyCode.pb.h>
#include <aap_protobuf/service/inputsource/message/PointerAction.pb.h>
#include <aasdk/IO/Promise.hpp>
namespace f1x
{
@ -49,12 +49,12 @@ struct ButtonEvent
{
ButtonEventType type;
WheelDirection wheelDirection;
aasdk::proto::enums::ButtonCode::Enum code;
aap_protobuf::service::media::sink::message::KeyCode code;
};
struct TouchEvent
{
aasdk::proto::enums::TouchAction::Enum type;
aap_protobuf::service::inputsource::message::PointerAction type;
uint32_t x;
uint32_t y;
uint32_t pointerId;

View File

@ -18,16 +18,12 @@
#include <QBluetoothLocalDevice>
#include <f1x/openauto/autoapp/Projection/IBluetoothDevice.hpp>
#include <QBluetoothServiceInfo>
#include <QtBluetooth/QBluetoothServer>
#pragma once
namespace f1x
{
namespace openauto
{
namespace autoapp
{
namespace projection
namespace f1x::openauto::autoapp::projection
{
class LocalBluetoothDevice: public QObject, public IBluetoothDevice
@ -35,34 +31,27 @@ class LocalBluetoothDevice: public QObject, public IBluetoothDevice
Q_OBJECT
public:
LocalBluetoothDevice();
LocalBluetoothDevice(const QString &adapterAddress = QString(), QObject *parent = nullptr);
void stop() override;
bool isPaired(const std::string& address) const override;
void pair(const std::string& address, PairingPromise::Pointer promise) override;
std::string getLocalAddress() const override;
std::string getAdapterAddress() const override;
bool isAvailable() const override;
signals:
void startPairing(const QString& address, PairingPromise::Pointer promise);
private slots:
void createBluetoothLocalDevice();
void onStartPairing(const QString& address, PairingPromise::Pointer promise);
void onPairingDisplayConfirmation(const QBluetoothAddress &address, QString pin);
void onPairingDisplayPinCode(const QBluetoothAddress &address, QString pin);
void onPairingFinished(const QBluetoothAddress &address, QBluetoothLocalDevice::Pairing pairing);
void onError(QBluetoothLocalDevice::Error error);
void onHostModeStateChanged(QBluetoothLocalDevice::HostMode state);
void createBluetoothLocalDevice(const QString &adapterAddress);
private:
mutable std::mutex mutex_;
std::unique_ptr<QBluetoothLocalDevice> localDevice_;
PairingPromise::Pointer pairingPromise_;
QBluetoothAddress pairingAddress_;
QBluetoothServiceInfo serviceInfo_;
std::unique_ptr<QBluetoothServer> rfcommServer_;
};
}
}
}
}

View File

@ -60,7 +60,7 @@ protected slots:
private:
QAudioFormat audioFormat_;
SequentialBuffer audioBuffer_;
QIODevice * audioBuffer_;
std::unique_ptr<QAudioOutput> audioOutput_;
bool playbackStarted_;
};

View File

@ -21,7 +21,7 @@
#include <QIODevice>
#include <mutex>
#include <boost/circular_buffer.hpp>
#include <f1x/aasdk/Common/Data.hpp>
#include <aasdk/Common/Data.hpp>
namespace f1x
{

View File

@ -35,8 +35,8 @@ class VideoOutput: public IVideoOutput
public:
VideoOutput(configuration::IConfiguration::Pointer configuration);
aasdk::proto::enums::VideoFPS::Enum getVideoFPS() const override;
aasdk::proto::enums::VideoResolution::Enum getVideoResolution() const override;
aap_protobuf::service::media::sink::message::VideoFrameRateType getVideoFPS() const override;
aap_protobuf::service::media::sink::message::VideoCodecResolutionType getVideoResolution() const override;
size_t getScreenDPI() const override;
QRect getVideoMargins() const override;

View File

@ -19,14 +19,18 @@
#pragma once
#include <boost/asio.hpp>
#include <f1x/aasdk/Transport/ITransport.hpp>
#include <f1x/aasdk/Channel/Control/IControlServiceChannel.hpp>
#include <f1x/aasdk/Channel/Control/IControlServiceChannelEventHandler.hpp>
#include <f1x/aasdk/Channel/AV/VideoServiceChannel.hpp>
#include <aasdk/Transport/ITransport.hpp>
#include <aasdk/Channel/Control/IControlServiceChannel.hpp>
#include <aasdk/Channel/Control/IControlServiceChannelEventHandler.hpp>
#include <aasdk/Channel/MediaSink/Video/Channel/VideoChannel.hpp>
#include <f1x/openauto/autoapp/Configuration/IConfiguration.hpp>
#include <f1x/openauto/autoapp/Service/IAndroidAutoEntity.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
#include <f1x/openauto/autoapp/Service/IPinger.hpp>
#include <Transport/ITransport.hpp>
#include <aap_protobuf/service/control/message/AudioFocusRequestType.pb.h>
#include <aap_protobuf/service/control/message/AudioFocusStateType.pb.h>
#include <aap_protobuf/service/control/message/NavFocusType.pb.h>
namespace f1x
{
@ -51,14 +55,20 @@ public:
void start(IAndroidAutoEntityEventHandler& eventHandler) override;
void stop() override;
void onVersionResponse(uint16_t majorCode, uint16_t minorCode, aasdk::proto::enums::VersionResponseStatus::Enum status) override;
void pause() override;
void resume() override;
// TODO: on channel open request... on channel close... on navigation focus, on voice session notification, on user switch, on call availability, on service disc update, on battery status, on car connected devices
void onVersionResponse(uint16_t majorCode, uint16_t minorCode, aap_protobuf::shared::MessageStatus status) override;
void onHandshake(const aasdk::common::DataConstBuffer& payload) override;
void onServiceDiscoveryRequest(const aasdk::proto::messages::ServiceDiscoveryRequest& request) override;
void onAudioFocusRequest(const aasdk::proto::messages::AudioFocusRequest& request) override;
void onShutdownRequest(const aasdk::proto::messages::ShutdownRequest& request) override;
void onShutdownResponse(const aasdk::proto::messages::ShutdownResponse& response) override;
void onNavigationFocusRequest(const aasdk::proto::messages::NavigationFocusRequest& request) override;
void onPingResponse(const aasdk::proto::messages::PingResponse& response) override;
void onServiceDiscoveryRequest(const aap_protobuf::service::control::message::ServiceDiscoveryRequest& request) override;
void onAudioFocusRequest(const aap_protobuf::service::control::message::AudioFocusRequest& request) override;
void onByeByeRequest(const aap_protobuf::service::control::message::ByeByeRequest& request) override;
void onByeByeResponse(const aap_protobuf::service::control::message::ByeByeResponse& response) override;
void onNavigationFocusRequest(const aap_protobuf::service::control::message::NavFocusRequestNotification& request) override;
void onVoiceSessionRequest(const aap_protobuf::service::control::message::VoiceSessionNotification &request) override;
void onBatteryStatusNotification(const aap_protobuf::service::control::message::BatteryStatusNotification &notification) override;
void onPingResponse(const aap_protobuf::service::control::message::PingResponse& response) override;
void onPingRequest(const aap_protobuf::service::control::message::PingRequest& request) override;
void onChannelError(const aasdk::error::Error& e) override;
private:

View File

@ -19,7 +19,7 @@
#pragma once
#include <boost/asio.hpp>
#include <f1x/aasdk/Transport/ITransport.hpp>
#include <aasdk/Transport/ITransport.hpp>
#include <f1x/openauto/autoapp/Configuration/IConfiguration.hpp>
#include <f1x/openauto/autoapp/Service/IAndroidAutoEntityFactory.hpp>
#include <f1x/openauto/autoapp/Service/IServiceFactory.hpp>

View File

@ -1,65 +0,0 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <f1x/aasdk/Channel/AV/AVInputServiceChannel.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
#include <f1x/openauto/autoapp/Projection/IAudioInput.hpp>
namespace f1x
{
namespace openauto
{
namespace autoapp
{
namespace service
{
class AudioInputService: public aasdk::channel::av::IAVInputServiceChannelEventHandler, public IService, public std::enable_shared_from_this<AudioInputService>
{
public:
typedef std::shared_ptr<AudioInputService> Pointer;
AudioInputService(boost::asio::io_service& ioService, aasdk::messenger::IMessenger::Pointer messenger, projection::IAudioInput::Pointer audioInput);
void start() override;
void stop() override;
void fillFeatures(aasdk::proto::messages::ServiceDiscoveryResponse& response) override;
void onChannelOpenRequest(const aasdk::proto::messages::ChannelOpenRequest& request) override;
void onAVChannelSetupRequest(const aasdk::proto::messages::AVChannelSetupRequest& request) override;
void onAVInputOpenRequest(const aasdk::proto::messages::AVInputOpenRequest& request) override;
void onAVMediaAckIndication(const aasdk::proto::messages::AVMediaAckIndication& indication) override;
void onChannelError(const aasdk::error::Error& e) override;
private:
using std::enable_shared_from_this<AudioInputService>::shared_from_this;
void onAudioInputOpenSucceed();
void onAudioInputDataReady(aasdk::common::Data data);
void readAudioInput();
boost::asio::io_service::strand strand_;
aasdk::channel::av::AVInputServiceChannel::Pointer channel_;
projection::IAudioInput::Pointer audioInput_;
int32_t session_;
};
}
}
}
}

View File

@ -1,65 +0,0 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <f1x/aasdk/Channel/AV/IAudioServiceChannel.hpp>
#include <f1x/aasdk/Channel/AV/IAudioServiceChannelEventHandler.hpp>
#include <f1x/openauto/autoapp/Projection/IAudioOutput.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
namespace f1x
{
namespace openauto
{
namespace autoapp
{
namespace service
{
class AudioService: public aasdk::channel::av::IAudioServiceChannelEventHandler, public IService, public std::enable_shared_from_this<AudioService>
{
public:
typedef std::shared_ptr<AudioService> Pointer;
AudioService(boost::asio::io_service& ioService, aasdk::channel::av::IAudioServiceChannel::Pointer channel, projection::IAudioOutput::Pointer audioOutput);
void start() override;
void stop() override;
void fillFeatures(aasdk::proto::messages::ServiceDiscoveryResponse& response) override;
void onChannelOpenRequest(const aasdk::proto::messages::ChannelOpenRequest& request) override;
void onAVChannelSetupRequest(const aasdk::proto::messages::AVChannelSetupRequest& request) override;
void onAVChannelStartIndication(const aasdk::proto::messages::AVChannelStartIndication& indication) override;
void onAVChannelStopIndication(const aasdk::proto::messages::AVChannelStopIndication& indication) override;
void onAVMediaWithTimestampIndication(aasdk::messenger::Timestamp::ValueType timestamp, const aasdk::common::DataConstBuffer& buffer) override;
void onAVMediaIndication(const aasdk::common::DataConstBuffer& buffer) override;
void onChannelError(const aasdk::error::Error& e) override;
protected:
using std::enable_shared_from_this<AudioService>::shared_from_this;
boost::asio::io_service::strand strand_;
aasdk::channel::av::IAudioServiceChannel::Pointer channel_;
projection::IAudioOutput::Pointer audioOutput_;
int32_t session_;
};
}
}
}
}

View File

@ -0,0 +1,70 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <aasdk/Channel/Bluetooth/BluetoothService.hpp>
#include <f1x/openauto/autoapp/Projection/IBluetoothDevice.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
namespace f1x {
namespace openauto {
namespace autoapp {
namespace service {
namespace bluetooth {
class BluetoothService
: public aasdk::channel::bluetooth::IBluetoothServiceEventHandler,
public IService,
public std::enable_shared_from_this<BluetoothService> {
public:
BluetoothService(boost::asio::io_service &ioService,
aasdk::messenger::IMessenger::Pointer messenger,
projection::IBluetoothDevice::Pointer bluetoothDevice);
void start() override;
void stop() override;
void pause() override;
void resume() override;
void fillFeatures(aap_protobuf::service::control::message::ServiceDiscoveryResponse &response) override;
void onChannelOpenRequest(const aap_protobuf::service::control::message::ChannelOpenRequest &request) override;
void onBluetoothPairingRequest(
const aap_protobuf::service::bluetooth::message::BluetoothPairingRequest &request) override;
void onBluetoothAuthenticationResult(const aap_protobuf::service::bluetooth::message::BluetoothAuthenticationResult &request) override;
void onChannelError(const aasdk::error::Error &e) override;
private:
using std::enable_shared_from_this<BluetoothService>::shared_from_this;
void sendBluetoothAuthenticationData();
boost::asio::io_service::strand strand_;
aasdk::channel::bluetooth::BluetoothService::Pointer channel_;
projection::IBluetoothDevice::Pointer bluetoothDevice_;
};
}
}
}
}
}

View File

@ -1,56 +0,0 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <f1x/aasdk/Channel/Bluetooth/BluetoothServiceChannel.hpp>
#include <f1x/openauto/autoapp/Projection/IBluetoothDevice.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
namespace f1x
{
namespace openauto
{
namespace autoapp
{
namespace service
{
class BluetoothService: public aasdk::channel::bluetooth::IBluetoothServiceChannelEventHandler, public IService, public std::enable_shared_from_this<BluetoothService>
{
public:
BluetoothService(boost::asio::io_service& ioService, aasdk::messenger::IMessenger::Pointer messenger, projection::IBluetoothDevice::Pointer bluetoothDevice);
void start() override;
void stop() override;
void fillFeatures(aasdk::proto::messages::ServiceDiscoveryResponse& response) override;
void onChannelOpenRequest(const aasdk::proto::messages::ChannelOpenRequest& request) override;
void onBluetoothPairingRequest(const aasdk::proto::messages::BluetoothPairingRequest& request) override;
void onChannelError(const aasdk::error::Error& e) override;
private:
using std::enable_shared_from_this<BluetoothService>::shared_from_this;
boost::asio::io_service::strand strand_;
aasdk::channel::bluetooth::BluetoothServiceChannel::Pointer channel_;
projection::IBluetoothDevice::Pointer bluetoothDevice_;
};
}
}
}
}

View File

@ -0,0 +1,61 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <aasdk/Channel/GenericNotification/GenericNotificationService.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
#include <boost/asio/io_service.hpp>
#include <aasdk/Messenger/IMessenger.hpp>
namespace f1x {
namespace openauto {
namespace autoapp {
namespace service {
namespace genericnotification {
class GenericNotificationService :
public aasdk::channel::genericnotification::IGenericNotificationServiceEventHandler,
public IService,
public std::enable_shared_from_this<GenericNotificationService> {
public:
GenericNotificationService(boost::asio::io_service &ioService, aasdk::messenger::IMessenger::Pointer messenger);
void start() override;
void stop() override;
void pause() override;
void resume() override;
void fillFeatures(aap_protobuf::service::control::message::ServiceDiscoveryResponse &response) override;
void onChannelOpenRequest(const aap_protobuf::service::control::message::ChannelOpenRequest &request) override;
void onChannelError(const aasdk::error::Error &e) override;
private:
using std::enable_shared_from_this<GenericNotificationService>::shared_from_this;
boost::asio::deadline_timer timer_;
boost::asio::io_service::strand strand_;
aasdk::channel::genericnotification::GenericNotificationService::Pointer channel_;
};
}
}
}
}
}

View File

@ -39,6 +39,8 @@ public:
virtual void start(IAndroidAutoEntityEventHandler& eventHandler) = 0;
virtual void stop() = 0;
virtual void pause() = 0;
virtual void resume() = 0;
};
}

View File

@ -18,7 +18,7 @@
#pragma once
#include <f1x/aasdk/Error/Error.hpp>
#include <aasdk/Error/Error.hpp>
namespace f1x
{

View File

@ -18,8 +18,8 @@
#pragma once
#include <f1x/aasdk/TCP/ITCPEndpoint.hpp>
#include <f1x/aasdk/USB/IAOAPDevice.hpp>
#include <aasdk/TCP/ITCPEndpoint.hpp>
#include <aasdk/USB/IAOAPDevice.hpp>
#include <f1x/openauto/autoapp/Service/IAndroidAutoEntity.hpp>
namespace f1x

View File

@ -18,7 +18,7 @@
#pragma once
#include <f1x/aasdk/IO/Promise.hpp>
#include <aasdk/IO/Promise.hpp>
namespace f1x
{

View File

@ -20,32 +20,33 @@
#include <vector>
#include <memory>
#include <aasdk_proto/ServiceDiscoveryResponseMessage.pb.h>
#include <f1x/openauto/Common/Log.hpp>
#include <aap_protobuf/service/control/message/ServiceDiscoveryResponse.pb.h>
#include <aap_protobuf/shared/MessageStatus.pb.h>
namespace f1x
{
namespace openauto
{
namespace autoapp
{
namespace service
{
class IService
{
namespace f1x::openauto::autoapp::service {
class IService {
public:
typedef std::shared_ptr<IService> Pointer;
virtual ~IService() = default;
virtual void start() = 0;
virtual void stop() = 0;
virtual void fillFeatures(aasdk::proto::messages::ServiceDiscoveryResponse& response) = 0;
virtual void pause() = 0;
virtual void resume() = 0;
virtual void fillFeatures(aap_protobuf::service::control::message::ServiceDiscoveryResponse &response) = 0;
};
typedef std::vector<IService::Pointer> ServiceList;
}
}
}
}

View File

@ -18,7 +18,7 @@
#pragma once
#include <f1x/aasdk/Messenger/IMessenger.hpp>
#include <aasdk/Messenger/IMessenger.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
namespace f1x

View File

@ -1,65 +0,0 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <aasdk_proto/ButtonCodeEnum.pb.h>
#include <f1x/aasdk/Channel/Input/InputServiceChannel.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
#include <f1x/openauto/autoapp/Projection/IInputDevice.hpp>
#include <f1x/openauto/autoapp/Projection/IInputDeviceEventHandler.hpp>
namespace f1x
{
namespace openauto
{
namespace autoapp
{
namespace service
{
class InputService:
public aasdk::channel::input::IInputServiceChannelEventHandler,
public IService,
public projection::IInputDeviceEventHandler,
public std::enable_shared_from_this<InputService>
{
public:
InputService(boost::asio::io_service& ioService, aasdk::messenger::IMessenger::Pointer messenger, projection::IInputDevice::Pointer inputDevice);
void start() override;
void stop() override;
void fillFeatures(aasdk::proto::messages::ServiceDiscoveryResponse& response) override;
void onChannelOpenRequest(const aasdk::proto::messages::ChannelOpenRequest& request) override;
void onBindingRequest(const aasdk::proto::messages::BindingRequest& request) override;
void onChannelError(const aasdk::error::Error& e) override;
void onButtonEvent(const projection::ButtonEvent& event) override;
void onTouchEvent(const projection::TouchEvent& event) override;
private:
using std::enable_shared_from_this<InputService>::shared_from_this;
boost::asio::io_service::strand strand_;
aasdk::channel::input::InputServiceChannel::Pointer channel_;
projection::IInputDevice::Pointer inputDevice_;
};
}
}
}
}

View File

@ -0,0 +1,71 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <aap_protobuf/service/media/sink/message/KeyCode.pb.h>
#include <aasdk/Channel/InputSource/InputSourceService.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
#include <f1x/openauto/autoapp/Projection/IInputDevice.hpp>
#include <f1x/openauto/autoapp/Projection/IInputDeviceEventHandler.hpp>
namespace f1x {
namespace openauto {
namespace autoapp {
namespace service {
namespace inputsource {
class InputSourceService :
public aasdk::channel::inputsource::IInputSourceServiceEventHandler,
public IService,
public projection::IInputDeviceEventHandler,
public std::enable_shared_from_this<InputSourceService> {
public:
InputSourceService(boost::asio::io_service &ioService, aasdk::messenger::IMessenger::Pointer messenger,
projection::IInputDevice::Pointer inputDevice);
void start() override;
void stop() override;
void pause() override;
void resume() override;
void fillFeatures(aap_protobuf::service::control::message::ServiceDiscoveryResponse &response) override;
void onChannelOpenRequest(const aap_protobuf::service::control::message::ChannelOpenRequest &request) override;
void onKeyBindingRequest(const aap_protobuf::service::media::sink::message::KeyBindingRequest &request) override;
void onChannelError(const aasdk::error::Error &e) override;
void onButtonEvent(const projection::ButtonEvent &event) override;
void onTouchEvent(const projection::TouchEvent &event) override;
private:
using std::enable_shared_from_this<InputSourceService>::shared_from_this;
boost::asio::io_service::strand strand_;
aasdk::channel::inputsource::InputSourceService::Pointer channel_;
projection::IInputDevice::Pointer inputDevice_;
};
}
}
}
}
}

View File

@ -0,0 +1,61 @@
/*
* This file is part of openauto project.
* Copyright (C) 2018 f1x.studio (Michal Szwaj)
*
* openauto is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
* openauto is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with openauto. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#include <aasdk/Channel/MediaBrowser/MediaBrowserService.hpp>
#include <f1x/openauto/autoapp/Service/IService.hpp>
#include <boost/asio/io_service.hpp>
#include <aasdk/Messenger/IMessenger.hpp>
namespace f1x {
namespace openauto {
namespace autoapp {
namespace service {
namespace mediabrowser {
class MediaBrowserService :
public aasdk::channel::mediabrowser::IMediaBrowserServiceEventHandler,
public IService,
public std::enable_shared_from_this<MediaBrowserService> {
public:
MediaBrowserService(boost::asio::io_service &ioService, aasdk::messenger::IMessenger::Pointer messenger);
void start() override;
void stop() override;
void pause() override;
void resume() override;
void fillFeatures(aap_protobuf::service::control::message::ServiceDiscoveryResponse &response) override;
void onChannelOpenRequest(const aap_protobuf::service::control::message::ChannelOpenRequest &request) override;
void onChannelError(const aasdk::error::Error &e) override;
private:
using std::enable_shared_from_this<MediaBrowserService>::shared_from_this;
boost::asio::deadline_timer timer_;
boost::asio::io_service::strand strand_;
aasdk::channel::mediabrowser::MediaBrowserService::Pointer channel_;
};
}
}
}
}
}

Some files were not shown because too many files have changed in this diff Show More