The program on the EV side begins by specifying a baud rate for communication between the Arduino and ZigBee. It then opens an Excel file upon receiving an SPXL command to log sensor data from the voltage and current sensors for 25 seconds, transmitting it wirelessly to the control station ZigBee. The EV ZigBee waits for instructions, activating V2G services if the command is "aaa" or G2V charging services if the command is "bbb".
The program on the control station side also specifies a baud rate and logs the sensor data received from the EV in an Excel file for 25 seconds. It extracts the SoC from the data, compares it to a 50% threshold,
The program on the EV side begins by specifying a baud rate for communication between the Arduino and ZigBee. It then opens an Excel file upon receiving an SPXL command to log sensor data from the voltage and current sensors for 25 seconds, transmitting it wirelessly to the control station ZigBee. The EV ZigBee waits for instructions, activating V2G services if the command is "aaa" or G2V charging services if the command is "bbb".
The program on the control station side also specifies a baud rate and logs the sensor data received from the EV in an Excel file for 25 seconds. It extracts the SoC from the data, compares it to a 50% threshold,
The program on the EV side begins by specifying a baud rate for communication between the Arduino and ZigBee. It then opens an Excel file upon receiving an SPXL command to log sensor data from the voltage and current sensors for 25 seconds, transmitting it wirelessly to the control station ZigBee. The EV ZigBee waits for instructions, activating V2G services if the command is "aaa" or G2V charging services if the command is "bbb".
The program on the control station side also specifies a baud rate and logs the sensor data received from the EV in an Excel file for 25 seconds. It extracts the SoC from the data, compares it to a 50% threshold,
1. The program starts from the EV end by specifying a particular baud rate (for both the Arduino and the ZigBee). 2. On encountering the SPXL command (a predefined command configured for launching excel file), the Gobetwino terminal opens the particular excel file located in the link associated with the SPXL command for data logging purposes. 3. The gobetw() function of the program begins and for the next 25 seconds sensor data from both the voltage and the current sensor are read and the voltage and the current SoC of the battery are logged in on the excel file and are also transmitted wirelessly at the same time to the control station ZigBee. 4. The EV side ZigBee transceiver waits for instruction/command from the Control Station. 5. If the command is “aaa”, the V2G services are activated by turning the relay high. 6. Else if the command is “bbb”, G2V services are activated and the EV is instructed to charge its battery pack.
6.3.4 Explanation of the program on Control Station:
1. The program starts on the Control Station end by specifying a particular baud rate (for both the Arduino and the ZigBee). 2. The gobetw() function of the program begins and for the next 25 seconds sensor data transmitted by the EV are logged on in the excel file and stored bitwise in an array. 3. The SPXL command is encountered for the second time. 4. The present value of SoC of the EV battery is extracted from the array and stored in a different array. This array is used to convert the ASCII values to a floating point value of SoC. 5. This floating point value of SoC is compared with the threshold level of 50 percentage points of SoC. 6. If the value is greater than 50, then a message “aaa” is transmitted back to the EV for the activation of V2G services. 7. Else if the value is less than 50, then a message “bbb” is transmitted back to the EV for the activation of G2V services.