You are on page 1of 14

See discussions, stats, and author profiles for this publication at: https://www.researchgate.

net/publication/299404952

Audio signal's test in designing a cost-effective hearing aid device using a


microcontroller

Article in International Journal of Biomedical Engineering and Technology · January 2016


DOI: 10.1504/IJBET.2016.075421

CITATIONS READS

2 376

5 authors, including:

Muhammad Zia ur rehman Syed Irtiza Ali Shah


Riphah International University Georgia Institute of Technology
41 PUBLICATIONS 628 CITATIONS 140 PUBLICATIONS 735 CITATIONS

SEE PROFILE SEE PROFILE

Muzzamil Javaid Syed Omer Gilani


National University of Sciences and Technology National University of Singapore
5 PUBLICATIONS 179 CITATIONS 106 PUBLICATIONS 1,548 CITATIONS

SEE PROFILE SEE PROFILE

All content following this page was uploaded by Syed Irtiza Ali Shah on 15 February 2023.

The user has requested enhancement of the downloaded file.


Int. J. Biomedical Engineering and Technology, Vol. 20, No. 3, 2016 195

Audio signal’s test in designing a cost-effective


hearing aid device using a microcontroller

Muhammad Zia ur Rehman* and


Syed Irtiza Ali Shah
Department of Robotics & Artificial Intelligence,
National University of Sciences and Technology,
Islamabad, Pakistan
Email: ziaurrehman@smme.edu.pk
Email: Zia.bme@gmail.com
Email: irtiza@smme.nust.edu.pk
*Corresponding author

Muzzamil Javaid
Department of Biomedical Engineering and Sciences,
National University of Sciences and Technology,
Islamabad, Pakistan
Email: muzamil.javaid@gmail.com

Syed Omer Gilani


Department of Robotics & Artificial Intelligence,
National University of Sciences and Technology,
Islamabad, Pakistan
Email: omer@smme.nust.edu.pk

Umar Ansari
Department of Biomedical Engineering and Sciences,
National University of Sciences and Technology,
Islamabad, Pakistan
Email: ansari@smme.nust.edu.pk

Abstract: A large number of hearing impaired people in rural sector of


Pakistan cannot afford the high prices of digital hearing aids. Moreover, since
the analogue devices amplify the speech and noise signals equally, they are not
much flexible and have functional limitations. These problems can be solved
with digital devices which are generally costly. In this research work, a
microcontroller based cost-effective and portable hearing aid is designed and
tested. The main components include sound detection circuit, microcontroller
and a digital to analogue (DAC) convertor. Device is aimed to process human
voice frequencies with an adjustable gain of up to 80 dB. It is tested with an
input audio signal and it showed satisfactory results for low frequency signals
up to 3.5 kHz which caters for the frequency range of most human voices. The
system is now being developed for more effective noise suppression and
broader frequency range.

Copyright © 2016 Inderscience Enterprises Ltd.


196 M. Zia ur Rehman et al.

Keywords: audio signals; hearing device; frequency; digital analogue


conversion; impairment; analogue to digital converter; microcontroller; human
voice; anti-aliasing filter; pre-amplifier.

Reference to this paper should be made as follows: Zia ur Rehman, M., Shah,
S.I.A., Javaid, M., Gilani, S.O. and Ansari, U. (2016) ‘Audio signal’s test in
designing a cost-effective hearing aid device using a microcontroller’,
Int. J. Biomedical Engineering and Technology, Vol. 20, No. 3, pp.195–207.

Biographical notes: Muhammad Zia ur Rehman is HEC awardee PhD scholar


at Department of Robotics and Artificial Intelligence, SMME, National
University of Science and Technology Pakistan. He received his bachelor’s
degree in Electronics Engineering (2012) and Master’s in Biomedical
Engineering from NUST Islamabad (2014). His research interest includes
signal processing, medical image processing, computer vision and electronics
circuit design.

Syed Irtiza Ali Shah is currently working as Associate professor at R&AI


department, SMME and head of NUST Community Service Club at National
University of Science and Technology Pakistan. He obtained his bachelor’s
degree in Aerospace engineering (1993), 4 Master’s degrees and a PhD degree
in Aerospace-Arial Robotics from Georgia Institute of Technology, USA
(2010). He has R&D experience of 10 years and engineering management
experience of 9 years. Apart from this, he has received many awards, gold
medals and is author co-author of more than 20 publications. His area of
specialisation includes ground & aerial robotics, computer vision, medical
imaging, advanced dynamics, automatic controls and currently different
projects are under progress in his supervision.

Muzzamil Javaid has completed his bachelor’s degree in Electrical Engineering


(2007) and Master’s degree in Biomedical Engineering from NUST Islamabad
(2014). His research interest includes signal processing, medical image
processing and computer vision.

Syed Omer Gilani is currently working as an Assistant Professor at R&AI


department, SMME National University of Science and Technology Pakistan.
He earned his PhD degree in Electrical and Computer Engineering from
National University of Singapore (2013). Between 2006 and 2008, he worked
on various vision and augmented-reality based projects at Interactive
Multimedia Lab, Singapore. His current research interests include human
computer interaction, biological vision, and machine learning.

Umar Ansari is a Lecturer at BMES department, SMME National University of


Science and Technology Pakistan. He is a PhD Candidate (Biomedical
Engineering) at University of New South Wales, Australia. His area of
specialisation includes prosthetic implants designing and Functional electronic
stimulation (FES) systems.

This paper is a revised and expanded version of a paper entitled


‘Microcontroller based design and analysis for a cost effective hearing aid
device’ presented at the ‘2nd International Conference on Engineering and
Emerging Technologies (ICEET 2015)’, Superior University, Lahore, Pakistan,
26–27 March 2015.
Audio signal’s test in designing a cost-effective hearing aid device 197

1 Introduction

World Health Organization (WHO) report shows that 360 million people are suffering
from disabling hearing loss worldwide (WHO, 2012). Hearing loss affect the developing
and learning processes in children and deprive students of written communication and
interpreting text or forming sentences etc. (Fernandes et al., 2013). In adults, it effect and
creates problems in the education, employment and general wellbeing. It affects the
professional and personal relationships (Grewal and Irwin, 2012) and may cause emotional
or psychological problems (Fernandes et al., 2013; Leigh, 2010). Cochlear implants and
hearing aids have been developed to counter such effects but small portion of people
seeks help and use them (Knudsen et al., 2010). Studies show that large number of adults
do not have hearing aids who could take benefits from it (Smits et al., 2006; Smeeth
et al., 2002).
Hearing aids can be classified into two types, the analogue and digital hearing aids.
The analogue hearing aid processes the signal in analogue domain while the digital hearing
aid first converts the signal into digital domain and then processes it. The conventional
analogue aids amplify all the frequencies equally hence along with the desired audio
signal, it also amplifies the noise. It cannot differentiate between the signal and background
noise. More ever it cannot be programmed during the fitting process. Some analogue aids
have different listening profiles which the user can select using a button on hearing aid
(Ricketts, 1997). The advancement in the digital technology and introduction of Digital
Signal Processing (DSP) (Strom, 2006; Kerckhoff et al., 2008) to the hearing aids in the
past decade (Edwards, 2007) has much improved the hearing aid (Kerckhoff et al., 2008).
DSP offers many advantages over the analogue hearing aids including the programmability,
self-monitoring, acoustic feedback control, signal level control and adaptive adjustment
etc. (Levitt, 1987). The Digital hearing aids first convert the signal into digital domain
and then process it. Hence utilising the software and proper configuration of the system,
speech signal can be much improved even in the presence of noise.
As shown in the Figure 1, a digital hearing aid contains a mic which captures the
audio signal and converts it into an electrical signal. The Preamplifier circuit amplifies
the audio signal such that it matches the input signal level of ADC. A filter (anti-aliasing)
is necessary in order to avoid the noise (before ADC) (Agarwal and Ramachandran,
2008) in the output signal. The DSP section process the digital signal accordingly to the
user requirement and DAC convert the signal back into analogue domain which is
received by the user through earphone.

Figure 1 Block diagram of a digital hearing aid (see online version for colours)
198 M. Zia ur Rehman et al.

In this paper, we will explore the microcontroller based low cost and portable
digital hearing aid which has a reduced circuitry. Utilising the internal clock of the
microcontroller and built-in ADC avoids the extra circuitry and hence reduce area. The 8
bit external DAC helps in suppressing the background noise which is very low in
intensity. Hence using the readily available components and circuitry, the system is
simple, portable and cost effective.
In the next Section 2, we present the circuit design; Section 3 working of the system,
Section 4 results and discussions and in the last Section 5 conclusions is presented.

2 Circuit design

The main components of the designed system are pre-amplifier circuit, aliasing filter,
microcontroller and DAC.

2.1 Mic and pre-amplifier circuit


The purpose of preamplifier circuit is to amplify the signal such that to level it to the
input signal requirement of analogue to digital converter, which is from 0 to 5 volt. To
achieve this level, an operational amplifier LM 324 is used. The Electrical signal from
the mic is fed to the inverting input of the op-amp, while the non-inverting input is
kept at stable 2.5 V from the battery. This combination of inputs provides the DC offset
of 2.5 V at the output and now the 180 degree phase shifted audio signal oscillate across
offset value.

Figure 2 Preamplifier circuit diagram. It has a fixed gain of up to 40 dB and the input and output
signals are out of phase by 180 degrees (see online version for colours)
Audio signal’s test in designing a cost-effective hearing aid device 199

2.2 Anti-aliasing filter


The purpose of anti aliasing filter is to avoid the aliasing noise at the output of analogue
to digital converter (ADC). Nyquist-Shanon sampling theorem suggests that the sampling
frequency of ADC should be at least two times the highest frequency component in a
signal. If the sampling frequency is less than the double of max frequency component in
the signal, then the higher frequencies will fold back over the lower frequencies and it
will create aliasing effect. Normally the human voice which is perceptual in nature
(Castillo-Guerra, 2009) has a frequency range in between 300 to 3000 Hz. As in the
proposed system, we are only interested in capturing the human voice only, so here the
filter has two main purposes
 avoid aliasing effect
 pass human voice frequencies
So to achieve these goals, R.P. Sallen and E.L. Key (Hennink, 2009) second order low
pass filter with unity gain is used (Franco, 2001).

Figure 3 Second-order anti-aliasing filter diagram. It has a unity gain with a quality factor of 0.5,
which gives a good compromise between the rising and settling time of the signal
(see online version for colours)

Some of the formulas for parameters like cut-off frequency (w0) and quality factor (Q)
are as below;
w0 = 1 / R1R2C1C2 (1)
And
fcutoff =w0 / 2*pi (2)
For quality factor
Q = (R1R2C1C2)1/2 / C1(R1+R2) – (K-1) R1C2 (3)
200 M. Zia ur Rehman et al.

where
w0 = 2*pi*fcut-off
R1 = resistance of resister 1
R2 = resistance of resistor 2
C1= capacitance of capacitor 1
C2=capacitance of capacitor 2
Q = quality factor
K = gain of filter
In this design, the gain of the filter is kept one and quality factor is kept ½ because this
value of Q gives good results in rise time and settling time (Hennink, 2009).
Hence putting R1 = R2 = 10k, K = 1 and Q = 0.5 in equation (1) and (3) and solving
for C1 and C2 , we get
C1 = C2 = 1/ R.w0 (4)
If putting cut-off frequency fcut-off= 3.5k Hz, we get
C1 = C2 = 4.7 nF
This value of filter’s cut-off frequency gives a good approximation of capturing human
voice frequency along with setting the maximum frequency limit for ADC.

2.3 Microcontroller and DAC


The atmega 32 is specifically chosen for this work because of its several advanced level
features like analogue to digital conversion which makes it ideal in applications like
automotives, medical and consumer applications. It is readily available cost effective
microcontroller which has a built in ADC and has 8 bit architecture. The large
programming memory, extra ports and analogue channels make it flexible here in this
application because it can be used for adding extra features in hearing aids like direct
audio input and directionality etc.
The analogue audio signal from the output of anti-aliasing filter is digitised by the
built in 10 bit ADC of the microcontroller and after desired processing, it is converted
back to analogue domain by 8 bit DAC which is interfaced in parallel with the
microcontroller.

2.4 Post amplifier and earphone


Op amp is one of the main block in analogue systems which is an active element and is
designed to perform specific signal processing operations (Santhanalakshmi and Vanathi,
2012). The analogue signal from the DAC output is fed to the post amplifier circuit and
for this purpose LM 386 is used which is a low power audio signal amplifier. The circuit
is designed such that the maximum achievable gain is 80 dB and output is finally fed to
earphone.
Audio signal’s test in designing a cost-effective hearing aid device 201

Figure 4 DAC interface with Atmega 32. DAC is interfaced parallel with port D of
microcontroller and its output is fed to the post amplifier circuit (see online version for
colours)

Along with the major components, the individual blocks and circuits are specially
designed and focused to work accordingly to the requirements. The proposed circuit was
first implemented in software and then it was tested on breadboard as shown in Figure 5
and after final testing it was implemented on PCB as shown in Figure 6.

Figure 5 Hardware design of the system. After successful software simulation results, the
individual circuits were tested on breadboard

Some of the components used in the design are as fallows


 Electret mic
 Opamp (lm324, lm741, lm386 )
 Built-in ADC of AVR ATmega32 microcontroller
 Microcontroller ATmega32
202 M. Zia ur Rehman et al.

 Digital to Analogue converter (DAC0808)


 Resisters
 Capacitors
 Inductors
 Earphone

Figure 6 PCB implementation of the circuit. After satisfactory results on breadboard, the system
is implemented on PCB

3 Working of the system

The electret microphone picks up the audio signal and converts it into the analogue
electrical signal whose magnitude is in millivolts. The signal level at this stage needs to
be amplified and for this purpose, it is fed to the pre-amplifier circuit which levels the
intensity or amplitude of a signal such that it is matched to the input level of ADC. The
potentiometer used in the feedback path of a preamplifier circuit gives control over the
amplitude of a signal at the output of preamplifier circuit. Before the ADC conversion,
the signal is passed through the Anti-aliasing filter which is specially designed
accordingly to the human voice frequency range and user requirements. This filter
minimises the aliasing effects in the reconstructed signal and passes the voice frequencies
without any attenuation and fed it in to the 10-bit ADC of a microcontroller, which
convert it into a digital signal. Microcontroller process the digital signal and after
required processing, the signal is converted back to analogue signal using an external 8-
bit DAC. The two least significant bits of ADC are ignored at this stage which helps to
suppress or reduce the amplitude of low intensities background noise. The audio signal at
the output of DAC is fed to the post amplifier which has an adjustable gain of up to 80
dB. Finally the signal is fed to earphone whose one end is plugged into the jack on the
circuit and other end is in the ear of user as shown in Figure 4. The each sub-circuit of
the system like preamplifier, ant aliasing filter, ADC and DAC woks individually and
contribute to the overall system. Figure 7 shows the working flow of the system and its
major results are discussed in coming section.
Audio signal’s test in designing a cost-effective hearing aid device 203

Figure 7 working flow of the circuit. Output of electret mic in millivolts is shown with red, this
signal is inverted, amplified and given offset of 2.5 volts and then passed through the
filter as shown with blue. The DAC setting is such that it brings the signal back to
ground level as shown with green

4 Results and discussions

This microcontroller based cost effective and portable design is successfully


implemented on PCB and it showed acceptable results for both the amplification and in
the frequency domain. The system gain is variable with minimum range set by the
preamplifier between 30 to 40 dB (as shown in Figure 8) and the final gain is controlled
by post amplifier with a maximum of 80 dB.

Figure 8 Gain of the system. The horizontal axis is of the frequency up to 3.5 kHz while the
vertical axis is the magnitude in dB. Red is the input audio signal and yellow is the
output signal with a gain different of almost 30–40 dB set by preamplifier
204 M. Zia ur Rehman et al.

The anti-aliasing filter is specially designed and separately tested for the low frequencies
including the human voice frequency range (500–3500 Hz). The response of the filter is
as shown in the Figures 9 and 10.

Figure 9 Frequency response of the filter. Red stars show the passing frequencies while the black
circles show the attenuated frequencies

Figure 10 Phase and frequency response of the system. Normally voice range is between 500–
3500 Hz. The upper red curve shows the frequency response and green curve is the
phase response. The system passes the voice frequencies with maximum acceptable
attenuation of –3 dB at cutoff frequency of 3.5 kHz

A test audio signal of 50–8000 Hz was given as input to the system and the test signal is
such that its frequency first moves from lowest to highest point, and then comes back
to lowest point and it repeats two times. The response of the system is as shown in
Figures 11a, 11b and 11c.
Audio signal’s test in designing a cost-effective hearing aid device 205

Figure 11 Testing audio signal response. (a) Yellow is input signal, blue is filter output and pink
is the system output. As the input signal frequency moves towards higher range, the
filter passes the low frequencies with desired gain and attenuates the higher frequencies
after cutoff; (b) When the frequency moves from higher towards lowest point and again
moves toward higher frequencies, the system passes lower frequencies portion with
desired gain and attenuates the higher frequencies; (c) At the end, when frequency
moves toward lowest point, again higher frequencies are attenuated and lower
frequencies are passed with desired gain

(a)

(b)

(c)
206 M. Zia ur Rehman et al.

After the gain and frequency response, the 8 bit external DAC avoids the two LSBs of
ADC which helps in suppressing the low intensities background noise. The overall
system response is desirable and this device is better for the patients having the
impairment with mild up to moderately severe degree.
Hearing aid is one of the achievements of biomedical engineers (Azar, 2011) who
applies the principal of engineering combined with biology and medicine, to design and
solve problems in health care industry (Azar, 2011; Azar, 2012). The previously done
work on the same topic is a bit complex in the sense that results and simulations are not
mentioned clearly, i.e. Eze et al. (2012) discusses the hearing aid with output level
indicator which provides fix sound levels, although the technique discussed is interesting
but there are no simulation results to show. (Mashud et al., 2013) discusses the low
power consumed hearing aid device which turned into on state only when sound is
detected.
The proposed device is better in the sense that it provides the amplification of sound
based on the requirement of user and no fixed levels (as discussed previously). Although
such microcontroller based designs have few limitations due to their weight and size but
they can be miniaturised and has advantage with respect to its low cost and such
instruments are user friendly and portable and their large memory can be utilised in
development of further features in hearing aids like directionality, DAI and frequency
channelling (which are being developed).
No matters how much the degree of Impairment is, but it affects the individual in
different fields of life (Eze et al., 2012), i.e. he/she cannot be able to communicate
properly with others and his/her surrounding. Although technological advancement in the
recent years has significantly lowers the price of electronic equipment but the prices of
medical devices are still high (Mashud et al., 2013). But the microelectronics field
development reduces the price of components and instruments (Mashud et al., 2013). The
microcontroller based hearing aids will take a long time to become common among the
users (Eze et al., 2012) but it provides an easy and cost effective way to enjoy the clear
hearing with ease and comfort.

5 Conclusion

The proposed design was first implemented in software and after successful simulation
results, it was implemented on hardware. The system showed the satisfactory results for
the low frequency signals. The system is flexible in the sense that the large memory of
the microcontroller, its extra analogue channels and ports can be used for other special
features like direct audio input and directionality etc. The system showed good results in
the human voice frequency range and it overcomes the limitation of analogue hearing
aid. The system is now being developed for more effective noise suppression and broader
frequency range with number of channels.
Audio signal’s test in designing a cost-effective hearing aid device 207

References
Agarwal, V. and Ramachandran, N. (2008) ‘Design and development of a low-cost spirometer with
an embedded web server’, International Journal of Biomedical Engineering and Technology,
Vol. 1, pp.439–452.
Azar, A.T. (2011) ‘Biomedical engineering: specialisations and future challenges’, International
Journal of Biomedical Engineering and Technology, Vol. 6, pp.163–177.
Azar, A.T. (2012) ‘Overview of biomedical engineering’, in Joel, J.P.C., Diez, I. and Abajo, B.
(Eds): Telemedicine and E-Health Services, Policies and Applications: Advancements and
Developments, IGI Global, USA.
Castillo-Guerra, E. (2009) ‘Acoustic study of dysarthria’, International Journal of Biomedical
Engineering and Technology, Vol. 2, pp.352–369.
Edwards, B. (2007) ‘The future of hearing aid technology’, Trends in Amplification, Vol. 11,
pp.31–46.
Eze, A.O., Ihekweaba, E.D.G. and Chinyere, N.R. (2012) ‘Exploring a microcontroller based
hearing aid with an output level indicator’, International Journal of Computational
Engineering Research, Vol. 2, pp.253–255.
Fernandes, J.C.L., Rodrigues, S.C.M. and Netto, O.L.D.C. (2013) ‘A virtual environment to help
deaf students with written language’, International Journal of Biomedical Engineering and
Technology, Vol. 12, pp.26–37.
Franco, S. (2001) Design with Operational Amplifiers and Analog Integrated Circuits, McGraw-
Hill Education.
Grewal, R. and Irwin, J. (2012) ‘Innovative ways hearing aids can be improved for clinical use: a
literature review’, Scottish Universities Medical Jour, Vol. 1.
Hennink, B. (2009) Designing a Second-Order Anti-aliasing Filter for a Sensor Signal Path.
Kerckhoff, J., Listenberger, J. and Valente, M. (2008) ‘Advances in hearing aid technology’,
Contemporary Issues in Communication Science and Disorders, Vol. 35.
Knudsen, L.V., Öberg, M., Nielsen, C., Naylor, G. and Kramer, S.E. (2010) ‘Factors influencing
help seeking, hearing aid uptake, hearing aid use and satisfaction with hearing aids: a review
of the literature’, Trends in Amplification, Vol. 14, pp.127–154.
Leigh, I.W. (2010) Psychotherapy with Deaf Clients from Diverse, Gallaudet University Press,
Washington, DC.
Levitt, H. (1987) ‘Digital hearing aids: a tutorial review’, Journal of Rehabilitation Research and
Development, Vol. 24, pp.7–20.
Mashud, M., Bishwas, M., Paul, S.R., Barman, S. and Islam, M.S. (2013) ‘Microcontroller based
low-power consumption smart hearing aid’, International Journal of Emerging Trends in
Engineering and Development, Vol. 2, pp.567–572.
Ricketts, T.A. (1997) Digital hearing aids: current “state of the art”, American Speech Language
and Hearing Association.
Santhanalakshmi, M. and Vanathi, P. (2012) ‘A 1.2 V improved operational amplifier for
bio-medical applications’, International Journal of Biomedical Engineering and Technology,
Vol. 9, pp.337–350.
Smeeth, L., Fletcher, A.E., Ng, E.S.-W., Stirling, S., Nunes, M., Breeze, E., Bulpitt, C.J., Jones, D.
and Tulloch, A. (2002) ‘Reduced hearing, ownership, and use of hearing aids in elderly people
in the UK – the MRC trial of the assessment and management of older people in the
community: a cross-sectional survey’, The Lancet, Vol. 359, pp.1466–1470.
Smits, C., Kramer, S.E. and Houtgast, T. (2006) ‘Speech reception thresholds in noise and
self-reported hearing disability in a general adult population’, Ear and Hearing, Vol. 27,
pp.538–549.
Strom, K. (2006) ‘The HR 2006 dispenser survey’, Hearing Review, Vol. 13, p.16.
WHO (2012) WHO global estimates on prevalence of hearing loss. Available online at:
http://www.who.int/pbd/deafness/estimates/en/

View publication stats

You might also like