Index: DCWoRMS/trunk/src/schedframe/resources/computing/ComputingResource.java
===================================================================
--- DCWoRMS/trunk/src/schedframe/resources/computing/ComputingResource.java	(revision 495)
+++ DCWoRMS/trunk/src/schedframe/resources/computing/ComputingResource.java	(revision 512)
@@ -46,4 +46,5 @@
 	protected String name;
 	protected ResourceType type;
+	protected String category;
 	protected ResourceStatus status;
 
@@ -63,4 +64,5 @@
 		this.type = resDesc.getType();
 		this.name = resDesc.getId();
+		this.category = resDesc.getCategory();
 		this.status = ResourceStatus.FREE;
 		this.extensionList = new ExtensionListImpl(1);
@@ -230,4 +232,8 @@
 	}
 	
+	public String getCategory(){
+		return category;
+	}
+	
 	public PowerInterface getPowerInterface(){
 		if (extensionList != null) {
@@ -297,11 +303,10 @@
 	public void initiate(){
 		
-		ResourceEventCommand rec = new ResourceEventCommand(this);
+		/*ResourceEventCommand rec = new ResourceEventCommand(this);
 		EnergyEvent event = new EnergyEvent(EnergyEventType.AIRFLOW_STATE_CHANGED, "Resource controller");
 		event.setReason(EventReason.SIM_INIT);
-		rec.execute(event);
-		
-		rec = new ResourceEventCommand(this);
-		event = new EnergyEvent(EnergyEventType.POWER_STATE_CHANGED, "Resource controller");
+		rec.execute(event);*/
+		ResourceEventCommand rec = new ResourceEventCommand(this);
+		EnergyEvent event = new EnergyEvent(EnergyEventType.POWER_STATE_CHANGED, "Resource controller");
 		event.setReason(EventReason.SIM_INIT);
 		rec.execute(event);
Index: DCWoRMS/trunk/src/schedframe/resources/computing/description/ComputingResourceDescription.java
===================================================================
--- DCWoRMS/trunk/src/schedframe/resources/computing/description/ComputingResourceDescription.java	(revision 477)
+++ DCWoRMS/trunk/src/schedframe/resources/computing/description/ComputingResourceDescription.java	(revision 512)
@@ -33,4 +33,5 @@
 	protected AirThroughputProfile airThroughputProfile;
 	protected Location location;
+	protected String category;
 	//protected Parameters parameters;
 
@@ -40,4 +41,5 @@
 
 		initId(computingResource);
+		this.category = computingResource.getType();
 
 		if (computingResource.getComputingResourceTypeChoiceSequence() != null) {
@@ -263,5 +265,7 @@
 	}
 
-
+	public String getCategory() {
+		return category;
+	}
 
 }
Index: DCWoRMS/trunk/src/schedframe/resources/computing/profiles/energy/power/PowerProfile.java
===================================================================
--- DCWoRMS/trunk/src/schedframe/resources/computing/profiles/energy/power/PowerProfile.java	(revision 495)
+++ DCWoRMS/trunk/src/schedframe/resources/computing/profiles/energy/power/PowerProfile.java	(revision 512)
@@ -66,7 +66,7 @@
 	}
 	
-	public Map<String, PState> getSupportedPStates() throws NoSuchFieldException {
+	public Map<String, PState> getSupportedPStates() {
 		if(supportedPStates == null)
-			throw new NoSuchFieldException("Supported p-states are not defined.");
+			return new HashMap<String, PState>();
 		return supportedPStates;
 	}
Index: DCWoRMS/trunk/src/schedframe/resources/computing/profiles/energy/power/ui/ProcessorPowerInterface.java
===================================================================
--- DCWoRMS/trunk/src/schedframe/resources/computing/profiles/energy/power/ui/ProcessorPowerInterface.java	(revision 506)
+++ DCWoRMS/trunk/src/schedframe/resources/computing/profiles/energy/power/ui/ProcessorPowerInterface.java	(revision 512)
@@ -1,7 +1,4 @@
 package schedframe.resources.computing.profiles.energy.power.ui;
 
-
-import gridsim.GridSimTags;
-import gridsim.dcworms.DCWormsTags;
 
 import java.util.Map;
@@ -15,6 +12,4 @@
 import schedframe.resources.computing.profiles.energy.power.PowerStateName;
 import schedframe.resources.computing.profiles.energy.power.StandardPowerStateName;
-import schedframe.resources.units.CpuSpeed;
-import schedframe.resources.units.StandardResourceUnitName;
 
 public class ProcessorPowerInterface extends ComputingResourcePowerInterface {
@@ -26,9 +21,5 @@
 		super(resource, pp);
 		currentPowerState = StandardPowerStateName.ON;
-		try {
-			currentPState = getSupportedPStates().get("P0");
-		} catch (NoSuchFieldException e) {
-			currentPState = null;
-		}
+		currentPState = getSupportedPStates().get("P0");
 	}
 	
@@ -53,17 +44,14 @@
 	}
 	
-	public Map<String, PState> getSupportedPStates() throws NoSuchFieldException {
+	public Map<String, PState> getSupportedPStates() {
 		return powerProfile.getSupportedPStates();
 	}
 	
 	public boolean supportPState(PState pState) {
-		try {
-			for(String pStateName: getSupportedPStates().keySet()){
-				if(pState.getName().equals(pStateName)){
-					return true;
-				}
+
+		for(String pStateName: getSupportedPStates().keySet()){
+			if(pState.getName().equals(pStateName)){
+				return true;
 			}
-		} catch (NoSuchFieldException e) {
-			return false;
 		}
 		return false;
@@ -71,12 +59,8 @@
 	
 	public boolean setPState(String pStateName){
-		PState newPState;
-		try {
-			newPState = getSupportedPStates().get(pStateName);
-		} catch (NoSuchFieldException e) {
-			return false;
-		}
+		PState newPState = getSupportedPStates().get(pStateName);
 
-		if(newPState != currentPState){
+
+		if(newPState != null && newPState != currentPState){
 			//double factor = newPState.getFrequency()/currentPState.getFrequency();
 			currentPState = newPState;
@@ -97,13 +81,10 @@
 
 	public boolean setFrequency(double freq) {
-		try {
-			for(String pStateName: getSupportedPStates().keySet()){
-				if(getSupportedPStates().get(pStateName).getFrequency() == freq){
-					setPState(pStateName);
-					return true;
-				}
+
+		for(String pStateName: getSupportedPStates().keySet()){
+			if(getSupportedPStates().get(pStateName).getFrequency() == freq){
+				setPState(pStateName);
+				return true;
 			}
-		} catch (NoSuchFieldException e) {
-			return false;
 		}
 		return false;
