Permalink
Browse files

solving obscure merge problems

  • Loading branch information...
2 parents 57fdf5f + 0b34f00 commit e252bf598301906f0b15c9bdc85eca36903f1ace Clovis Scotti committed May 18, 2011
@@ -90,7 +90,7 @@ void NPushFootTick::dump_to_xml(QXmlStreamWriter& xml) const
QString NPushFootTick::get_pretty_print() const
{
- return QString("Foot: [%1;%2;%3]")
+ return QString("Foot: [%1;T:%2;H:%3]")
.arg(QString(side))
.arg(QString::number(toes))
.arg(QString::number(heel));
@@ -1,79 +1,79 @@
-/*
- * Copyright (c) 2011 Nokia Corporation
- *
- * This file is part of the Push Snowboarding Project, More info at:
- * www.pushsnowboading.com
- *
- * Author: Clovis Scotti <scotti@ieee.org>
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
-
-#include "pushburtongenericdevice.h"
-
-PushBurtonGenericDevice::PushBurtonGenericDevice(QObject * parent) : QObject(parent)
-{
-}
-
-PushBurtonGenericDevice::~PushBurtonGenericDevice()
-{
-}
-
-void PushBurtonGenericDevice::start_readings()
-{
- if(timerId == 0)
- timerId = startTimer(timerPeriod);
-}
-
-void PushBurtonGenericDevice::stop_readings()
-{
- if(timerId != 0)
- killTimer(timerId);
- timerId = 0;
-}
-
-void PushBurtonGenericDevice::disconnect_from_backend()
-{
-}
-
-bool PushBurtonGenericDevice::subscribesTo(PushBurtonGenericDevice*)
-{
- return false;
-}
-
-bool PushBurtonGenericDevice::subscribesToAny()
-{
- return false;
-}
-
-void PushBurtonGenericDevice::incoming_reading(NPushLogTick *)
-{
-
-}
-
-bool PushBurtonGenericDevice::start_run()
-{
- return true;
-}
-
-
-bool PushBurtonGenericDevice::end_run()
-{
- return true;
-}
+/*
+ * Copyright (c) 2011 Nokia Corporation
+ *
+ * This file is part of the Push Snowboarding Project, More info at:
+ * www.pushsnowboading.com
+ *
+ * Author: Clovis Scotti <scotti@ieee.org>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#include "pushburtongenericdevice.h"
+
+PushBurtonGenericDevice::PushBurtonGenericDevice(QObject * parent) : QObject(parent)
+{
+}
+
+PushBurtonGenericDevice::~PushBurtonGenericDevice()
+{
+}
+
+void PushBurtonGenericDevice::start_readings()
+{
+ if(timerId == 0)
+ timerId = startTimer(timerPeriod);
+}
+
+void PushBurtonGenericDevice::stop_readings()
+{
+ if(timerId != 0)
+ killTimer(timerId);
+ timerId = 0;
+}
+
+void PushBurtonGenericDevice::disconnect_from_backend()
+{
+}
+
+bool PushBurtonGenericDevice::subscribesTo(PushBurtonGenericDevice*)
+{
+ return false;
+}
+
+bool PushBurtonGenericDevice::subscribesToAny()
+{
+ return false;
+}
+
+void PushBurtonGenericDevice::incoming_reading(NPushLogTick *)
+{
+
+}
+
+bool PushBurtonGenericDevice::start_run()
+{
+ return true;
+}
+
+
+bool PushBurtonGenericDevice::end_run()
+{
+ return true;
+}
@@ -1,87 +1,87 @@
-/*
- * Copyright (c) 2011 Nokia Corporation
- *
- * This file is part of the Push Snowboarding Project, More info at:
- * www.pushsnowboading.com
- *
- * Author: Clovis Scotti <scotti@ieee.org>
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see <http://www.gnu.org/licenses/>.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
-
-#ifndef PUSHBURTONGENERICDEVICE_H
-#define PUSHBURTONGENERICDEVICE_H
-
-
-
-#include <QObject>
-#include <QString>
-//#include <QVector>
-#include "npushlogtick.h"
-#include "npushgenreport.h"
-
-/* This is the base class for all devices.
- * This adds to all its subclasses the following functionalities
- * Adds QObject basic functionality for all devices (emit/slots/signals)
- * Periodic timer for sensor pooling (subclasses assign period value to timerPeriod variable)
- * defines the common interface for all sensors
- */
-class PushBurtonGenericDevice : public QObject
-{
- Q_OBJECT
-public:
-
- PushBurtonGenericDevice(QObject * parent = 0);
-
- virtual ~PushBurtonGenericDevice() = 0;
-
- virtual QString get_description() = 0;
-
- virtual void start_readings();
- virtual void stop_readings();
-
- virtual bool is_online() = 0;
-
- virtual void disconnect_from_backend();
-
- virtual bool start_run();
- virtual bool end_run();
-
- virtual bool subscribesToAny();
- virtual bool subscribesTo(PushBurtonGenericDevice* deviceType);
-
-protected:
- int timerId;
- int timerPeriod;
-
-
-
-public slots:
- virtual void incoming_reading(NPushLogTick *);
-
-signals:
- void reading_ready(NPushLogTick *);
-
- void report_ready(NPushGenReport *);
-
- void connected();
- void disconnected();
-};
-
-#endif // PUSHBURTONGENERICDEVICE_H
+/*
+ * Copyright (c) 2011 Nokia Corporation
+ *
+ * This file is part of the Push Snowboarding Project, More info at:
+ * www.pushsnowboading.com
+ *
+ * Author: Clovis Scotti <scotti@ieee.org>
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ *
+ */
+
+#ifndef PUSHBURTONGENERICDEVICE_H
+#define PUSHBURTONGENERICDEVICE_H
+
+
+
+#include <QObject>
+#include <QString>
+//#include <QVector>
+#include "npushlogtick.h"
+#include "npushgenreport.h"
+
+/* This is the base class for all devices.
+ * This adds to all its subclasses the following functionalities
+ * Adds QObject basic functionality for all devices (emit/slots/signals)
+ * Periodic timer for sensor pooling (subclasses assign period value to timerPeriod variable)
+ * defines the common interface for all sensors
+ */
+class PushBurtonGenericDevice : public QObject
+{
+ Q_OBJECT
+public:
+
+ PushBurtonGenericDevice(QObject * parent = 0);
+
+ virtual ~PushBurtonGenericDevice() = 0;
+
+ virtual QString get_description() = 0;
+
+ virtual void start_readings();
+ virtual void stop_readings();
+
+ virtual bool is_online() = 0;
+
+ virtual void disconnect_from_backend();
+
+ virtual bool start_run();
+ virtual bool end_run();
+
+ virtual bool subscribesToAny();
+ virtual bool subscribesTo(PushBurtonGenericDevice* deviceType);
+
+protected:
+ int timerId;
+ int timerPeriod;
+
+
+
+public slots:
+ virtual void incoming_reading(NPushLogTick *);
+
+signals:
+ void reading_ready(NPushLogTick *);
+
+ void report_ready(NPushGenReport *);
+
+ void connected();
+ void disconnected();
+};
+
+#endif // PUSHBURTONGENERICDEVICE_H
@@ -61,8 +61,11 @@ void PushN8FootDevice::gotDataReceived(QString data)
QStringList params;
if(getPackage(data, params))
{
- int ntoes = params[1].toInt();
- int nheel = params[2].toInt();
+// int ntoes = params[1].toInt();//Want to flip, this is it!
+// int nheel = params[2].toInt();// THIS IS THE OLD SETUP
+
+ int ntoes = params[2].toInt();//Want to flip, this is it!
+ int nheel = params[1].toInt();// THIS IS THE NEW SETUP for the v3 boxes
NPushFootTick * newFootTick = new NPushFootTick(side, ntoes, nheel);

0 comments on commit e252bf5

Please sign in to comment.