Hi there, i've been working on an implementation of s-AES and having some issues with the subkeys and keys. Here is what I have thus far.

Code:
import java.math.BigInteger;
import java.util.*;

public class AESTest {

	private static Scanner console;
	
	public static void main (String args[]) {
		System.out.println("This program accepts a plaintext and key as inputs, " +
			"and uses s-AES to encrypt and decrypt your plaintext!");
		System.out.println("Please press 1 if you wish to enter your inputs in binary or 2 " +
				"if you would prefer to enter them as whole numbers: ");
		try {
		console = new Scanner(System.in);
		int choice = console.nextInt();
		
		// S-Box
		int sBox[] = {0x9, 0x4, 0xa, 0xb, 0xd, 0x1, 0x8, 0x5,
		         0x6, 0x2, 0x0, 0x3, 0xc, 0xe, 0xf, 0x7};
		 
		// Inverse S-Box
		int sBoxI[] = {0xa, 0x5, 0x9, 0xb, 0x1, 0x7, 0x8, 0xf,
		         0x6, 0x0, 0x2, 0x3, 0xc, 0x4, 0xd, 0xe};
		
		String key0 = null;
		String plaintext = null;
		
		if (choice == 1) {
			plaintext = binaryPlaintext();
			key0 = binaryKey();
		} else if (choice == 2) {
			plaintext = binarizePlaintext();
			key0 = binarizeKey();
		} else {
			System.out.println("Incorrect option");
		}
	
		System.out.println("The plaintext you have entered is: " + plaintext);
		System.out.println("The key that you entered is: " + key0);
			
		//keyExpansion(key0);
	
	
		} catch (java.util.InputMismatchException ex) {
			System.out.println("Incorrect input, please try again!");
		}
	
	}	//end of main
		
	public static int sBox(int[] sBox) {
		int b = 0;
		return sBox[b >> 4] + (sBox[b & 0x0f] << 4);
	}
	
	public static int keyExp(String key0) {
		
		int Rcon1 = 0b10000000;
		int Rcon2 = 0b00110000;
		String w0 = (key0 + 0xff00) >> 8;
		String w1 = key0 + 0x00ff;
		String w2 = w0 ^ Rcon1 ^ sBox(w1);
		String w3 = w2 ^ w1;
		String w4 = w2 ^ Rcon2 ^ sBox(w3);
		String w5 = w4 ^ w3;
	}
	
	public static String binaryPlaintext() {
		System.out.println("Please enter the plaintext as a 16-bit binary number:");
		String binary = console.next();
		
		int nb;
		boolean check = true;
		try {
			nb = Integer.valueOf(binary, 2);
		} catch (NumberFormatException e) {
			check = false;
		}
		if((check) && (binary.length() == 16)) {
			} else {
				System.out.println("The number you entered is invalid");
				binaryPlaintext();
			}
		return binary;
	}
		
		
	
	public static String binarizePlaintext() {
		System.out.println("Please enter the plaintext as a whole number ");
		long plaintext1 = console.nextLong();
			
		String binarized = Integer.toBinaryString((int) plaintext1);
		int len = binarized.length();
		String sixteenZeroes = "00000000000000000";
		if (len < 16) {
			binarized = sixteenZeroes.substring(0, 16-len).concat(binarized);
		} else {
			binarized = binarized.substring(len - 16);
		}
		return binarized;
	}
	
	
	
	public static String binaryKey() {
		System.out.println("Please enter the key as a 16-bit binary number:");
		String binaryKey = console.next();
		
		int nb;
		boolean check = true;
		try {
			nb = Integer.valueOf(binaryKey, 2);
		} catch (NumberFormatException e) {
			check = false;
		}
		if((check) && (binaryKey.length() == 16)) {
			} else {
				System.out.println("The number you entered is invalid");
				binaryKey();
			}
		return binaryKey;
	}
		
		
	
	public static String binarizeKey() {
		System.out.println("Please enter the key as a whole number ");
		long key = console.nextLong();
			
		String binarizedKey = Integer.toBinaryString((int) key);
		int len = binarizedKey.length();
		String sixteenZeroes = "00000000000000000";
		if (len < 16) {
			binarizedKey = sixteenZeroes.substring(0, 16-len).concat(binarizedKey);
		} else {
			binarizedKey = binarizedKey.substring(len - 16);
		}
		return binarizedKey;
	}	
}
Now, the issue i'm having is splitting the subkeys up properly, and using those subkeys to calculate keys 0, 1, and 2.

More specifically, here is where my issue is

Code:
public static int sBox(int[] sBox) {
		int b = 0;
		return sBox[b >> 4] + (sBox[b & 0x0f] << 4);
	}
	
	public static int keyExp(String key0) {
		
		int Rcon1 = 0b10000000;
		int Rcon2 = 0b00110000;
		String w0 = (key0 + 0xff00) >> 8;
		String w1 = key0 + 0x00ff;
		String w2 = w0 ^ Rcon1 ^ sBox(w1);
		String w3 = w2 ^ w1;
		String w4 = w2 ^ Rcon2 ^ sBox(w3);
		String w5 = w4 ^ w3;
	}
i've made an s-box method which uses the sbox array, however i'm not sure the best way to get these subkeys (w0 - w5) to work properly.

Any help would be much appreciated. Thanks!!