• No se han encontrado resultados

LA EVOLUCIÓN Y EL PAPEL DE LA ENSEÑANZA SECUNDARIA EN FRANCIA

In document educacion y sociologia durkheim (página 79-86)

JOAN BORRELL

IV. LA EVOLUCIÓN Y EL PAPEL DE LA ENSEÑANZA SECUNDARIA EN FRANCIA

To ensure uninterrupted power to the Raspberry Pi control system, a backup power source needs to be provided. This subsystem needs to be charged off the vehicles main power circuit, but prevent any components from the main power circuit from drawing power from the backup power source. The Raspberry Pi UPS should also provide a status signal to the Pi regarding the vehicles main power status, so that action can be taken depending on the availability of this source. This would allow the Pi to perform a safe shutdown upon detection that the main power was interrupted. This interruption in main power could be caused by high power draw from system components during operation and can be caused by the activation of the vehicles starter motor or by the main power being switched off.

If the voltage from the main power supply drops, the backup battery should supply the required power to run the switch mode supply. An expected source of power failure is the operation of the starter motor, which is set to run for a maximum of two seconds. As soon as this power failure is detected by the Pi, it checks every second, for a total of three seconds to see if the power has been restored before shutting down. If the power is restored within this three-second window the Pi will not shutdown and resume normal operations. This allows time for the voltage levels to return to normal before shutting down to prevent any unnecessary system shutdowns.

The UPS needs to run the switch mode for a set amount of time after main power has been lost to allow the Pi to safely shutdown. In the event that the Pi needs more time than the fixed time available, due to busy system or data saving, then it should be able to override the automated power off sequence until the Pi is ready to shutdown.

To achieve the required functionality specified above, a simple system was designed and built. This is opposed to purchasing an existing, more expensive system that would be otherwise comparatively complicated and may not offer the same features required for the system.

Initial testing to measure the voltage drop on the main power supply during motor start shows that from an initial battery voltage of 12.6 volts. The battery voltage dropped to

7.74 volts when the starter motor was activated and rose to 11.9 volts over 0.7 seconds after the initial voltage drop. During this testing, it took 1.4 seconds for the motor to start with the voltage across the battery increasing to 13.4 volts charging from the alternator.

6.6.2.1.2.1

UPS System Design

Once the requirements of the UPS system were evaluated, it could be broken down into smaller systems. These included a backup battery, a charging method for the battery backup, a power switching method, timing circuit, main power detection, and a power off override to prevent power switching off.

A sealed lead acid battery was chosen as the backup battery. These batteries while heavy, have high capacity and discharge currents, while proving rugged and reliable, both of which are important qualities for outdoor use in an agricultural environment. To charge the backup battery while preventing the main supply from draining the backup battery, a power diode was used in series between the positive input from mains and the positive terminal of the battery. This keeps the battery charged to the following voltage level Vmain = VBattery + VDiode,

which means that the voltage across the backup battery will always be the main supply voltage minus the voltage drop across the diode. Therefore, when vehicle motor is operating the output of the alternator will keep the battery charged to 12.8-volts.

6.12

While many UPS systems use a microcontroller to monitor and ensure an uninterrupted supply to the system, the circuit designed does it using an analogue timing configuration. This timing method is achieved using a simple Resistor-Capacitor timing circuit, featuring a variable resistor to allow for adjustments in the discharge curve. A diode is included to prevent the capacitor, C1 in Figure 6-36, from discharging back through the main circuit after the input power has failed. The discharge voltage curve is monitored by a LM339 Comparator, which compares the discharge curve to a reference voltage.

The reference voltage is generated from the voltage drop across two diodes operated in a forward bias mode, in conjunction with resistor to limit the current. This gives a reference voltage of 1.2 ± 0.1 volts, which is generated using the backup battery as the voltage source. The comparator also draws its powered from the backup battery. This ensures the comparator remains powered after the mains power has been disconnected. The output of the comparator controls a power MOSFET. This MOSFET switches the power to the switch mode supply.

An override circuit is included to charge the timing circuit form the backup battery. This prevents the capacitor voltage form discharging below the 1.2-volt threshold, preventing the system from powering down. The Raspberry Pi has a set of general-purpose input-output pins (GPIO) that operate 3.3-volt logic level. Therefore, the override circuit must be capable of being driven at this voltage level. This system uses a transistor charge pump to provide 12 volts to charge the timing circuit, and maintain the timing of the analogue circuit, using a 3.3V input from the Raspberry Pi. Main power sensing is achieved using a Zener diode in series with a resistor. This provides a voltage drop of 2.5 volts across the diode that can be detected 3.3-volt Raspberry Pi input pins.

6.6.2.1.2.2

UPS System Testing

To test the circuit designed, individual components of the system was tested to ensure they functioning as expected. During this testing, a problem with the timing circuit was detected, with the circuit maintaining the expected timing. This was caused by the timing capacitor discharging back into the bikes main power circuit. This was due to the diode designed to stop the reverse current flow being damaged during circuit power up. This 1N4148 diode was damaged due to the timing capacitor's current draw, which exceeded the 1N4148s maximum current rating of 450mA (Datasheet within 0).

Due to the extremely high instantaneous current, the capacitor draws from the system on charging, a small resistor, R_Limit in Figure 6-36, was inserted in series in between the diode and the timing circuit. The positioning of this resistor limits the current to the timing capacitor, without affecting the resistance of the timing circuit. Calculating the resistance based on the voltage input from the main power source should not exceed 15 volts, and the current through the 1N4148 Diode should not exceed 450mA, a resistor value of 47Ω was selected. This results in a maximum current of 320mA through the diode.

6.13

Figure 6-36 UPS Circuit Schematic

During testing, the Raspberry Pi would lose power as the input power source was removed, with the power from the UBEC insufficient keep the system running during this switch. The cause of this stemmed from the selected backup battery, and its ability to supply the instantaneous current required supplement from the main system the supply to the UBEC. This problem was solved by increasing the size of the sealed lead acid battery from a 12V 1.2Ah with an initial current of less than 0.36 amperes, to the next available battery which had a 12V 9Ahr rating with an initial current of less than 2.7 amperes.

Figure 6-37 UPS Board

A possibly solution could have been to add a series of capacitors in parallel with the battery, which would increase the effective instantaneous current capacity, as the battery was capable of running the Raspberry Pi. This was not implemented, as there was a larger battery available on site and provided a simpler option, though for cost saving measures, the capacitor option should be investigated in future designs.

Chapter Seven

Software Development

This chapter covers the software developed for this system primarily consisting of hardware programming for the systems control modules, along with the user interface and path finding algorithm implemented on the Raspberry Pi controller.

7.1

Steering Control System

The purpose of the steering controller is to turn the steering mechanism to a specified position and control the linear actuator that engages the steering motor. To control the steering position, the position must be read from the 8-bit encoder with connections to digital and analogue pins outlined in section 5.2.4.

In document educacion y sociologia durkheim (página 79-86)

Documento similar