You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// TODO: Show a reverse button, but that's a lot of effort -- i'd have to change the UI too, which i hate doing, and handle other device's reverses too, and disconnect audio etc... so for now, just pause the audio and show the island without asking to reverse.
883
887
// handling reverse is a problem because we'd have to disconnect the audio, but there's no option connect audio again natively, so notification would have to be changed. I wish there was a way to just "change the audio output device".
// first 4 bytes AACP header, next two bytes opcode, next to bytes identifer
558
+
548
559
eqOnMedia = (packet[10] ==0x01.toByte())
549
560
eqOnPhone = (packet[11] ==0x01.toByte())
550
561
// there are 4 eqs. i am not sure what those are for, maybe all 4 listening modes, or maybe phone+media left+right, but then there shouldn't be another flag for phone/media enabled. just directly the EQ... weird.
@@ -554,7 +565,7 @@ class AACPManager {
554
565
val eq3 =ByteBuffer.wrap(packet, 76, 32).order(ByteOrder.LITTLE_ENDIAN).asFloatBuffer()
555
566
val eq4 =ByteBuffer.wrap(packet, 108, 32).order(ByteOrder.LITTLE_ENDIAN).asFloatBuffer()
556
567
557
-
// for now, just take the first EQ
568
+
// for now, taking just the first EQ
558
569
eqData =FloatArray(8) { i -> eq1.get(i) }
559
570
Log.d(TAG, "EQ Data set to: ${eqData.toList()}, eqOnPhone: $eqOnPhone, eqOnMedia: $eqOnMedia")
buffer.put(byteArrayOf(0x56)) // 'V', seems like a identifier or a separator
@@ -877,8 +886,8 @@ class AACPManager {
877
886
buffer.put(0x51) // 'Q'
878
887
buffer.put(selfMacAddress.toByteArray()) // self MAC
879
888
buffer.put("btName".toByteArray()) // self name
880
-
buffer.put(0x44) // 'D'
881
-
buffer.put("iPho".toByteArray()) // if set to iPad, shows "Moved to iPad, but most likely we're running on a phone. setting to anything else of the same length will show iPhone instead.
889
+
buffer.put(0x47) // 'D'
890
+
buffer.put("Android".toByteArray()) // if set to iPad, shows "Moved to iPad", but most likely we're running on a phone. setting to anything else of the same length will show iPhone instead.
0 commit comments