Contiki 3.x
Functions
sampler.h File Reference

Process that periodically takes samples from onboard sensors and stores them in flash. More...

#include <stdbool.h>
#include "contiki.h"
#include "settings.pb.h"

Go to the source code of this file.

Functions

 PROCESS_NAME (sample_process)
 Process the sampler runs as.
 
void sampler_refresh_config (void)
 Get the Sampler to reload it's config from flash. More...
 
bool sampler_check_config (SensorConfig *config)
 Check a config for sanity. More...
 

Detailed Description

Process that periodically takes samples from onboard sensors and stores them in flash.

The sensors to sample as well as the sampling interval are defined by the SampleConfig stored in the Store. The sampler can be instrcuted to reload it from the Store by calling sampler_refresh_config()

Author
Dan Playle djap1.nosp@m.g12@.nosp@m.soton.nosp@m..ac..nosp@m.uk Philip Basford pjb@e.nosp@m.cs.s.nosp@m.oton..nosp@m.ac.u.nosp@m.k Graeme Bragg gmb1g.nosp@m.08@e.nosp@m.cs.so.nosp@m.ton..nosp@m.ac.uk Tyler Ward tw16g.nosp@m.08@e.nosp@m.cs.so.nosp@m.ton..nosp@m.ac.uk Kirk Martinez km@ec.nosp@m.s.so.nosp@m.ton.a.nosp@m.c.uk Arthur Fabre af1g1.nosp@m.2@ec.nosp@m.s.sot.nosp@m.on.a.nosp@m.c.uk

Definition in file sampler.h.

Function Documentation

bool sampler_check_config ( SensorConfig *  config)

Check a config for sanity.

Returns
True if the config is sane, false otherwise.

Definition at line 266 of file sampler.c.

void sampler_refresh_config ( void  )

Get the Sampler to reload it's config from flash.

This is a non blocking asynchronous call.

Definition at line 261 of file sampler.c.

References NULL, and process_post().