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.
Fork of Multiplexer-Test by
Multiplexer_read.cpp
- Committer:
- O_Shovah
- Date:
- 2014-09-10
- Revision:
- 9:341c831b162b
- Parent:
- 8:fd403cfcaa0a
File content as of revision 9:341c831b162b:
//Includes
#include "mbed.h"
//*************************************************************************
//Outputs
//*************************************************************************
DigitalOut timetest_0 (p30);
BusOut unused(p18);
//Inputs
//*************************************************************************
AnalogIn DMS_sens (p17);
//Communication
//*************************************************************************
int DMS_torque = 0;
Serial pc(USBTX, USBRX);
//DMS-Abfrage
//*************************************************************************
void DMS_value()
{
DMS_torque = DMS_sens.read_u16();
}
//*************************************************************************
//Main
//*************************************************************************
int main(void)
{
// Time counters
while(true) {
DMS_value();
pc.printf("%i\n\r",DMS_torque);
wait(0.5);
}
}
