Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Revision 2:3fb7c06efa1e, committed 2013-08-16
- Comitter:
- ddollar
- Date:
- Fri Aug 16 16:49:34 2013 +0000
- Parent:
- 1:f5eafb42e9e4
- Commit message:
- model handling
Changed in this revision
| MachineCloud.cpp | Show annotated file Show diff for this revision Revisions of this file |
| MachineCloud.h | Show annotated file Show diff for this revision Revisions of this file |
--- a/MachineCloud.cpp Thu Aug 15 23:54:25 2013 +0000
+++ b/MachineCloud.cpp Fri Aug 16 16:49:34 2013 +0000
@@ -1,22 +1,20 @@
#include <string.h>
#include "MachineCloud.h"
-MachineCloud::MachineCloud(char *model) {
- init(model, 0x1000);
+MachineCloud::MachineCloud() {
+ init(0x1000);
}
-MachineCloud::MachineCloud(char *model, uint16_t router) {
- init(model, router);
+MachineCloud::MachineCloud(uint16_t router) {
+ init(router);
}
-void MachineCloud::init(char *model, uint16_t router) {
- m_model = model;
+void MachineCloud::init(uint16_t router) {
m_router = router;
}
int MachineCloud::connect() {
m_xbee = new XBee(p9, p10);
- send("model", m_model);
return 0;
}
--- a/MachineCloud.h Thu Aug 15 23:54:25 2013 +0000
+++ b/MachineCloud.h Fri Aug 16 16:49:34 2013 +0000
@@ -35,8 +35,8 @@
public:
// constructor
- MachineCloud(char *model);
- MachineCloud(char *model, uint16_t router);
+ MachineCloud();
+ MachineCloud(uint16_t router);
// connect to the machine cloud
int connect();
@@ -54,11 +54,10 @@
private:
- void init(char *model, uint16_t router);
+ void init(uint16_t router);
void receive(char *key, char *value);
Mutex m_lock;
- char *m_model;
MachineCloudCallback *m_receiverFunction;
MachineCloudReceiver *m_receiverObject;
uint16_t m_router;