Stap 5: CODES voor toepassing
Het APK bestand is hier toegevoegd. U kunt gewoon downloaden op uw Androïde apparaat en probeer het.
Of het originele bestand door Iann (http://forum.rfduino.com/index.php?topic=44.0) handmatig wijzigen. In dat geval:
Zoeken in de MainActivity.java voor het volgende stukje code en voeg de regel dat vet wordt gemaakt:
private void addData (bytegegevens []) {}
Weergave = getLayoutInflater () .inflate (android. R.layout.simple_list_item_2, dataLayout, false);
TextView text1 = (TextView) view.findViewById (android. R.id.text1); Text1.SetText(HexAsciiHelper.bytesToHex(Data));
rfduinoService.send(data);
String van ascii = HexAsciiHelper.bytesToAsciiMaybe(data);
Als (ascii! = null) {}
TextView text2 = (TextView) view.findViewById (android. R.id.text2);
text2.SetText(ASCII);
}
dataLayout.addView)
weergave, LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT);
}