My previous blog's method works for "Windows Phone 7 7.10.7720" version. But the old versions doesn't have this feature. So I found another two more methods to find out the MAC address on windows phones.
Method 1 (works on "Windows Phone 7 7.10.7720" version on LG at&t)
1) Go to phone dialer.
2) Type ##634# and press "call" button.
3) In the MFG screen enter 277634#*# as password.
4) In "Factory menu" select "Engineer Menu"
5) In "Engineer Menu" select "Device Test"
6) From "Device Test" select "WIFI Test"
7) From "WIFI Test" open "Net.Info."
You will see the MAC address... ;)
For Samsung phones. [I didn't test this method]
1) Go to phone dialer.
2) Type ##634# (might have been ##643#) and press "call" button.
3) In the MFG screen enter 277634#*# as password.
4) Go to Diagnosis.
5) enter *#1234#
6) It should bring up a menu that includes the WiFi Mac Address
Method 2 [I didn't test this one. :P]
1) Enable your router logs.
2) Then enable your phone wi-fi.
3) Select the router from your phone's wifi list and let it to connect.
4) Check the DHCP CLIENT LOG of the router.
Hi friends. I'm Kumudu Saranath Liyanage. This is my personal blog. I put everything which i think that will important for me on another day. So it is no need to search same thing two times in the internet for any more...
Wednesday, March 21, 2012
How to find the MAC address on Windows phone.
Portable Wi-Fi hotspot.
This is another valuable reason to buy a Nexus S phone.. ;). The phone should connect to the network first and then can start its hotspot. [Model number : Nexus s, Android version : 2.3.6]. To connect to the network, set the APN (Access Point Names).
Menu -> Settings -> wireless network -> Mobite networks -> Access Point Names. Press Menu button. New APN.
I used a mobitel (Sri Lanka) sim. So... these are the mobitel settings
Name : Mobitel
APN : mobitel3g
proxy : 192.168.050.163
port : 8080
username :
password :
And keep all others with default values.
Then enable the data access over mobile network.
Menu -> Settings -> Wireless & networks -> Mobile networks -> Data enabled (put a tick)
Steps...
Menu -> Settings -> Wireless & networks -> Tethering & portable hotspot -> Portable Wi-Fi hotspot (put a tick)
You can configure Network SSID (Service Set Identifier) and password in hotspot configurations.
Your portable hotspot is ready to use.... ;)
Menu -> Settings -> wireless network -> Mobite networks -> Access Point Names. Press Menu button. New APN.
I used a mobitel (Sri Lanka) sim. So... these are the mobitel settings
Name : Mobitel
APN : mobitel3g
proxy : 192.168.050.163
port : 8080
username :
password :
And keep all others with default values.
Then enable the data access over mobile network.
Menu -> Settings -> Wireless & networks -> Mobile networks -> Data enabled (put a tick)
Now the phone should allow to connect to the internet. [If there are enough signal strength... :)]
Ok... then convert the phone to allow other devices [laptops, phones etc.. which has Wi-Fi] to use the same network connection. In other word make it a "hotspot".
Steps...
Menu -> Settings -> Wireless & networks -> Tethering & portable hotspot -> Portable Wi-Fi hotspot (put a tick)
You can configure Network SSID (Service Set Identifier) and password in hotspot configurations.
Your portable hotspot is ready to use.... ;)
Tuesday, March 20, 2012
How to take screen shots on nexus s phone.
There are dozens of free applications on the android market for take screen shots. But they are not supported for Nexus S phone. Because it is a unrooted phone. [I'll talk more about this later.. ;) ] However, after trying several ways i found a successful method. But it need a computer which has android sdk.
Simply you have to follow these 5 steps. [mm... I tried on windows 7]
2) Enable your phone for USB debugging.
Menu -> Settings -> Applications -> Development -> USB debugging
3) Connect the phone to the computer through USB.
4) Start DDM.
You can find an application called DDM inside tools in "android sdk" folder. Start it.
5) Select the phone and go to "Device -> Screen capture" [or press Ctrl+S]
Wednesday, March 14, 2012
quartz...
Story... ;)
Last week I thought to improve my appzone application. Its a message alert system. Which has some groups and users can join to those groups. Then they will recieves messages every morning. The improvement is i just want to set separatem trigger times for each group. Currently i used quartz in spring context file. I created one schedular factory bean, one trigger bean, and one job bean. So simply what i have to do is create each one of those for each group. But its not possible it another group will added. hmmm.... I need a dynamic and more configurable way. Before explain the solution i'll show my old codes.
<bean class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
<property name="triggers">
<list>
<ref bean="alertMessageTrigger"/>
</list>
</property>
</bean>
<bean id="alertMessageTrigger" class="org.springframework.scheduling.quartz.CronTriggerBean">
<property name="jobDetail" ref="alertMessageTimeTrackJob"/>
<property name="cronExpression" value="0 0 8 * * ?"/>
</bean>
<bean name="alertMessageTimeTrackJob" class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
<property name="targetObject" ref="dailyAlertManager"/>
<property name="targetMethod" value="startDaily"/>
</bean>
<bean id="dailyAlertManager" class="myroad.util.impl.AlertManagerImpl">
<property name="limit" value="${sms.data.retreive.batch.size}"/>
</bean>
"AlertManagerImpl" class has a method called "startDaily". So that message will executes by the cron when trigger time occurs. To understand the cron expression please check my old posts.
Ok.. now the solution. I create new class "MySchedularFactoryBean" by extending "SchedularFactoryBean". So to initialize create a bean of that class inside the context file. Now the context.xml has only this.
<bean class="myroad.say.util.impl.SaySchedulerFactoryBean">
<property name="groupService" ref="groupService"/>
</bean>
This is my class.
public class MySchedulerFactoryBean extends SchedulerFactoryBean {
private Log logger = LogFactory.getLog(MySchedulerFactoryBean.class);
private GroupService groupService;
@Override
protected void startScheduler(Scheduler scheduler, int startupDelay) throws SchedulerException {
logger.info("Scheduler starting...");
try {
List<Group> groups = groupService.getAllGroups();
logger.debug("Number of groups in database = " + groups.size());
for (Group group : groups) {
if (null == group.getQtzExpression() || group.getQtzExpression().equals("")) {
continue;
}
JobDetail jobDetail = new JobDetail();
jobDetail.setName(group.getShortName());
jobDetail.setJobClass(GroupMsgSendJob.class);
CronTriggerBean triggerBean = new CronTriggerBean();
triggerBean.setName(group.getShortName() + "Trigger");
try {
triggerBean.setCronExpression(group.getQtzExpression());
} catch (ParseException e) {
logger.error("Exception while parsing quartz expression for " + group.getShortName() + "Group.", e);
}
scheduler.scheduleJob(jobDetail, triggerBean);
}
} catch (myroad.say.exception.DBException e) {
logger.error("DB exception occurs while searching groups for load schedules.", e);
} catch (SQLException e) {
logger.error("SQL exception occurs while searching groups for load schedules.", e);
}
super.startScheduler(scheduler, startupDelay);
}
public void setGroupService(GroupService groupService) {
this.groupService = groupService;
}
}
For your convienience I'll show my "Group" pojo.
public class Group {
private int id;
private String shortName;
private String description;
private List<String> synonyms;
private String successMessage;
private String responseMsg1;
private String qtzExpression;
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public List<String> getSynonyms() {
return synonyms;
}
public void setSynonyms(List<String> synonyms) {
this.synonyms = synonyms;
}
public String getShortName() {
return shortName;
}
public void setShortName(String shortName) {
this.shortName = shortName;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public String getSuccessMessage() {
return successMessage;
}
public void setSuccessMessage(String successMessage) {
this.successMessage = successMessage;
}
public String getResponseMsg1() {
return responseMsg1;
}
public void setResponseMsg1(String responseMsg1) {
this.responseMsg1 = responseMsg1;
}
public String getQtzExpression() {
return qtzExpression;
}
public void setQtzExpression(String qtzExpression) {
this.qtzExpression = qtzExpression;
}
}
This one solves my problem. But i have to restart the system after adding new group into the database. mmm... its not a big issue. Because I may add new group once a two or three months ;)
However there is a solution even for that. We can set data source for quarts. Then it will handle the cron expressions dynamically. Also it consumes less proccessing power than my solution.
Last week I thought to improve my appzone application. Its a message alert system. Which has some groups and users can join to those groups. Then they will recieves messages every morning. The improvement is i just want to set separatem trigger times for each group. Currently i used quartz in spring context file. I created one schedular factory bean, one trigger bean, and one job bean. So simply what i have to do is create each one of those for each group. But its not possible it another group will added. hmmm.... I need a dynamic and more configurable way. Before explain the solution i'll show my old codes.
<bean class="org.springframework.scheduling.quartz.SchedulerFactoryBean">
<property name="triggers">
<list>
<ref bean="alertMessageTrigger"/>
</list>
</property>
</bean>
<bean id="alertMessageTrigger" class="org.springframework.scheduling.quartz.CronTriggerBean">
<property name="jobDetail" ref="alertMessageTimeTrackJob"/>
<property name="cronExpression" value="0 0 8 * * ?"/>
</bean>
<bean name="alertMessageTimeTrackJob" class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
<property name="targetObject" ref="dailyAlertManager"/>
<property name="targetMethod" value="startDaily"/>
</bean>
<bean id="dailyAlertManager" class="myroad.util.impl.AlertManagerImpl">
<property name="limit" value="${sms.data.retreive.batch.size}"/>
</bean>
"AlertManagerImpl" class has a method called "startDaily". So that message will executes by the cron when trigger time occurs. To understand the cron expression please check my old posts.
Ok.. now the solution. I create new class "MySchedularFactoryBean" by extending "SchedularFactoryBean". So to initialize create a bean of that class inside the context file. Now the context.xml has only this.
<bean class="myroad.say.util.impl.SaySchedulerFactoryBean">
<property name="groupService" ref="groupService"/>
</bean>
This is my class.
public class MySchedulerFactoryBean extends SchedulerFactoryBean {
private Log logger = LogFactory.getLog(MySchedulerFactoryBean.class);
private GroupService groupService;
@Override
protected void startScheduler(Scheduler scheduler, int startupDelay) throws SchedulerException {
logger.info("Scheduler starting...");
try {
List<Group> groups = groupService.getAllGroups();
logger.debug("Number of groups in database = " + groups.size());
for (Group group : groups) {
if (null == group.getQtzExpression() || group.getQtzExpression().equals("")) {
continue;
}
JobDetail jobDetail = new JobDetail();
jobDetail.setName(group.getShortName());
jobDetail.setJobClass(GroupMsgSendJob.class);
CronTriggerBean triggerBean = new CronTriggerBean();
triggerBean.setName(group.getShortName() + "Trigger");
try {
triggerBean.setCronExpression(group.getQtzExpression());
} catch (ParseException e) {
logger.error("Exception while parsing quartz expression for " + group.getShortName() + "Group.", e);
}
scheduler.scheduleJob(jobDetail, triggerBean);
}
} catch (myroad.say.exception.DBException e) {
logger.error("DB exception occurs while searching groups for load schedules.", e);
} catch (SQLException e) {
logger.error("SQL exception occurs while searching groups for load schedules.", e);
}
super.startScheduler(scheduler, startupDelay);
}
public void setGroupService(GroupService groupService) {
this.groupService = groupService;
}
}
For your convienience I'll show my "Group" pojo.
public class Group {
private int id;
private String shortName;
private String description;
private List<String> synonyms;
private String successMessage;
private String responseMsg1;
private String qtzExpression;
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public List<String> getSynonyms() {
return synonyms;
}
public void setSynonyms(List<String> synonyms) {
this.synonyms = synonyms;
}
public String getShortName() {
return shortName;
}
public void setShortName(String shortName) {
this.shortName = shortName;
}
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public String getSuccessMessage() {
return successMessage;
}
public void setSuccessMessage(String successMessage) {
this.successMessage = successMessage;
}
public String getResponseMsg1() {
return responseMsg1;
}
public void setResponseMsg1(String responseMsg1) {
this.responseMsg1 = responseMsg1;
}
public String getQtzExpression() {
return qtzExpression;
}
public void setQtzExpression(String qtzExpression) {
this.qtzExpression = qtzExpression;
}
}
This one solves my problem. But i have to restart the system after adding new group into the database. mmm... its not a big issue. Because I may add new group once a two or three months ;)
However there is a solution even for that. We can set data source for quarts. Then it will handle the cron expressions dynamically. Also it consumes less proccessing power than my solution.
Subscribe to:
Posts (Atom)