void EIoTCloudRestApi::sendParameter(const char * instaceParamId, bool value) { if (value) sendParameter(instaceParamId, "1"); else sendParameter(instaceParamId, "0"); }
void EIoTCloudRestApi::sendParameter(const char * instaceParamId, const char * value) { sendParameter(instaceParamId, String(value)); }
void Test::test() { // sendHearbeat(false, MAV_STATE_STANDBY); // battery updateUI(); sendSystemStatus(100, 12.4); updateUI(); sendHomePosition( getRadians(59, 57, 11.44), // 59�'11.44"N getRadians(30, 18, 51.69), // 30�'51.69"E 0); updateUI(); sendCurrentPosition( getRadians(59, 57, 11.44), // 59�'11.44"N getRadians(30, 18, 51.69), // 30�'51.69"E 200); updateUI(); sendVfrHud( 10, // ground speed 10 m/s 180, // heading south (180 deg) 70, // 70% throttle 2); // climb rate 2 m/s down updateUI(); sendEkfStatusReport(0.9); updateUI(); // Base parameters sendParameter("WPNAV_SPEED", 500); sendParameter("WPNAV_SPEED_UP", 250); sendParameter("WPNAV_SPEED_DN", 150); sendParameter("RTL_ALT", 1500); sendParameter("RTL_ALT_FINAL", 0); sendParameter("LAND_SPEED", 50); sendParameter("BATT_CAPACITY", 5000); sendParameter("FS_BATT_MAH", 1000); sendParameter("FS_BATT_VOLTAGE", 13); updateUI(); //sendHearbeat(true); /* sendCurrentPosition( getRadians(59, 57, 37.56), // 59�'37.56"N getRadians(30, 18, 47.24), // 30�'47.24"E 10); */ // sendHearbeat(true, MAV_STATE_CRITICAL); sendStatusText(MAV_SEVERITY_CRITICAL, "Some very very very long status text."); updateUI(); sendStatusText(MAV_SEVERITY_CRITICAL, "TEST"); updateUI(); sendChannels(1100, 1500); updateUI(); sendHearbeat(true, MAV_STATE_ACTIVE); }