![](/media/cache/group/Hepta_pic_SsOXYEQ.png.50x50_q85.png)
HeptaSat
main.cpp@27:e1060a85b032, 19 months ago (annotated)
- Committer:
- RyusukeIwata
- Date:
- Mon Nov 07 14:44:34 2022 +0000
- Revision:
- 27:e1060a85b032
- Parent:
- 26:e0f46da1ff13
raw;
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
mbed_official | 0:bdbd3d6fc5d5 | 1 | #include "mbed.h" |
HeptaSatTraining2019 | 25:4277e16b97c3 | 2 | #include "HEPTA_EPS.h" |
HeptaSatTraining2019 | 24:3659e0c223c8 | 3 | |
RyusukeIwata | 27:e1060a85b032 | 4 | RawSerial pc(USBTX,USBRX,9600); |
HeptaSatTraining2019 | 25:4277e16b97c3 | 5 | HEPTA_EPS eps(p16,p26); |
HeptaSatTraining2019 | 24:3659e0c223c8 | 6 | |
umeume | 2:1c5cdb2c3e0f | 7 | int main() |
umeume | 2:1c5cdb2c3e0f | 8 | { |
HeptaSatTraining2019 | 26:e0f46da1ff13 | 9 | float bt_dec; |
HeptaSatTraining2019 | 26:e0f46da1ff13 | 10 | char bt_hex[4]; |
HeptaSatTraining2019 | 25:4277e16b97c3 | 11 | for(int i = 0; i < 10; i++) { |
HeptaSatTraining2019 | 26:e0f46da1ff13 | 12 | eps.vol(&bt_dec); |
HeptaSatTraining2019 | 26:e0f46da1ff13 | 13 | eps.vol_u16(bt_hex); |
HeptaSatTraining2019 | 26:e0f46da1ff13 | 14 | pc.printf("Vol = %f\r\n",bt_dec); |
HeptaSatTraining2019 | 26:e0f46da1ff13 | 15 | pc.printf("Vol_hex = %c%c%c%c\r\n",bt_hex[0],bt_hex[1],bt_hex[2],bt_hex[3]); |
HeptaSatTraining2019 | 25:4277e16b97c3 | 16 | wait(1.0); |
HeptaSatTraining2019 | 24:3659e0c223c8 | 17 | } |
umeume | 2:1c5cdb2c3e0f | 18 | } |