-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCatcher.cpp
More file actions
executable file
·50 lines (38 loc) · 1.13 KB
/
Catcher.cpp
File metadata and controls
executable file
·50 lines (38 loc) · 1.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
/*----------------------------------------------------------------------------*/
/* Copyright (c) TechForKid 2014. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in $(WIND_BASE)/WPILib. */
/*----------------------------------------------------------------------------*/
#include "Catcher.h"
/* --------------------------------------------------------------------------- */
// Constructors
Catcher::Catcher() : m_SolenoidCatcher(C_cRIOPneumaticModuleNumber, C_SolenoidWings)
{
m_SolenoidCatcher.Set(false);
m_StateWings = false;
}
Catcher::~Catcher()
{
}
/* --------------------------------------------------------------------------- */
// Methods
void Catcher::GestionWings()
{
m_SolenoidCatcher.Set(m_StateWings);
}
bool Catcher::GetWingsState()
{
return m_SolenoidCatcher.Get();
}
void Catcher::OpenWings()
{
m_StateWings = true;
}
void Catcher::CloseWings()
{
m_StateWings = false;
}
void Catcher::ToggleWings()
{
m_StateWings ^= 1;
}