ss_blog_claim=726e70d7c87c20ae33aa7a61f06eb8aa

Sunday, May 30, 2010

Introduction to Random Access Mode of APR 9600

Hi readers, so we are on track looking into my EMAS - Wi Tech project. In our last post we were looking into APR9600 in brief. Now let us look into its usage in our project. The APR9600 has various modes of operation of which we have selected the 'Random Access 8 fixed duration messages' mode, where we could record 8 voice signals and play them back. The below is the table for different modes of operation of APR9600,

Let us look into the Random Access Mode functionality of APR9600 in my next post

Thursday, April 29, 2010

Introduction to APR9600

In our last post we discussed on how to monitor Saline level using an LDR, now let us move to the APR module. Before going to the interface part of APR 9600 with the microcontroller, lets look about APR9600 in brief.



The APR 9600 is a 28 pin device used to record and playback maximum of 8 messages. The APR9600 device offers true single-chip voice recording, non-volatile storage, and playback capability for 40 to 60 seconds. The device supports both random and sequential access of multiple messages. Sample rates are user-selectable, allowing designers to customize their design for unique quality and storage time needs. Integrated output amplifier, microphone amplifier, and AGC circuits greatly simplify system design. The device is ideal for use in portable voice recorders, toys, and many other consumer and industrial applications.

Tuesday, April 13, 2010

Saline Level monitoring using LDR

Hi folks, we are looking into one of my project "EMAS - Wi Tech", In our previous post we saw some introduction about it. Now we are going to dig further on the different sensor circuits used. The first one which we would see is how we monitored the saline level using an LDR, Just go through the below para for detials on the circuit what we used.


The LDR sensor circuit consists of a comparator, an LDR and a pair of multi-turn preset resistor (10k ohm). The LDR is connected in series with a preset resistor forms a voltage divider configuration. When no laser beam falls on the LDR its resistance will be very high compared to 10k ohm. So by voltage divider rule small voltage will be available across the preset resistor. But when laser beam falls on the LDR its resistance becomes almost zero. So voltage across the preset will become nearly 5V. This change in voltage across the preset can be detected using a comparator. Comparator is constructed using UA741.
The threshold voltage can set using another 10k ohm preset connected to the inverting input of the opamp.
In normal condition output of comparator remains at logic zero because the laser beam is distracted by the saline present in the bottle, but when saline level reduces, the distraction is lost and the laser beam falls on the LDR, because of this comparator output changes to logic one. This change is used by microcontroller to detect the quantity in the saline bottle.

Sunday, April 4, 2010

Introduction to EMAS-Wi Tech

Hi guys last week we were looking on brief into one of my project "Emergency Announcement System In Hospital Using Wireless Technology" which I have abbreviated as "EMAS-Wi Tech". It is now time to look into it in detail. This post will explain the outline of the project and the components used. Just look at the below block diagram which describes the outline of our project.



In the Transmitter side, The Output from the sensors are continuously monitored by the microcontroller, when the microcontroller senses any abnormal values, it transmits corresponding data through wireless medium with the help of the ZigBee module. On the Receiver side, the wireless data obtained by the ZigBee module is sent to the Microcontroller, The microcontroller then analyses the data obtained from the ZigBee module and triggers corresponding messages signals to the APR module. The APR module playbacks corresponding voice recorded signals according to the message signals obtained from the microcontroller.

P89V51RD2, an 8051 Microcontroller is the Main component at the Transmitter side, which is used to sense the output from the Sensors. The Saline Level is sensed using an LDR sensor unit. XBee PRO is used in the ZigBee module at the Transmitter and Receiver sides. PIC16F877A is used at the Receiver side, which senses the output from the ZigBee module. APR9600 is used to playback recorded voice signals based on the input from the Microcontroller.

Sunday, March 28, 2010

Emergency Announcement System In Hospital Using Wireless Technology

The above topic is the name of our project which we did for AU PERS center. Here is a brief detail on our project "Emergency Announcement System In Hospital Using Wireless Technology"

The advancement in technology had favored many fields. The Emergency announcement systems present in the hospitals nowadays, are not implemented real time and any crucial data is transmitted through wired means. There is a probability for the crucial data to get lost, by not reaching the right person at the right time. Our system is designed to overcome these drawbacks by transmitting the data obtained from sensors to the respected persons through wireless means. Sensors are provided to measure the physical values e.g. Saline level, heart beat, etc. The outputs from these sensors are fed to the microcontroller which is monitoring continuously. When abnormal input conditions were sensed by the microcontroller, it transmits respective message to the intended person immediately through wireless medium. The entire system is designed to provide a cost effective solution to save the life of people in need.

More details on my next post.....

NOTE: AU PERS center has been shutted down last year

Friday, November 28, 2008

The usage of ‘gets’ statement in C Programming

Well we have already discussed about the usage of ‘fflush’ statement, let us now discuss about the usage of ‘gets’ statement. String is an array of characters and we use the format specifier ‘%s’ to directly get these array of characters, which is not possible in the case of array of integers. In the case of array of integers we use the ‘for’ loop to get the values since we don't have any format specifier for array of integers.

To get array of characters we use the format specifier ‘%s’ as shown below

puts(“Enter the string”);
scanf(“%s”,ex_str);
puts(ex_str);

Output:

Enter a string
sample text
sample

What is wrong in the output?? We know that ‘Space’ and ‘Enter’ key act as a delimiter. So if you execute this program and give input as ‘sample text’ the value stored in ‘ex_str’ is ‘sample’ and not ‘sample text’ this is because the space in between the words ‘sample’ and ‘text’ acts as a delimiter thus storing only ‘sample’ in the character array (string). To overcome this problem we use the ‘gets’ statement. The ‘gets’ statement takes only the ‘Enter’ key as delimiter. The below part of the code shows how to use ‘gets’ statement.

puts(“Enter a string”);
gets(ex_str);
puts(ex_str);

Output:

Enter a string
sample text

sample text

Just think of getting a name of a person which contains first name, last name and middle name so this ‘gets’ statement is much useful in those situations. Happy Programming!!

Saturday, November 15, 2008

The usage of ‘fflush’ statement in C programming

The keyboard has an input buffer in it and every time you read data from the keyboard the value stored in the input buffer is read. For every key press there will be a value loaded into the input buffer which means that the ‘Enter’ key, ‘Tab’ key also has a value being stored in the buffer when pressed.


We know that the ‘Enter’ key and the ‘Tab’ key acts as a delimiter while accepting data. Consider the below C Program

void main()
{
int num;
char ch;
clrscr();
printf(“Enter a number\n”);
scanf(“%d”,&num);
printf(“Enter a character\n”);
scanf(“%c”,&ch);
printf(“The value of num is %d and ch is %c”,num,ch);
getch();
}

The output of the program is shown below

Enter a number
12
Enter a character
The value of num is 12 and ch is

Wonder why this happens? Well let us look at the problem. When you type the number 12 and press ‘Enter’ key, the value corresponding to key press ‘1’ and ‘2’ is read from the input buffer and gets assigned to the variable ‘num’ once you press the ‘Enter’ key(delimiter). Now the value of the ‘Enter’ key is stored in the input buffer. So when you want to read a character, the value of the ‘Enter’ key which is stored in the input buffer is assigned to the character variable ‘ch’. This results in giving a wrong output. This is where the ‘fflush’ command comes into picture. The ‘fflush’ clears the specified buffer, so after getting the integer value we need to clear the input buffer (which stores the ‘Enter’ key value) before getting the character value. So the C program is changed as shown below.

printf(“Enter a number\n”);
scanf(“%d”,&num);
fflush(stdin);
printf(“Enter a character\n”);
scanf(“%c”,&ch);

Hope you know understood the importance of ‘ffush’ statement