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.
Revision 21:e01a019fae2f, committed 2020-03-04
- Comitter:
- open4416
- Date:
- Wed Mar 04 08:44:55 2020 +0000
- Parent:
- 20:e9daae390513
- Child:
- 22:4f764f7cd0b3
- Commit message:
- Fix timing issue
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Wed Mar 04 08:17:12 2020 +0000
+++ b/main.cpp Wed Mar 04 08:44:55 2020 +0000
@@ -74,6 +74,8 @@
spi2.format(16, 3);
//spi2.frequency(); //As default
#endif
+
+ wait_ms(2500);
ticker1.attach_us(&timer1_interrupt, 1000); //1 ms Systick
while(1) {
@@ -211,6 +213,7 @@
FLT_print = 0; //Stop error printing
VDU_STAT = VDU_PowerOn;
printf("VDU rebooting...\n");
+ printf("QDrive rebooting...\n");
} //Else keep in state
break;
}
@@ -586,6 +589,7 @@
temp_msg[0] = tmp;
temp_msg[1] = tmp >> 8U;
temp_msg[2] = RTD_cmd;
+ temp_msg[3] = RST_cmd;
// temp_msg[3] = 0U; // 2020/3/4 add to disable HMI reseting Driver
temp_msg[4] = 0U;
temp_msg[5] = 0U;
@@ -598,8 +602,6 @@
tmp = (int16_t) (FR_Tcmd * 100.0f);
temp_msg[0] = tmp;
temp_msg[1] = tmp >> 8U;
-// temp_msg[2] = RTD_cmd;
-// temp_msg[3] = RST_cmd;
can_msg_Tx = CANMessage(FR_CMD_ID,temp_msg,8,CANData,CANStandard);
CANpendTX();
can1.write(can_msg_Tx);
@@ -607,8 +609,6 @@
tmp = (int16_t) (RL_Tcmd * 100.0f);
temp_msg[0] = tmp;
temp_msg[1] = tmp >> 8U;
-// temp_msg[2] = RTD_cmd;
-// temp_msg[3] = RST_cmd;
can_msg_Tx = CANMessage(RL_CMD_ID,temp_msg,8,CANData,CANStandard);
CANpendTX();
can1.write(can_msg_Tx);
@@ -616,8 +616,6 @@
tmp = (int16_t) (RR_Tcmd * 100.0f);
temp_msg[0] = tmp;
temp_msg[1] = tmp >> 8U;
-// temp_msg[2] = RTD_cmd;
-// temp_msg[3] = RST_cmd;
can_msg_Tx = CANMessage(RR_CMD_ID,temp_msg,8,CANData,CANStandard);
CANpendTX();
can1.write(can_msg_Tx);