Arduino-Android LED styr med hjälp av Ethernet Shield (3 / 4 steg)
Steg 3: skriva din xml
< RelativeLayout xmlns:android = "http://schemas.android.com/apk/res/android"xmlns:tools = "http://schemas.android.com/tools"
Android: layout_width = "match_parent"
Android: layout_height = "match_parent"
Android: paddingBottom = "
Android: paddingLeft = "
Android: paddingRight = "
Android: paddingTop = "
verktyg: sammanhang = ". MainActivity">
< TextView
Android: id = "
Android: layout_width = "wrap_content"
Android: layout_height = "wrap_content"
Android: layout_gravity = "center"
Android: text = "Arduino enkel Automation"
Android: textAppearance = "? android: attr / textAppearanceLarge" / >
< LinearLayout
Android: id = "
Android: layout_width = "fill_parent"
Android: layout_height = "wrap_content"
Android: layout_alignLeft = "
Android: layout_below = "
Android: orientering = "horisontell" >
< knappen
Android: id = "
Android: layout_width = "100dp"
Android: layout_height = "100dp"
Android: layout_weight = "0,39"
Android: text = "LED 1 ON" / >
< knappen
Android: id = "
Android: layout_width = "100dp"
Android: layout_height = "100dp"
Android: layout_weight = "0,39"
Android: text = "LED 1 OFF" / >
< / LinearLayout >
< LinearLayout
Android: id = "
Android: layout_width = "fill_parent"
Android: layout_height = "wrap_content"
Android: layout_alignLeft = "
Android: layout_alignRight = "
Android: layout_below = "
Android: orientering = "horisontell" >
< knappen
Android: id = "
Android: layout_width = "100dp"
Android: layout_height = "100dp"
Android: layout_weight = "0,39"
Android: text = "LED 2 ON" / >
< knappen
Android: id = "
Android: layout_width = "100dp"
Android: layout_height = "100dp"
Android: layout_weight = "0,39"
Android: text = "LED 2 OFF" / >
< / LinearLayout >
< / RelativeLayout >