Add ByteBuilder, start work on parsing stored data

This commit is contained in:
Astatin3
2024-05-03 21:10:08 -06:00
parent bf64f8f6d1
commit 1321aad34c
33 changed files with 769 additions and 411 deletions
+13
View File
@@ -0,0 +1,13 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="800dp"
android:height="800dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M18,12V17C18,18.657 15.314,20 12,20C8.686,20 6,18.657 6,17V12M18,12V7M18,12C18,13.657 15.314,15 12,15C8.686,15 6,13.657 6,12M18,7C18,5.343 15.314,4 12,4C8.686,4 6,5.343 6,7M18,7C18,8.657 15.314,10 12,10C8.686,10 6,8.657 6,7M6,12V7"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:strokeLineCap="round"/>
</vector>
+13
View File
@@ -0,0 +1,13 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="800dp"
android:height="800dp"
android:viewportWidth="24"
android:viewportHeight="24">
<path
android:pathData="M7,14H12.5M7,10H17M10,19H6.2C5.08,19 4.52,19 4.092,18.782C3.716,18.59 3.41,18.284 3.218,17.908C3,17.48 3,16.92 3,15.8V8.2C3,7.08 3,6.52 3.218,6.092C3.41,5.716 3.716,5.41 4.092,5.218C4.52,5 5.08,5 6.2,5H17.8C18.92,5 19.48,5 19.908,5.218C20.284,5.41 20.59,5.716 20.782,6.092C21,6.52 21,7.08 21,8.2V8.5M14,20L16.025,19.595C16.201,19.56 16.29,19.542 16.372,19.51C16.445,19.481 16.515,19.444 16.579,19.399C16.652,19.348 16.715,19.285 16.843,19.157L21,15C21.552,14.448 21.552,13.552 21,13C20.448,12.448 19.552,12.448 19,13L14.843,17.157C14.715,17.285 14.652,17.348 14.601,17.421C14.556,17.485 14.519,17.555 14.49,17.628C14.458,17.71 14.44,17.799 14.405,17.975L14,20Z"
android:strokeLineJoin="round"
android:strokeWidth="2"
android:fillColor="#00000000"
android:strokeColor="#000000"
android:strokeLineCap="round"/>
</vector>
+12
View File
@@ -0,0 +1,12 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="800dp"
android:height="800dp"
android:viewportWidth="30"
android:viewportHeight="30">
<path
android:pathData="M27.52,21.134L26.528,22.866C26.254,23.345 25.648,23.508 25.173,23.232L22.418,21.628C21.02,23.219 19.129,24.359 16.983,24.799L16.983,27C16.983,27.553 16.54,28 15.992,28L14.008,28C13.46,28 13.017,27.553 13.017,27L13.017,24.799C10.871,24.359 8.98,23.219 7.582,21.628L4.827,23.232C4.352,23.508 3.746,23.345 3.472,22.866L2.48,21.134C2.206,20.656 2.369,20.044 2.843,19.769L5.609,18.157C5.28,17.163 5.083,16.106 5.083,15C5.083,13.894 5.28,12.838 5.609,11.843L2.843,10.232C2.369,9.956 2.206,9.345 2.48,8.866L3.472,7.134C3.746,6.656 4.352,6.492 4.827,6.768L7.582,8.372C8.98,6.781 10.871,5.641 13.017,5.201L13.017,3C13.017,2.447 13.46,2 14.008,2L15.992,2C16.54,2 16.983,2.447 16.983,3L16.983,5.201C19.129,5.641 21.02,6.781 22.418,8.372L25.173,6.768C25.648,6.492 26.254,6.656 26.528,7.134L27.52,8.866C27.794,9.345 27.631,9.956 27.157,10.232L24.391,11.843C24.72,12.838 24.917,13.894 24.917,15C24.917,16.106 24.72,17.163 24.391,18.157L27.157,19.769C27.631,20.044 27.794,20.656 27.52,21.134L27.52,21.134ZM29.008,18.536L26.685,17.184C26.815,16.474 26.901,15.749 26.901,15C26.901,14.252 26.815,13.526 26.685,12.816L29.008,11.464C29.957,10.912 30.281,9.688 29.733,8.732L27.75,5.268C27.203,4.312 25.989,3.983 25.041,4.536L22.694,5.901C21.598,4.961 20.352,4.192 18.967,3.697L18.967,2C18.967,0.896 18.079,0 16.983,0L13.017,0C11.921,0 11.033,0.896 11.033,2L11.033,3.697C9.648,4.192 8.402,4.961 7.306,5.901L4.959,4.536C4.011,3.983 2.797,4.312 2.25,5.268L0.267,8.732C-0.281,9.688 0.044,10.912 0.992,11.464L3.315,12.816C3.185,13.526 3.099,14.252 3.099,15C3.099,15.749 3.185,16.474 3.315,17.184L0.992,18.536C0.044,19.088 -0.281,20.312 0.267,21.268L2.25,24.732C2.797,25.688 4.011,26.017 4.959,25.464L7.306,24.099C8.402,25.039 9.648,25.809 11.033,26.303L11.033,28C11.033,29.104 11.921,30 13.017,30L16.983,30C18.079,30 18.967,29.104 18.967,28L18.967,26.303C20.352,25.809 21.598,25.039 22.694,24.099L25.041,25.464C25.989,26.017 27.203,25.688 27.75,24.732L29.733,21.268C30.281,20.312 29.957,19.088 29.008,18.536L29.008,18.536ZM15,18C13.357,18 12.025,16.657 12.025,15C12.025,13.344 13.357,12 15,12C16.643,12 17.975,13.344 17.975,15C17.975,16.657 16.643,18 15,18L15,18ZM15,10C12.261,10 10.042,12.238 10.042,15C10.042,17.762 12.261,20 15,20C17.739,20 19.959,17.762 19.959,15C19.959,12.238 17.739,10 15,10L15,10Z"
android:strokeWidth="1"
android:fillColor="#000000"
android:fillType="evenOdd"
android:strokeColor="#00000000"/>
</vector>
@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent">
</androidx.constraintlayout.widget.ConstraintLayout>
@@ -11,4 +11,10 @@
tools:context=".MainActivity">
<Spinner
android:id="@+id/eventDropdown"
android:layout_width="409dp"
android:layout_height="wrap_content"
tools:layout_editor_absoluteX="1dp"
tools:layout_editor_absoluteY="32dp" />
</androidx.constraintlayout.widget.ConstraintLayout>
@@ -4,7 +4,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".ui.TBA.TBAFragment">
tools:context=".ui.Settings.Settings">
<ScrollView
android:id="@+id/ScrollArea"
+11 -8
View File
@@ -10,6 +10,7 @@
android:id="@+id/selectLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="visible"
tools:visibility="gone">
<Button
@@ -137,7 +138,7 @@
android:visibility="gone"
app:layout_constraintTop_toBottomOf="parent"
tools:layout_editor_absoluteX="-62dp"
tools:visibility="visible">
tools:visibility="gone">
<SeekBar
@@ -145,25 +146,25 @@
android:layout_width="match_parent"
android:layout_height="48dp"
android:layout_marginTop="15dp"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"/>
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<SeekBar
android:id="@+id/scannerThreshold"
android:layout_width="match_parent"
android:layout_height="48dp"
app:layout_constraintTop_toBottomOf="@id/scannerColors"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"/>
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/scannerColors" />
<SeekBar
android:id="@+id/scannerBrightness"
android:layout_width="match_parent"
android:layout_height="48dp"
app:layout_constraintTop_toBottomOf="@id/scannerThreshold"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"/>
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/scannerThreshold" />
<TextView
android:id="@+id/scannerColorsLabel"
@@ -220,12 +221,14 @@
android:id="@+id/TBAView"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginBottom="60dp"
android:fillViewport="true"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:visibility="gone">
tools:visibility="visible">
<LinearLayout
android:layout_width="match_parent"
+11 -8
View File
@@ -2,16 +2,19 @@
<menu xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:id="@+id/navigation_home"
android:icon="@drawable/ic_home_black_24dp"
android:title="@string/title_home" />
android:id="@+id/navigation_scouting"
android:icon="@drawable/scouting"
android:title="@string/title_scouting" />
<item
android:id="@+id/navigation_notifications"
android:id="@+id/navigation_data"
android:icon="@drawable/data"
android:title="@string/title_data" />
<item
android:id="@+id/navigation_transfer"
android:icon="@drawable/transfer_icon"
android:title="@string/title_transfer" />
<item
android:id="@+id/navigation_tba"
android:icon="@drawable/ic_dashboard_black_24dp"
android:title="@string/title_tba" />
android:id="@+id/navigation_settings"
android:icon="@drawable/settings"
android:title="@string/title_settings" />
</menu>
@@ -3,40 +3,33 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/mobile_navigation"
app:startDestination="@+id/navigation_home">
app:startDestination="@+id/navigation_scouting">
<fragment
android:id="@+id/navigation_home"
android:name="com.astatin3.scoutingapp2025.ui.home.HomeFragment"
android:label="@string/title_home"
tools:layout="@layout/fragment_home" >
<action
android:id="@+id/action_navigation_home_to_navigation_tba"
app:destination="@id/navigation_tba" />
<action
android:id="@+id/action_navigation_home_to_navigation_notifications"
app:destination="@id/navigation_notifications" />
<action
android:id="@+id/action_navigation_home_to_navigation_dashboard2"
app:destination="@id/navigation_tba" />
android:id="@+id/navigation_scouting"
android:name="com.astatin3.scoutingapp2025.ui.scouting.scoutingFragment"
android:label="@string/title_scouting"
tools:layout="@layout/fragment_scouting" >
</fragment>
<fragment
android:id="@+id/navigation_tba"
android:name="com.astatin3.scoutingapp2025.ui.TBA.TBAFragment"
android:label="@string/title_tba"
tools:layout="@layout/fragment_tba" >
<action
android:id="@+id/action_navigation_dashboard_to_navigation_notifications"
app:destination="@id/navigation_notifications" />
<action
android:id="@+id/action_navigation_dashboard_to_navigation_home"
app:destination="@id/navigation_home" />
android:id="@+id/navigation_data"
android:name="com.astatin3.scoutingapp2025.ui.scouting.dataFragment"
android:label="@string/title_data"
tools:layout="@layout/fragment_data" >
</fragment>
<fragment
android:id="@+id/navigation_notifications"
android:id="@+id/navigation_settings"
android:name="com.astatin3.scoutingapp2025.ui.Settings.Settings"
android:label="@string/title_settings"
tools:layout="@layout/fragment_settings" >
</fragment>
<fragment
android:id="@+id/navigation_transfer"
android:name="com.astatin3.scoutingapp2025.ui.transfer.TransferFragment"
android:label="@string/title_transfer"
tools:layout="@layout/fragment_transfer" />
</navigation>
+3 -2
View File
@@ -1,6 +1,7 @@
<resources>
<string name="app_name">ScoutingApp2025</string>
<string name="title_home">Home</string>
<string name="title_scouting">Scouting</string>
<string name="title_data">Data</string>
<string name="title_transfer">Transfer</string>
<string name="title_tba">TBA</string>
<string name="title_settings">Settings</string>
</resources>