Created
March 3, 2016 04:34
-
-
Save cho45/e8145280995995293204 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
arm-none-eabi-objcopy -O binary .pioenvs/lpc1114fn28/firmware.elf .pioenvs/lpc1114fn28/firmware.bin | |
text data bss dec hex filename | |
22948 124 340 23412 5b74 .pioenvs/lpc1114fn28/firmware.elf | |
arm-none-eabi-g++ --version | |
arm-none-eabi-g++ (GNU Tools for ARM Embedded Processors) 4.8.4 20140725 (release) [ARM/embedded-4_8-branch revision 213147] | |
Copyright (C) 2013 Free Software Foundation, Inc. | |
This is free software; see the source for copying conditions. There is NO | |
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "mbed.h" | |
DigitalOut myled(LED1); | |
AnalogIn adc(dp1); | |
int main() { | |
float foobar = adc.read(); | |
foobar = pow(foobar, 2); | |
while(1) { | |
myled = 1; | |
wait(0.2); | |
myled = 0; | |
wait(0.2); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment