/elec/quadcopter

To get this branch, use:
bzr branch http://bzr.ed.am/elec/quadcopter

« back to all changes in this revision

Viewing changes to src/rc-interface/comms.h

  • Committer: Tim Marston
  • Date: 2013-10-23 20:08:35 UTC
  • Revision ID: tim@ed.am-20131023200835-zqu4je2gn0y79car
- added "all done" message
- rewrote Importer.finish() to make the exit process more consistent
- moved Doit's message definitions to Doit
- ensure the importer is destroyed in Doit.onPause()
- only show the toaster popup if a) there is an importer to abort, and b) the abort actually did something (i.e., it's not already aborted)
- bugfix: added some checks for abortion to the Importer after wait()ing after a dialog. Importer.wake() now alsy does a notify() to break out of dialog waits.
- also, made Importer.checkAbort() protected, so it can be checked from specific importers as desiredfixed receiver test code which is now working

Show diffs side-by-side

added added

removed removed

1
 
//
2
 
// comms.h
3
 
//
4
 
 
5
 
#ifndef COMMS_H_
6
 
#define COMMS_H_
7
 
 
8
 
 
9
 
namespace Comms
10
 
{
11
 
        /**
12
 
         * Setup the Arduino as required.
13
 
         */
14
 
        void setup();
15
 
 
16
 
        /**
17
 
         * Write channel values.
18
 
         *
19
 
         * @param channel_values array of NUM_CHANNELS values
20
 
         */
21
 
        void write_channels( int channels[] );
22
 
 
23
 
        /**
24
 
         * Read channel values.  Call often.  If a complete frame is read,
25
 
         * channel_values will contain the data.
26
 
         *
27
 
         * @param channel_values array of NUM_MOTORS values
28
 
         * @returns true if a whole frame was read
29
 
         */
30
 
        bool read_channels( int channels[] );
31
 
}
32
 
 
33
 
 
34
 
#endif //COMMS_H_