Interesting that not saving (and restoring) values allowed the code to work. How are the values saved across invocations of the app? I haven't looked at the code yet, May be it will be shown there.The tutor mostly removed places where the code saved the GUI values.
wouldn't it be: 00011010? A different value from the 00110100?
what exactly does "& 0xFF" do?
He made several changes to the code. I tested that I can close and open the app two times and the values stick.
@rem Run adb
D:\AndroidDevelopment\adt-bundle-windows-x86_64-20140702\sdk\platform-tools\adb.exe devices
D:\AndroidDevelopment\adt-bundle-windows-x86_64-20140702\sdk\platform-tools\adb.exe logcat >> Nexus7Logcat.txt
MORE
It is rare that a program works early on. There is always something that you didn't think of. I think in 50 years of programming I have had 3 programs that I designed, coded, typed in the code, compiled and executed with the desired results the first time.I'm a little frustrated with not being able to get the code to work,
BLW onCreate() at 2025-01-30 T 10:19:26
BLW onCreate times=07:15, 10:00, 15:00, 15:30, 16:00, 16:30, 17:00, 17:30, 18:00, 21:45
BLW onCreate() intent=Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning bnds=[696,761][888,999] }
>>data=null
>>extras=null
savedInstanceState=null
BLW onResume at 2025-01-30 T 10:19:27
BLW button clicked runningAlarm=false, alarmPI=null at 2025-01-30 T 10:19:32
BLW Set the alarm for 60 seconds at 2025-01-30 T 10:19:32 alarm at Jan 30 10:20
BLW onPause() at 2025-01-30 T 10:19:34
onPause intent=Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning bnds=[696,761][888,999] }
BLW onDestroy at 2025-01-30 T 10:19:34
1 minute
BLW onCreate() at 2025-01-30 T 10:20:38
BLW onCreate times=07:15, 10:00, 15:00, 15:30, 16:00, 16:30, 17:00, 17:30, 18:00, 21:45
BLW onCreate() intent=Intent { flg=0x10000000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning (has extras) }
>>data=null
>>extras=Bundle[mParcelledData.dataSize=132]
savedInstanceState=null
>>bndl keySet=[timeOfAlarm, StartedBy]
BLW startedBy=OnAlarmReceive, timeOfAlarm=Jan 30 10:20 at 2025-01-30 T 10:20:38 <<<<<<<<<<<<< NOTE
Battery level=89
BLW Set the alarm for 60 seconds at 2025-01-30 T 10:20:38 alarm at Jan 30 10:21
??? 10 minutes later <<<<<<<<<<<<<< Manually opened
BLW onResume at 2025-01-30 T 10:30:24
BLW onPause() at 2025-01-30 T 10:30:24
onPause intent=Intent { flg=0x10000000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning (has extras) }
BLW onSaveInstanceState() at 2025-01-30 T 10:30:24
BLW onResume at 2025-01-30 T 10:30:24
BLW TTS onInit status=0
BLW runnable calling finish() at 2025-01-30 T 10:30:30
BLW onPause() at 2025-01-30 T 10:30:30
onPause intent=Intent { flg=0x10000000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning (has extras) }
BLW onDestroy at 2025-01-30 T 10:30:30
BLW onCreate() at 2025-01-30 T 10:30:33
BLW onCreate times=07:15, 10:00, 15:00, 15:30, 16:00, 16:30, 17:00, 17:30, 18:00, 21:45
BLW onCreate() intent=Intent { flg=0x10000000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning (has extras) }
>>data=null
>>extras=Bundle[mParcelledData.dataSize=132]
savedInstanceState=null
>>bndl keySet=[timeOfAlarm, StartedBy]
BLW startedBy=OnAlarmReceive, timeOfAlarm=Jan 30 10:21 at 2025-01-30 T 10:30:33 <<<<<<< NOTE timeOfAlarm is 9 minutes ago
Battery level=89
BLW Set the alarm for 60 seconds at 2025-01-30 T 10:30:34 alarm at Jan 30 10:31
BLW onResume at 2025-01-30 T 10:30:34
BLW TTS onInit status=0
BLW runnable calling finish() at 2025-01-30 T 10:30:40
BLW onPause() at 2025-01-30 T 10:30:40
onPause intent=Intent { flg=0x10000000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning (has extras) }
BLW onDestroy at 2025-01-30 T 10:30:40
BLW onCreate() at 2025-01-30 T 10:30:54
BLW onCreate times=07:15, 10:00, 15:00, 15:30, 16:00, 16:30, 17:00, 17:30, 18:00, 21:45
BLW onCreate() intent=Intent { flg=0x10000000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning (has extras) }
>>data=null
>>extras=Bundle[mParcelledData.dataSize=80]
savedInstanceState=null
>>bndl keySet=[Notify at]
BLW startedBy=null, timeOfAlarm=null at 2025-01-30 T 10:30:54
BLW onResume at 2025-01-30 T 10:30:54
BLW button clicked runningAlarm=true, alarmPI=null at 2025-01-30 T 10:30:55
BLW cancelled Alarm at 2025-01-30 T 10:30:55
BLW onPause() at 2025-01-30 T 10:30:58
onPause intent=Intent { flg=0x10000000 cmp=com.normsstuff.batterylevelwarning/.BatteryLevelWarning (has extras) }
BLW onDestroy at 2025-01-30 T 10:30:58
01/29/2025 09:07 AM 157 HelloWorld.java.txt
I can't start eclipse photon using jdk 17
jdk 17 (specified in eclipse .ini).