本文整理汇总了C++中endCommand函数的典型用法代码示例。如果您正苦于以下问题:C++ endCommand函数的具体用法?C++ endCommand怎么用?C++ endCommand使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了endCommand函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: beginCommand
void I2CFlexel::loadLcdCustomCharacters(byte addr, byte *bitmap)
{
beginCommand(I2C_FLEXEL_COMMAND_LOAD_LCD_CUSTOM_CHARACTERS);
sendCommandParameter(addr);
sendCommandParameters(bitmap, I2C_FLEXEL_LCD_CHAR_ROWS_COUNT);
endCommand();
}
示例2: cm_send_ir
/**
* Sends the provided byte out over IR.
*/
void cm_send_ir(const uint8_t &data)
{
sendByte(CmdIRChar);
padCommand();
sendByte(data);
endCommand();
}
示例3: cm_play_song
/**
* Plays the song stored under the given number.
*/
void cm_play_song(const uint8_t &song_number)
{
sendByte(CmdPlay);
padCommand();
sendByte(song_number);
endCommand();
}
示例4: cm_play_demo
/**
* Tells the robot to play the specified demo.
* See the DEMO_* constants for more information.
*/
void cm_play_demo(const uint8_t &demo)
{
sendByte(CmdDemo);
padCommand();
sendByte(demo);
endCommand();
}
示例5: endCommand
Module::~Module()
{
endCommand();
qDeleteAll( d->modules );
delete d->project;
delete d;
}
示例6: cm_read_wall_signal
/**
* Reads the strength of the wall sensor's signal.
* The range is 0 to 4095.
*/
uint16_t cm_read_wall_signal(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_WALL_SIGNAL);
endCommand();
return readWord();
}
示例7: cm_read_front_left_cliff_signal
/**
* Reads the strength of the front left cliff sensor's signal.
* The range is 0 to 4095.
*/
uint16_t cm_read_front_left_cliff_signal(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_FRONT_LEFT_CLIFF_SIGNAL);
endCommand();
return readWord();
}
示例8: cm_read_right_cliff_signal
/**
* Reads the strength of the far right cliff sensor's signal.
* The range is 0 to 4095.
*/
uint16_t cm_read_right_cliff_signal(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_FAR_RIGHT_CLIFF_SIGNAL);
endCommand();
return readWord();
}
示例9: cm_read_oi_mode
/**
* Reads the current Open Interface mode.
* See the OI_MODE_* codes in the cm.h header.
*/
uint8_t cm_read_oi_mode(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_OI_MODE);
endCommand();
return readByte();
}
示例10: cm_read_battery_capacity
/**
* Reads the battery's estimated charge capacity in milliamp-hours.
* Note: This value is not accurate if the robot is running off Alkaline batteries.
*/
uint16_t cm_read_battery_capacity(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_CAPACITY);
endCommand();
return readWord();
}
示例11: cm_read_current_song_number
/**
* Reads the number of the currently-playing song.
* Range is 0-15.
*/
uint8_t cm_read_current_song_number(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_SONG_NUMBER);
endCommand();
return readByte();
}
示例12: cm_read_requested_radius
/**
* Returns the last-requested radius.
* Range is -32768 to 32767, units are in millimeters.
*/
uint16_t cm_read_requested_radius(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_RADIUS);
endCommand();
return readWord();
}
示例13: cm_read_is_song_playing
/**
* Returns 1 if there is a song currently playing.
*/
uint8_t cm_read_is_song_playing(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_SONG_PLAYING);
endCommand();
return readByte();
}
示例14: cm_read_battery_temperature
/**
* Reads the battery's current temperature in degrees Celsius.
*/
int8_t cm_read_battery_temperature(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_TEMPERATURE);
endCommand();
return readWord();
}
示例15: cm_read_battery_charge
/**
* Reads the battery's current charge in milliamp-hours.
* Note: This value is not accurate if the robot is running off Alkaline batteries.
*/
uint16_t cm_read_battery_charge(void)
{
sendByte(CmdSensors);
padCommand();
sendByte(SEN_CHARGE);
endCommand();
return readWord();
}