Upload
solana
View
29
Download
0
Tags:
Embed Size (px)
DESCRIPTION
Smart-grid Interface with Photovoltaic Installation – Phase 2 PP-01. Team members: Matt Koresh Ivan Mills Matt Martin Advisor: Dr. Aliprantis. - PowerPoint PPT Presentation
Citation preview
Smart-grid Interface with Photovoltaic Installation – Phase 2
PP-01Team members:
Matt KoreshIvan Mills
Matt Martin
Advisor:
Dr. Aliprantis
Problem StatementOur group is tasked with the completion of previous work on a PV panel. The panel must be installed on top of Coover Hall and must incorporate smart grid technology.
Our client has expressed a need for a wireless device to send power data between a solar inverter and a computer interface.
Our client has expressed using new Zigbee technology to be incorporated in our design.
Solution
We built upon small amounts of previous work laid out by the previous group and began a design for the installation
We designed a current measuring circuit and incorporated a wireless Zigbee device in order to transmit data to a computer.
Previous PhaseDocumentation on PV panel
PV panel and cables
Due to lack of testing and documentation reverse engineering the inverter could prove futile.
System Diagram
Measurements and Data transfer
Current will be measured from Inverter output
Power will be calculated from known grid Voltage and Current measurements
Data measurements will be sent over Zigbee network to computer with Software interface to display results
Schematic of Final Board
Tit le
S ize D o c u m e n t N u m b e r R e v
D a t e : S h e e t o f
<D o c > <R e v C o d e >
<Tit le >
B
1 1F rid a y , N o v e m b e r 2 0 , 2 0 0 9
0
J 1H e a d e r7
1 2 3 4 5 6 7
R 5
1 6 0 k
R 6
1 6 0 k
0
C 11 0 0 n
0
R 14 . 7 k R 2
4 7 0
U 11 8 F 4 6 2 0
M C L R / V P P / R E 31
R A 0 / A N 02
R A 1 / A N 13
R A 2 / A N 2 / V R E F -/ C V R E F4
R A 3 / A N 3 / V R E F +5
R A 4 / T0 C K I / C 1 O U T6
R A 5 / A N 4 / S S / H L V D I N / C 2 O U T7
R E 0 / A N 5 / R D8
R E 1 / A N 6 / W R9
R E 2 / A N 7 / C S1 0
V D D1 1
V S S1 2
O S C 1 / C L K I / R A 71 3
O S C 2 / C L K O / R A 61 4
R C 0 / T1 O S O / T1 3 C K 11 5
R C 1 / T1 O S I / C C P 21 6
R C 2 / C C P 1 / P 1 A1 7
R C 3 / S C K / S C L1 8
R D 0 / P S P 01 9
R D 1 / P S P 12 0
R D 2 / P S P 22 1R D 3 / P S P 32 2R C 4 / S D I / S D A2 3R C 5 / S D O2 4R C 6 / TX/ C K2 5R C 7 / R X/ D T2 6R D 4 / P S P 42 7R D 5 / P S P 5 / P 1 B2 8R D 6 / P S P 6 / P 1 C2 9R D 7 / P S P 7 / P 1 D3 0V S S _ 13 1V D D _ 13 2R B 0 / I N T0 / F L T0 / A N 1 23 3R B 1 / I N T1 / A N 1 03 4R B 2 / I N T2 / A N 83 5R B 3 / A N 9 / C C P 23 6R B 4 / K B I 0 / A N 1 13 7R B 5 / K B I 1 / P G M3 8R B 6 / K B I 2 / P G C3 9R B 7 / K B I 3 / P G D4 0
0
3 . 3 V
3 . 3 V
0
S W 2
S W P U S H B U TTO N
S W 1
S W P U S H B U TTO N
0
U 4
XB 2 4 -A W I -0 0 1
V C C1
D O U T2
D I N / C O N F I G3
D O 8 *4
R E S E T5
P W M 0 / R S S I6
P W M 17
[ re s e rv e d ]8
D TR / S L E E P _ R Q / D l89
G N D1 0
A D 4 / D I O 41 1C TS / D I O 71 2O N / S L E E P1 3V R E F1 4A s s o c ia t e / A D 5 / D I O 51 5R TS / A D 6 / D I O 61 6A D 3 / D I O 31 7A D 2 / D I O 21 8A D 1 / D I O 21 9A D 0 / D I O 02 0
L P 2 9 8 0 A I M 5 -3 . 3U 2
V in1
G N D2 O N
3
A D J4
V o u t5
0
3 . 3 V
C 21 e -6 C 3
3 . 3 e -6
V C C
00
0
0
N e g _ V C C
U 3 D
L M 3 2 4
+1 2
-1 3
V+
4V
-1
1
O U T1 4
U 3 A
L M 3 2 4
+3
-2
V+
4V
-1
1
O U T1
U 3 B
L M 3 2 4
+5
-6
V+
4V
-1
1
O U T7
U 3 C
L M 3 2 4
+1 0
-9
V+
4V
-1
1
O U T8
R 3
1 k
R 7
1 2 0 k
R 91 k
R 8
1 2 0 k
V C C
D 1
1 N 4 0 0 6
V C C
D 2
1 N 4 0 0 6
C 4
1 0 0 e -1 2
C 5
1 e -6
V C C
0
V C C
3 . 3 V
R 4
1 k
N e g _ V C C
N e g _ V C C
N e g _ V C C
3 . 3 V
N e g _ V C C
L 1C T C R S 8 6 2 0 -1 0 0 0
J 2
C G rid L a t c h
12345
Microcontroller: PIC18F4620
-10-Bit A/D Converter(up to 13 channels)-Internal Oscillator-USART interface-ICSP (In-Circuit Serial Program)-ICD (In-Circuit Debug)
PIC Programming
MPLAB from Microchip used to programAssembly Code Utilized
◦3 basic functions: Analog to Digital Conversion of input voltage
signal Serial Communication Interface 30 second timer to repeat main functions
PIC ProgrammingList P = PIC18F4620 #include<P18F4620.INC>
;-------------------------------------------------------------------------------;;------ This program is implementing USART on a PIC18F4620 ---------------------;;------ OSC = INT RC-Port on RA6, Port on RA7-----------------------------------;;------ Fosc = 8MHz (internal)--------------------------------------------------;
;------Initialization Routine----------------------------------------------------;Init:
;----------Set Oscillator----------;banksel OSCCONmovlw b'01110000' ;set frequency to 8MHzmovwf OSCCON
;------Configure Input/Output------;;Clear PORTAbanksel PORTA ;Select the bank that PORTA is locatedclrf PORTA ;Clear the Port just in case erroneous
;Configures Pin AN0 as an A/D inputbanksel TRISA ;Select the bank that TRISA is locatedMOVLW b'00000001' ;move binery number to w-registerMOVWF TRISA ;move value from w-reg to TRISA - this makes pin AN0 an input for ADC later
;------ADC Init------;;ADCON0: Controls operation of A/D modulebanksel ADCON0 ;Select the bank that ADCON0 is locatedmovlw b'00000001' ;bit selects AN0 as A/D channel, A/D module enabled, A/D conversion to idlemovwf ADCON0
;ADCON1: Configures functions of port pinsbanksel ADCON1 ;Select the bank that ADCON1 is locatedmovlw b'00000000' ;sets Vref- to Vss, Vref+ to Vdd and AN0 as analog inputmovwf ADCON1
;ADCON2: Configures A/D clock source, programmed acquisition time and justificationbanksel ADCON2 ;Select the bank that ADCON2 is locatedmovlw b'10101000' ;A/D Result right-justifiedmovwf ADCON2
;------Configure USART Communication------;banksel TRISC ;select bank holding TRISCmovlw b'11000000' ;Program RC7/RX pin and RC6/TX pin as directed by datasheet (pg 201)movwf TRISC ;
banksel SPBRG ;Select bank holding SPBRGmovlw b'00001100' ;decimal value of 12 (binary 00001100) is required value for 9600 baud ratemovwf SPBRG ;
PIC Programming (cont)banksel RCSTA ;select bank holding RCSTAmovlw b'10000000' ;Enabled transmission, 8 data bits. SPEN bit (RCSTA<7>=1)movwf RCSTA ;USART ready to transmit and recieve data
banksel TXSTA ;select bank holding TXSTAmovlw b'10000000' ;Transmit enabeled bit TXEN(TXSTA<5>) set low(disabled) for now, Asynchronous mode low speed(BRGH=0)movwf TXSTA ;
goto Main ;force program to go to Main loop after initialization
;--------------------------------------------------------------------------------;;--------------------------------------------------------------------------------;
;;------Main Routine--------------------------------------------------------------;Main:
;------ADC------;\
;Clear ADC Output registers first to ensure correct measurementbanksel ADRESH ;Select the bank that ADRESH is locatedclrf ADRESH ;clear output highbanksel ADRESL ;Select the bank that ADRESL is locatedclrf ADRESL ;clear output low
;Actually Perform ADCbanksel ADCON0 ;Select the bank that ADCON0 is locatedbsf ADCON0, GO_DONE ;sets GO_DONE bit high enabling ADCbtfsc ADCON0, GO_DONE ;checks GO_DONE, if low the next line is skippedgoto $-1 ;this is a loop, if GO_DONE is low (ie. ADC is complete)
program returns to previous line
;------Send data in A/D registers to Serial------;;---Note:Data to transmit must be in W register--;
TXDATA:;---Send ADRESH-----;
banksel TXSTAbsf TXSTA,TXEN ;Transmit enabled bit TXEN(TXSTA<5>) set, this enables
transmission
banksel ADRESHmovf ADRESH, W ;put data located in ADRESH into working registrybanksel TXREGmovwf TXREG ;Store ADRESH data in TXREG initializing transmission
PIC Programming (cont)movlw b'10101010' ;waste time in order to allow TRMT (status bit) to change so we can pole itmovlw b'11010101' ;waste more time
WaitHere btfss TXSTA,TRMT ;transmit complete if bit TRMT(TXSTA<1>) is highgoto WaitHere ;sending not
done, go back through loop
banksel TXSTAbcf TXSTA,TXEN ;clear transmit
enabled bit when finished
;---Send ADRESL-----;banksel TXSTAbsf TXSTA,TXEN ;Transmit enabled bit TXEN(TXSTA<5>) set, this enables
transmission
banksel ADRESLmovf ADRESL, W ;put data located in ADRESL into working registrybanksel TXREGmovwf TXREG ;Store ADRESL data in TXREG initializing transmission
movlw b'10101010' ;waste time in order to allow TRMT (status bit) to change so we can pole itmovlw b'11010101' ;waste more time
WaitHere2 btfss TXSTA,TRMT ;transmit complete if bit TRMT(TXSTA<1>) is highgoto WaitHere2 ;sending not
done, go back through loop
banksel TXSTAbcf TXSTA,TXEN ;clear transmit
enabled bit when finished
;------Wait 30's to take another measurement and send data------;;---------------------------Delay Loop--------------------------;;-------Instructions occure every 1/f --------------------------;
;This code segment defines how many times to run the delay loopmovlw 0xFF ;Put the value of 85h in the working register (85h is a value)movwf 09h ;Move this value to the 09h register (09h is a register)
COUNT2 equ 09h ;09h defines how many times to run COUNT1 delay loop
movlw 0xFF ;Put the value of 85h in the working register (85h is a value)movwf 07h ;Move this value to the 09h register (09h is a register)
COUNT3 equ 07h ;09h defines how many times to run COUNT1 delay loop
PIC Programming (cont)LABEL3:
movlw 0xFF ;Put the value of FFh (255) in the working register (FFh is a value)
movwf 08h ;Move this value to the 08h register (08h is a register)COUNT1 equ 08h ;Now COUNT will equal the value 85hLABEL DECFSZ COUNT1,1;Decrease COUNT1 by 1 from 255, if COUNT1=0 skip next line and continue
goto LABEL ;COUNT1 is not 1 therefore go to LABEL
DECFSZ COUNT2,1 ;Decrease COUNT2 by 1 from 09h, if COUNT2=0 skip next line and continuegoto LABEL3 ;if COUNT2 is not 0 therefore re-run delay loop another time
DECFSZ COUNT3,1 ;Decrease COUNT2 by 1 from 09h, if COUNT2=0 skip next line and continuegoto LABEL3 ;if COUNT2 is not 0 therefore re-run delay loop another time
goto Main
;--------------------------------------------------------------------------------;
end
Wireless Communication
Wireless communication utilizes Zigbee protocol
Zigbee:a) Was a design requirementb) Requires minimal powerc) Easy to used) Is becoming a standard
Zigbee Module•Includes MAC address•Straight-forward interface•More standardized than other modules
Network Topology Due to low power of Zigbee modules a mesh network is utilized to increase
reach of our network We are planning ahead for an increased number of devices in the future Zigbee modules work with other device brands
Installation Location
Installation (cont)
Equipment
Standards
Expandability
Serial Communications
Built in Java
Event Driven
USB to Serial
Testing Communications
PC Settings
Communications Check
Modem Configuration
Data Storage
Relay data to a MySQL database
Programs Needed
PHP/Script Interaction
Expandability
Visualization
Google API
Select and Zoom Feature
Project Evolution
Prototype Final Product
Project Evolution
Prototype Final Product
Sources
http://www.wirelessnetdesignline.com/173500576 http://www.microchip.com http://www.digi.com http://www.microwatt.co.uk/images/zigbee_topology.png
Questions?