Tut 3 : 7-segment LED and Keypad

A program to press keypad and display the numbers on 7-segment LED (common-anode).

7-segment LED display
 
It is composed of 8 LEDs- 7 segments are arranged as a rectangle for symbol displaying and there is an additional segment for decimal point displaying. In order to simplify connection, anodes or cathodes of all diodes are connected to the common pin so that there are common anode displays and common cathode displays, respectively. Segments are marked with the letters from a to g, plus decimal point (dp), as shown in figure below. On connecting, each diode is treated separately, which means that each must have its own current limiting resistor.



In addition to digits from 0 to 9, there are some letters- A, C, E, J, F, U, H, L, b, c, d, o, r, t  that can be also displayed by means of the appropriate masking.

Keypad configuration
 
PBP Program

' Example program to read keypad numbers and display with 7-segment

DEFINE OSC 20                          ' using 20MHz clock oscillator
@ device hs_osc

        row1 VAR PORTD.6    'declare ports
        row2 VAR PORTD.5
        row3 VAR PORTD.4
        row4 VAR PORTD.3
        col1 VAR PORTD.2
        col2 VAR PORTD.1
        col3 VAR PORTD.0
                    
        TRISD=%11111000 'assign ports
        TRISB=0
             
     loop:
    
     Low col1:High col2:High col3          'column 1

     IF (row1==0) Then                 'if key 1 is pressed
     PORTB=%1111001
     Pause 1000
     Else
     PORTB=%1111111
     EndIF
    
     IF (row3==0) Then                     'key 7
     PORTB=%1111000
     Pause 1000
     Else
     PORTB=%1111111
     EndIF
    
     IF (row4==0) Then                     'key *
     PORTB=%0111111
     Pause 1000
     Else
     PORTB=%1111111
     EndIF
    
     High col1:Low col2:High col3            'column 2

     IF (row1==0) Then                    'key 2
     PORTB=%0100100
     Pause 1000
     Else
     PORTB=%1111111
     EndIF
          
     IF (row4==0) Then                       'key 0
     PORTB=%1000000
     Pause 1000
     Else
     PORTB=%1111111
     EndIF

     High col1:High col2:Low col3           'column 3

     IF (row1==0) Then                    'key 3
     PORTB=%0110000
     Pause 1000
     Else
     PORTB=%1111111
     EndIF
    
     GoTo loop
     End
    
You should try to write your own program for numbers "4", "5", "6" "8", "9" and symbol "#"......


 

Tut 2 : Blinking LED

A program to blink LED red and green on SK40C board. The delay time is set to 1 second. The blinking will repeat continously.

 
LED and current limiting resistor

LED has two ends an anode and a cathode. Connect it properly to a power supply voltage. The diode will emit light. Depending on any power supply voltage, you need to discard the current through a current limiting resistor to protect LED from burning.

PBP Program

DEFINE OSC 20                                        ' using 20MHz clock oscillator
    @ device hs_osc

loop:  
        High PORTB.6:Low PORTB.7        
        Pause 1000                                          ' Delay for 1 second
        High PORTB.7:Low PORTB.6          
        Pause 1000                                          ' Delay for 1 second
        GoTo loop                                           ' Go back to loop and blink LED forever
        End


Hex Code
2823 01a3 00a2 30ff 07a2 1c03 07a3 1c03
281e 3003 00a1 30e6 200f 2803 01a1 3efc
00a0 09a1 1c03 281a 30ff 0000 07a0 1803
2815 07a0 0064 0fa1 2814 0008 1383 1303
1283 0064 0008 1706 1683 1306 1283 1386
1683 1386 1283 3003 00a3 30e8 018a 2002
1786 1683 1386 1283 1306 1683 1306 1283
3003 00a3 30e8 018a 2002 018a 2823 0063
018a 283f


Schematic diagram from Proteus




Tut 1 : Introduction to PIC16F877/877A

 PIC16F877 IC
 
PIC16F877 pin layout

 SK40C Development Board


SK40C and PIC16F877
 
 INTRODUCTION
 
This tutorial is to introduce the using of Microcontroller Microchip PIC16F877, its  technolgy the capabilities and the specifications of a commonly used in market and describe the experiments conducted using the SK40C development board from Cytron Technology which accomodates this microcontroller .
 
A microcontroller is a compact standalone mini-computer, optimized for control applications. Entire processor, memory and the I/O interfaces are located on a single piece of silicon so, it takes less time to read and write to extrernal devices.

The reasons why microcontrollers are incorporated in control systems are:

1) Cost: Microcontrollers with the supplemantary circuit components are much cheaper than a computer with an analog and digital I/O
2) Size and Weight: Microcontrollers are compact and light compared to computers
3) Simple applications: If the application requires very few number of I/O and the code is relatively small, which do not require extended amount of memory and a simple LCD display is sufficient as a user interface, a microcontroller would be suitable for this application.
4) Reliability: Since the architecture is much simpler than a computer it is less likely to fail.
5) Speed: All the components on the microcontroller are located on a singe piece of silicon. Hence, the applications run much faster than it does on a computer.   
 
One of the most important feature of the microcontroller is a number of input/output pins used for connection with peripherals. In this case, there are in total of thirty-five general purpose I/O pins available, which is quite enough for the most applications. In order pins’ operation can match internal 8-bit organization, all of them are, similar to registers, grouped into five so called ports denoted by A, B, C, D and E. They all have several features in common:
 
 
To become familiar how to start your first program click here
All programs written in C langguage.
 
To see a lot of projects done click here
 
In my next tutorial you will learn about basic language i.e Pic Basic Pro (PBP). It is more easier than using C language, but the programming architechture is almost the same. However, for those who are expert, some programming features in PBP are so limited, thus C langguage is most suitable. For beginners, PBP is the best choice and more prefereable. If you are good enough to master PBP, a lot of things can be done.
 

Project 18 : Aircond Temperature Controller

System test

Video on demand

Description

Aircond temperature controller comprises of PIC microcontroller, LM35D temperature sensor and relay board. The controller will maintain and control the temperature of a room set by the user. The relay board is used to turn on and off 240V AC supply to compressor. The user has flexibility to control the range of temperature, minimum and maximum degree to make sure that room is well conditioned.

This project is hoped to be an early attempt to any project related to energy saving or energy management. If we can control the compressor automatically and wisely, then a lot of energy can be utilised for other purposes. Apparently, aircond is one of loads that we may put into consideration as it runs at high power and contributes a lot in our bill. 1 h/p is equivalent to 746W. If we manage to save 10% energy, thus we manage to save 10% or more our money.

Prinsip operasi

Sebuah projek menggunakan temperature sensor LM35D utk memaparkan suhu semasa didalam bilik berhawa dingin. Ia akan mengawal litar bekalan kuasa kepada aircond (240Vac) menggunakan relay SPDT. Program PIC diatur untuk membaca suhu dan menghidupkan relay (compressor ON) jika suhu melebihi 28 darjah celcius atau mematikan relay (compressor OFF) jika suhu bilik kurang drpd 23 darjah celcius. Suhu bilik boleh dikawal oleh pengguna supaya keadaan bilik tidak terlalu sejuk atau panas (litar PIC boleh ditambah baik dengan meletakkan keypad bagi pengguna memasukkan suhu minimum/maksimum).

Disamping itu diharapkan dapat menjimatkan bil tenaga yg perlu dibayar (belum diuji dengan aircond sebenar). Sekiranya aircond dihidupkan terlalu lama pada satu keadaan suhu yg tetap maka bil yg perlu dibayar adalah agak tinggi. Utk aircond 1H/P (746W), jika dihidupkan pada suhu tetap 22 darjah celcius, compressor aircond perlu senantiasa memastikan suhu bilik tersebut adalah 22 darjah celcius. Dengan mengawal suhu antara 23 hingga 28 darjah celcius diharapkan compressor tidak perlu sentiasa hidup, maka tenaga elektrik dapat dijimatkan.

Pengiraan bil elektrik adalah berdasarkan kWh/month dimana kadar utk 200kWH pertama di Malaysia adalah RM 0.216, kadar ini akan meningkat sekiranya pengguna menggunakan lebih drpd 200kWh sebulan.

Contoh pengiraan utk 1 aircond 1H/P jika menggunakan aircond selama 6 jam sehari selama sebulan: Bilangan tenaga digunakan = 0.746kW * 6 hour * 30 hari = 134.28 kWh/month
Jumlah bil = 134.28 * RM 0.216 = RM 29.00

Mengambil kira penjimatan purata jika menggunakan sistem kawalan relay (sekitar 4 jam sehari) selama sebulan :
Bilangan tenaga digunakan = 0.746kW * 4 hour * 30 hari = 89.52 kWh/month
Jumlah bil = 89.52 * RM 0.216 = RM 19.34

Dijangkakan pengguna dapat menjimatkan hampir RM 10 utk sebulan jika menggunaka 1 aircond 1H/P. Bayangkan jika menggunakan 2 atau lebih aircond.

Selain aircond, projek ini juga boleh diaplikasikan utk mengawal kipas penyedut udara (air ventilation fan) bagi dapur.


Project 17 : GPS VB6 Google Map

SKGPS-53 GPS Module

System test

NMEA format data

Visual basic and google map
 
Video on demand

Description

GPS is a system used to monitor or locate any positon in the world based on a set of specified data. Generally it is widely used in car navigation, speed coordination and portable navigation system. A GPS module basically produces current date and time based on UTC and current position based on latitude and longitude. These datas might be presented on computer screen using some special software available in market. But here we use PIC microcontroller and visual basic to process and plot these data on a google map.

The NMEA protocol is a standard format to obtain UTC time,date, latitude, longitude etc. Two standard cords produced from this protocol are $GPGGA and $GPRMC. In this project, the NMEA datas are processed and displayed in LCD showing the latitude and longitude. They are linked to visual basic and google map to plot the real location using web browser command. This project becomes more valuable if it is added with GSM modem so that the location may be sent to customer directly via cellphone.

Prinsip operasi

Sebuah projek menggunakan GPS(Global Positioning System) dari Cytron SKGPS-53 utk memaparkan/memeta koordinat atau lokasi. Ia juga boleh digunakan sbg sistem navigasi kenderaan, peranti navigasi bolehubah dan utk tujuan pemasaan. Kebiasaannya kita akan dapat dua data utama dr modul GPS iaitu waktu dan tarikh semasa berasaskan Coordinated Universal Time (UTC) dan juga koordinat kedudukan semasa berasaskan  latitude dan longitude. Kemudian kita boleh menghubungkan GPS kepada PC/laptop untuk memaparkan data2 ini menggunakan PIC dan LCD. Jenis data2 ini adalah berasaskan protokol NMEA (National Marine Electronics Association) format standard. Maka kita perlulah tahu utk menganalisisnya untuk mendapatkan masa UTC, tarikh, latitude, longitude dan sebagainya. Gambar di atas menunjukkan paparan yg akan keluar dr GPS iaitu mesej jenis $GPGGA dan $GPRMC.

Dalam projek ini, koordinat GPS dalam bentuk data2 NMEA dipaparkan pada LCD. Menggunakan perisian Visual Basic data2 tersebut ditukarkan kepada nilai yang mudah dibaca mewakili latitude dan longitude. Data2 ini kemudian diprogram dalam VB6 untuk dipaparkan pada Google Map berasaskan kedudukan koordinat semasa. Menggunakan aturcara web browser, laman web Google Map diedit utk membolehkan data dari PIC dihantar terus ke alamat ini. Hasilnya kedudukan latitude dan longitude dipaparkan pada Google Map.
Projek ini akan dinaiktaraf dgn menambahkan GSM modem sebagai contoh utk membuat aplikasi sistem navigasi kenderaan. Pengguna akan sentiasa dpt memantau kedudukan semasa kenderaan mereka dan ia amat bermanfaat sbg satu tambahan kpd sistem sekuriti bg kenderaan.

Project 16 : Mentor Robot

Left side view
Right side view
Motor driver circuit
Visual basic SCADA interface video

Description

Mentor robot is actually outdated. But for some purpose, it can be modified to do some simple jobs. Some may use it as a demo robot in school/university. The pictures above show how we can control the mentor robot using computer interface. Visual basic software is used as SCADA system to get data send from robot or send the data from user back to robot meaning that we can build 2-way communication system.

This old robot has 5 DOF with 1 gripper. It uses DC motor to move and each motor is attached with a potentiometer that can be used to send feedback data (motor position). This is not an accurate way to sense motors position but it may help. PIC mictrocontroller is programmed to read the position data from robot and receives commands from visual basic. It is between computer keyboard and motor. Motor driver L293/L298 may drive the robot right or left, forward or backward, up or down. 

Prinsip operasi

Sebuah projek robotik yang dikawal oleh keypad/komputer. Robot ini dari jenis picking robot utk mengambil dan meletakkan item pada lokasi yg boleh dikawal menggunakan komputer. Robot ini mempunyai  5 DOF(Degree of freedom) iaitu 5 paksi yg boleh dikawal oleh motor DC. Program PIC dibangunkan utk membaca kod keypad/komputer dan menghantar data ke litar driver motor yg telah dibina. Dengan menekan button2 yg telah diprogram, robot ini boleh dikawal utk fungsi pick and place item2 tertentu.

Jenis driver yg digunakan adalah L293D/L298 utk memacu motor secara forward/reverse atau atas/bawah atau kiri/kanan. Program visual basic boleh dibangunkan utk memeta kedudukan semasa robot dan ini memungkinkan robot berfungsi secara automatik (autonomous). Robot juga boleh dikawal dari jauh jika RF transmitter/receiver digunakan ke dlm sistem.

Project 15 : Solar Sliding Autogate System

 24V DC motor

Original controller

Controller after modification

Solar battery, controller and door gate

Description

Generally an autogate system is installed at home and powered by domestic wall plug at 240Vac. With some modification it can be powered with solar power as long as it has a backup battery. The backup battery is rated at 12Vdc but the motor used in this system normally operate at 24Vdc. With 12Vdc battery, the opening gate process runs at half of the maximum speed and quite slower. If we wish to run at maximum speed, the 24V system is advised to be used.

Solar power can be used to power the system. The size of the solar system can be 12Vdc or 24Vdc. To use 24Vdc, we need to alter the existing controller. To use additional remote controller, we need to build an interfacer board to trigger the existing controller. Basically, some external ports are provided for us to interface the system with remote or RFID reader/tag. 
Prinsip operasi

Sebuah projek pintu gate automatik menggunakan tenaga elektrik/solar. Kebiasaannya tenaga elektrik biasa 240V digunakan dan bateri digunakan sebagai backup kpd sistem. Namun utk sistem ini, tenaga adalah 100% drpd solar digunakan utk mengecas bateri 12V, 7Ah. Bateri yg dipasang disarankan pd kadaran Ah lebih tinggi misalnya 20Ah untuk memastikan sistem senantiasa beroperasi lancar dalam keadaan mendung/hujan berterusan.

Sistem asal telah dimodifikasi dgn menambahkan RF receiver utk membolehkan pengguna mengakses menggunakan remote lain selain yg dibekalkan. Ini boleh membantu pengguna yg acapkali kehilangan remote lama dan sukar utk membuat tempahan menggantikannya. Selain itu sistem boleh diupgrade menggunakan RFID reader/tag.

Project 14 : Incubator System

Bulb mounting

 Solar incubator

 Early test

 Finished prototype

Test sample

Temperature indicator

Description

An incubator is used to incubate chicken/quail eggs for breeding process. An icubator must have filament lamps and a controller used to control the incubation temperature. The heat generated from filament lamps must be around 38-39 degree celcius so that the process works perfectly. A PIC controller is programmed to control the relay that turns on and off the AC supply connected to the filament lamps. An accurate programmable temperature sensor LM35D is commonly used for this purpose. LCD will indicate the current temperature and the system status.

Prinsip operasi

Sebuah projek inkubator untuk menetaskan telor puyuh/ayam. Mentol lampu digunakan dr jenis filamen (menghasilkan haba yg panas) pada kadaran 5W sebiji. Untuk menghidupkan mentol, litar PIC digunakan untuk mengawal on dan off relay yg menyambungkan mentol dan bekalan AC 240V. Temperature sensor LM35D mengesan suhu didalam inkubator, ia diprogram dan LCD memaparkan suhu tsbt. Suhu penetasan yg sesuai adalah sekitar 38-39 darjah celcius. Julat suhu yg sesuai sangat perlu utk membolehkan telor menetas dgn sempurna.

Project 13 : Solar Home Lighting System

 Solar Panel 70W

5W LED Downlight Type A ( 240Vac/12Vdc)

 5W LED Downlight Type B ( 240Vac/12Vdc)


 DC 12V,15W CFL Type Spiral

  DC 12V,15W CFL Type Kalimantang

 Solar battery charger and batteries

LEDs light up during testing

Solar panel on the roof

Descriptions:

This a solar based project. A solar home system is part of a green home system incorporating solar panels, controller and loads. Loads vary from downlight, LED lights, CFL, autogate system etc. Basically the solar home system is rated at 12 V system because most of loads operate at this voltage. Even a water pump may be powered by solar panel if it has the same rating.

To install a solar system at home, you need to invest a bit large amount of money during early setup. This includes the cost of solar panels,controllers and batteries. Although it is very costly, you can get back your money, pay back period or return of investment (ROI) in 3-5 years depends on the size you install the system. The solar panels may lasting up to 25-30 years if they are maintained well while batteries need to be changed every 2-3 years.

The LED light is highly recommended as it has a very good lifetime period. Some of them may last up to 10000 hours of operating time. In addition, it suits with the solar panel voltage. Using LED also reduce the number of power required to light up a room. Let say previously you used 2 CFL lights rated at 15W (total power = 30W). You should try change to 2 LED lights rating at 9W (18W), you will get the same number of light intensity (counted in Lumen). The saving is around 12W.

Prinsip operasi

Sebuah projek pencahayaan lampu menggunakan tenaga solar utk aplikasi di kediaman/pejabat/pondok....Sesuai utk diaplikasikan dikawasan bandar(urban) dan pendalaman (remote area) jika bekalan TNB tidak dpt dicapai. Terdapat kepelbagaian jenis lampu dari jenis downlight/kalimantang dan teknologi dari jenis LED/CFL boleh digunakan bagi sistem solar. Kebiasaannya sistem LED dipilih kerana lampu dan cahayanya lebih cantik dan menggunakan kuasa watt (P) lebih rendah berbanding CFL utk mendapatkan keamatan cahaya yg sama. Keamatan cahaya diukur dlm unit Lumen menggunakan meter jenis Luxmeter. Untuk mod pembacaan buku unit Lumen sekitar 200 cukup utk kecerahan diperlukan sesuai dgn yg diperlukan oleh mata manusia.

Jika menggunakan lampu LED, jenis sistem boleh dipilih samada berasaskan 240Vac (talian biasa rumah) atau 12Vdc( sistem solar panel). Jika sistem solar panel dipilih, pengguna perlu mempunyai tambahan kepada sistem iaitu solar charge controller dan bateri drpd jenis SLA (seal lead acid) atau Gel atau Lithium Ion....Kos permulaan bagi sistem solar agak mahal namun pengguna boleh mendapatkan keuntungan slps tempoh pay back period (PBP) atau return of investment (ROI) mereka bergantung kepada saiz sistem yang dipasang. Kebiasaannya selepas 5 tahun. Namun begitu solar panel mampu bertahan sehingga 25-30 tahun dan bateri hanya perlu ditukar setiap 2-3 tahun.

Memandangkan ketahanan lampu LED melebihi drpd jangkaun nilai pelaburannya, sistem ini lebih praktikal dipasang dengan solar panel. Sebagai contohnya kita memerlukan 2 biji lampu LED pada kadaran 9W utk sebuah bilek, kecerahannya akan bersamaan dgn 2 biji lampu CFL biasa pada kadaran 15W. 

Project 12 : Lab Attendance SCADA System

System setup

Visual basic program

Visual basic SCADA interface

Excel SCADA interface

Access SCADA interface

Video on demand

Descriptions:

A system to record the attendace of lab/class student based on RFID reader. The reader sends the student ID number to PIC microcontroller. From PIC, the data is processed before being sent to a SCADA software. The SCADA is built based on Visual Basic software. The recorded IDs are shown on a computer screen and save these IDs into microsoft excel as a database. 

Prinsip operasi

Sebuah projek yg digunakan untuk merekod kehadiran pelajar ke kelas/makmal menggunakan kad RFID. Pelajar perlu menyentuh kad mereka pada reader yg disediakan. Reader akan menghantar ID pelajar tersebut ke PIC microcontroller. Dari PIC data akan dihantar ke sistem SCADA yg dibina menggunakan perisian visual basic. Perisian telah diprogram untuk memaparkan paparan SCADA pada komputer dan menyalin rekod kehadiran kedalam file Microsoft Excel. Setiap data kehadiran akan direkod dan dikemaskini secara automatik.

Program database yg boleh digunakan adalah Microsoft Excel (Mudah), Acces (Medium) dan MySQL (kompleks). Program2 ini bole diakses dan diubahsuai berpandukan perisian SCADA yg telah dibangunkan. 

Project 11 : Solar Parking System

Complete system installation

Solar panels

Batteries storage

PIC controller and solar charger

Controller casing

In campus bulletin

Descriptions:

A solar parking system is actually a 100%  stand alone solar powered system. This means that no power from grid needed to power it up. The system allows only authorized users to enter the parking area. The acces card (RFID) or remote controller can be used to trigger the barrier up. High current DC motor is controlled by a PIC board to lift up or down the barrier. The first board uses 24V battery system. Another PIC board is used to receive data from RFID/remote controller before triggering the first board. This board uses nominal 12V battery system.

The solar power taken from sunlight is charged into AGM batteries so that the system may run day and night and may lasting up to 3-4 days if no sunlight detected. This system comes together with a protection circuit using an ultrasonic sensor in case any car stop below the barrier.

Prinsip operasi

Sebuah projek yg digunakan untuk membenarkan akses kepada sistem parking. Akses adalah melalui kad/tag RFID atau kad Touch N Go (TnG) utk mengawal palang seperti di lebuhraya PLUS. Pengguna juga boleh mengakses menggunakan remote control yg diupgrade dr sistem asal. RFID reader digunakan bersama high current DC motor driver dan litar PIC utk mengawal perjalanan sistem. Bekalan kuasa adalah 100% dari tenaga solar yg digunakan utk mengecas bateri. Sistem menggunakan dua controller berlainan, satu utk megawal litar utama motor dan satu lagi litar kawalan rfid/remote control. Litar utama berasaskan 24V manakala litar kedua 12 V. Oleh itu sebanyak 3 solar panel,3 bateri dan 2 charger digunakan.

Sistem turut dilengkapi sejenis sensor ultrasonic sbg ptotection system. Sekiranya semasa palang sedang turun dan kereta masih berada/terberhenti di bawah palang, sensor ini akan menghantar data ke PIC utk menaikkan semula palang. Rekabentuk stand alone ini telah dikira utk membolehkan sistem beroperasi berterusan selama 4-5 hari walaupon keadaan hujan/mendung dialami dlm tempoh tersebut.  

Project 10 : Industrial motor RPM Counter

Controller

System setup

Sensor installation

Video on demand
Descriptions:

This project has been awarded gold medal in ITEX convention. A project to test the reliability(wearness) of mechanical piston when it is attached to a car model. The piston is attached to a 3-phase induction motor so that the motor can slide the piston horizontally to the tested surface. PIC microcontroller board allows the user to key in the number of rotation needed by the piston using a keypad interfacer board.

The rotation number  and the speed in RPM are displayed on LCD. To on and off the induction motor, a relay board is used. Every turns counted by an infrared sensor, the data is sent to PIC for calculation. The relay will be turned off when the counter reaches the number specified by user. Thus is stops the motor. A buzzer sounds a "beep" 3 times to alert the user if the rotation cycle is achieved. 

Prinsip operasi

Projek ini telah memenangi pingat emas di ITEX (Innovation and Technology Excibition) May 2013 dan perak pada PENCIPTA Oktober 2013. Satu pencapaian yang membanggakan bagi peserta yang terlibat. Sebuah projek yg digunakan untuk menguji ketahanan elemen piston mekanikal(wearness). Elemen piston disambungkan kpd motor  induksi 3 fasa membolehkan ia diputarkan utk menguji ketahanannya terhadap kehausan geseran (wear). Program PIC dibangunkan bg membolehkan pengguna memasukkan bilangan putaran yg dikehendaki (contohnya 18000 pusingan) menggunakan keypad. Bilangan pusingan akan dipaparkan pd LCD beserta halajunya dlm RPM (revolution per minute). Arahan dibaca oleh PIC mengarahkan driver motor dan bekalan supply ke motor dihidupkan menggunakan relay. Setiap pusingan motor dibaca oleh infrared sensor dan menghantar data ke PIC. Apabila bilangan putaran telah mencapai nilai yg dikehendaki oleh pengguna, PIC arahkan bekalan supply dan driver motor td dimatikan. 3 kali bunyi dr buzzer "beep" akan kedengaran membolehkan pengguna alert bahawa kitaran pusingan sudah tercapai.

Project 9 : Electric Vehicle


Electric bicycle model

Electric car model
Speed and odometer

Inside controller box

Video on demand
Descriptions:

It is a green project using an incentive grant project to design an electric bicycle for testing and running. It consists of 48V BLDC motor, 12V batteries (4 in series), the motor contoller and the PIC microcontroller. The input for BLDC is 48 Vdc battery. The motor controller converts this voltage to a powerful 3-phase AC power (about 500W) for driving BLDC using an inverter circuit. The BLDC motor has 3 hall sensors built inside it to sense the motor position.  

A hand throttle and hand brake is used to control the speed. The maximum speed is 35km/h. With 12V,7Ah batteries, you may drive the bicycle for half an hour before need to be charged again. The charging process is based on 48V-based voltage using solar panel (solar charging station at 52V, 3 units of panels) or may be plugged through home socket output (240Vac). The motor has special features built using PIC microcontroller i.e speedometer and odometer. It is also equipped with a smart protection system using a gyrometer to avoid the system from being stolen.

Prinsip operasi

Sebuah projek membangunkan sebuah basikal elektrik. Sistem menggunakan voltan 48V, motor jenis BLDC(brushless DC motor) yg mana inputnya bekalan DC (bateri 48V) ditukar kpd AC 3 fasa utk menghasillkan power yg cukup besar (sekitar 500W bg menggerakkan penunggang). Sistem dilengkapi dengan sebuah meter indikator digital yg dibina berasaskan PIC utk memaparkan status kenderaan (STOP, Gear 1,2,3,4), speedometer (km/h) dan mileage (m). Sistem juga dibina alat pencegah kecurian berasaskan accelerometer dan alat ini dikawal oleh remote control.

Throttle tangan digunakan utk memecut kenderaan. Kelajuan maksimum direkodkan 35km/h. Ketepatan halaju dan mileage telah disahkan dgn penggunaan GoogleEarth bg merekod track perjalanan. Sistem bekalan bateri 48V dicas menggunakan tenaga solar (charging station). Juga boleh menggunakan plug dr rumah (240V) dan memerlukan penukar voltan turun.