1 // ============================================================================= 2 // PROJECT CHRONO - http://projectchrono.org 3 // 4 // Copyright (c) 2014 projectchrono.org 5 // All right reserved. 6 // 7 // Use of this source code is governed by a BSD-style license that can be found 8 // in the LICENSE file at the top level of the distribution and at 9 // http://projectchrono.org/license-chrono.txt. 10 // 11 // ============================================================================= 12 // Authors: Radu Serban, Michael Taylor 13 // ============================================================================= 14 // 15 // Base class for a continuous band track assembly using a bushing-based web 16 // (template definition). 17 // 18 // The reference frame for a vehicle follows the ISO standard: Z-axis up, X-axis 19 // pointing forward, and Y-axis towards the left of the vehicle. 20 // 21 // ============================================================================= 22 23 #ifndef CH_TRACK_ASSEMBLY_BAND_BUSHING_H 24 #define CH_TRACK_ASSEMBLY_BAND_BUSHING_H 25 26 #include "chrono_vehicle/ChApiVehicle.h" 27 #include "chrono_vehicle/tracked_vehicle/track_assembly/ChTrackAssemblyBand.h" 28 #include "chrono_vehicle/tracked_vehicle/track_shoe/ChTrackShoeBandBushing.h" 29 30 namespace chrono { 31 namespace vehicle { 32 33 /// @addtogroup vehicle_tracked 34 /// @{ 35 36 /// Definition of a continuous band track assembly using a bushing-based web 37 /// A track assembly consists of a sprocket, an idler (with tensioner mechanism), 38 /// a set of suspensions (road-wheel assemblies), and a collection of track shoes. 39 /// This class defines the template for a track assembly using a web modeled as 40 /// multiple rigid segments connected with bushings. 41 class CH_VEHICLE_API ChTrackAssemblyBandBushing : public ChTrackAssemblyBand { 42 public: 43 /// Construct a bushing-based track assembly on the specified vehicle side. 44 ChTrackAssemblyBandBushing(const std::string& name, ///< [in] name of the subsystem 45 VehicleSide side ///< [in] assembly on left/right vehicle side 46 ); 47 ~ChTrackAssemblyBandBushing()48 virtual ~ChTrackAssemblyBandBushing() {} 49 50 /// Get the name of the vehicle subsystem template. GetTemplateName()51 virtual std::string GetTemplateName() const override { return "TrackAssemblyBandBushing"; } 52 53 /// Get the number of track shoes. GetNumTrackShoes()54 virtual size_t GetNumTrackShoes() const override { return m_shoes.size(); } 55 56 /// Get a handle to the specified track shoe subsystem. GetTrackShoe(size_t id)57 virtual std::shared_ptr<ChTrackShoe> GetTrackShoe(size_t id) const override { return m_shoes[id]; } 58 59 protected: 60 ChTrackShoeBandBushingList m_shoes; ///< track shoes 61 62 private: 63 /// Assemble track shoes over wheels. 64 /// Return true if the track shoes were initialized in a counter clockwise 65 /// direction and false otherwise. 66 virtual bool Assemble(std::shared_ptr<ChBodyAuxRef> chassis) override final; 67 68 /// Remove all track shoes from assembly. 69 virtual void RemoveTrackShoes() override final; 70 }; 71 72 /// @} vehicle_tracked 73 74 } // end namespace vehicle 75 } // end namespace chrono 76 77 #endif 78