Sensix
Wireless Sensor Network Middleware



   Home


   Project Page


   Download


   CVS




 Hosted by
Get SENSIX at SourceForge.net. Fast, secure 
and Free Open Source software downloads

/home/brennan/Software/sensix/tools/sim/platform.pc/adc_model.c File Reference

#include <pthread.h>
#include "external_adc.h"

Go to the source code of this file.

Enumerations

enum  { ADC_NUM_PORTS_PER_NODE = 256 }

Functions

void random_adc_init ()
uint16_t random_adc_read (int moteID, uint8_t port, long long ftime)
adc_modelcreate_random_adc_model ()
void generic_adc_init ()
uint16_t generic_adc_read (int moteID, uint8_t port, long long ftime)
adc_modelcreate_generic_adc_model ()
void set_adc_value (int moteID, uint8_t port, uint16_t value)
void external_adc_init ()
int16_t external_adc_connect ()
uint16_t external_adc_read (int moteID, uint8_t port, long long ftime)
adc_modelcreate_external_adc_model ()

Variables

uint16_t adcValues [TOSNODES][ADC_NUM_PORTS_PER_NODE]
pthread_mutex_t adcValuesLock
uint16_t external_adc_connected
int external_adc_socket


Enumeration Type Documentation

anonymous enum

Enumerator:
ADC_NUM_PORTS_PER_NODE 

Definition at line 65 of file adc_model.c.


Function Documentation

adc_model* create_external_adc_model (  ) 

Definition at line 209 of file adc_model.c.

adc_model* create_generic_adc_model (  ) 

Definition at line 99 of file adc_model.c.

adc_model* create_random_adc_model (  ) 

Definition at line 54 of file adc_model.c.

int16_t external_adc_connect (  ) 

Definition at line 130 of file adc_model.c.

void external_adc_init (  ) 

Definition at line 125 of file adc_model.c.

uint16_t external_adc_read ( int  moteID,
uint8_t  port,
long long  ftime 
)

Definition at line 174 of file adc_model.c.

void generic_adc_init (  ) 

Definition at line 72 of file adc_model.c.

uint16_t generic_adc_read ( int  moteID,
uint8_t  port,
long long  ftime 
)

Definition at line 83 of file adc_model.c.

void random_adc_init (  ) 

Definition at line 48 of file adc_model.c.

uint16_t random_adc_read ( int  moteID,
uint8_t  port,
long long  ftime 
)

Definition at line 50 of file adc_model.c.

void set_adc_value ( int  moteID,
uint8_t  port,
uint16_t  value 
)

Definition at line 106 of file adc_model.c.


Variable Documentation

uint16_t adcValues[TOSNODES][ADC_NUM_PORTS_PER_NODE]

Definition at line 69 of file adc_model.c.

pthread_mutex_t adcValuesLock

Definition at line 70 of file adc_model.c.

Definition at line 122 of file adc_model.c.

Definition at line 123 of file adc_model.c.


© 2008, Los Alamos National Security, LLC.