本文整理汇总了C++中OLED_ShowString函数的典型用法代码示例。如果您正苦于以下问题:C++ OLED_ShowString函数的具体用法?C++ OLED_ShowString怎么用?C++ OLED_ShowString使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了OLED_ShowString函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: user_modules_init
OSStatus user_modules_init(void)
{
OSStatus err = kUnknownErr;
// init DC Motor(GPIO)
dc_motor_init();
dc_motor_set(0); // off
// init RGB LED(P9813)
hsb2rgb_led_init();
hsb2rgb_led_open(0, 0, 0); // off
// init OLED
OLED_Init();
//OLED_Clear();
LCD_Clear(0x00);
OLED_ShowString(20,0,"M X C H I P");
OLED_ShowString(20,3,(uint8_t*)DEFAULT_DEVICE_NAME);
OLED_ShowString(0,6,"T: 0C H: 0%");
// init Light sensor(ADC)
light_sensor_init();
// init infrared sensor(ADC)
infrared_reflective_init();
// init user key1 && key2
user_key1_init();
user_key2_init();
err = kNoErr;
return err;
}
示例2: alert_signal
/**@brief Signals alert event from Immediate Alert or Link Loss services.
*
* @param[in] alert_level Requested alert level.
*/
static void alert_signal(uint8_t alert_level)
{
switch (alert_level)
{
case BLE_CHAR_ALERT_LEVEL_NO_ALERT:
m_is_link_loss_alerting = false;
alert_led_blink_stop();
#if OLED096_Func
OLED_ShowString(48,16, (uint8_t*)" ");
OLED_Refresh_Gram();
#endif
break;
case BLE_CHAR_ALERT_LEVEL_MILD_ALERT:
alert_led_blink_start();
break;
case BLE_CHAR_ALERT_LEVEL_HIGH_ALERT:
alert_led_blink_stop();
nrf_gpio_pin_set(ALERT_PIN_NO);
#if OLED096_Func
OLED_ShowString(48,16, (uint8_t*)"ALT");
OLED_Refresh_Gram();
#endif
break;
default:
break;
}
}
示例3: menu_Showtime
void menu_Showtime()
{
OLED_ShowNum(0,0,Time/3600,2,16,0);
// OLED_ShowString(16,0,":");
OLED_ShowNum(24,0,Time%3600/60,2,16,0);
// OLED_ShowString(40,0,":");
OLED_ShowNum(48,0,Time%60,2,16,0);
OLED_ShowNum(0,2,img.CerPtx,3,16,1);
OLED_ShowNum(32,2,img.CerPty,3,16,1);
OLED_ShowNum(64,2,img.CerR,3,16,1);
OLED_ShowNum(98,2,img.rate,3,16,1);
OLED_ShowNum(0,4,img.Line[0].pt1x,3,16,1);
OLED_ShowNum(32,4,img.Line[0].pt1y,3,16,1);
OLED_ShowNum(64,4,img.Line[0].pt2x,3,16,1);
OLED_ShowNum(98,4,img.Line[0].pt2y,3,16,1);
switch(FLYMODE)
{
case CTRLP:
OLED_ShowString(50,6,"CTRLP");
break;
case _A_B_:
OLED_ShowString(50,6,"_A_B_");
break;
}
}
示例4: mico_system_delegate_config_success
void mico_system_delegate_config_success( mico_config_source_t source )
{
config_delegate_log_trace();
#ifdef USE_MiCOKit_EXT
char oled_show_line[OLED_DISPLAY_MAX_CHAR_PER_ROW+1] = {'\0'};
#endif
config_delegate_log( "Wi-Fi configed by: %d", source );
MicoGpioOutputLow((mico_gpio_t)MICO_SYS_LED);
#ifdef USE_MiCOKit_EXT
memset(oled_show_line, '\0', OLED_DISPLAY_MAX_CHAR_PER_ROW+1);
if(CONFIG_BY_AIRKISS == source){
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%s", (uint8_t*)"Airkiss success ");
}else if(CONFIG_BY_SOFT_AP == source){
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%s", (uint8_t*)"SoftAP success ");
}else if(CONFIG_BY_WAC == source){
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%s", (uint8_t*)"WAC success ");
}else if( (CONFIG_BY_EASYLINK_V2 == source) || (CONFIG_BY_EASYLINK_PLUS == source) ||
(CONFIG_BY_EASYLINK_MINUS == source) ){
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%s", (uint8_t*)"Easylink success");
}else{
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%s", (uint8_t*)"Unknown ");
}
OLED_ShowString(OLED_DISPLAY_COLUMN_START, OLED_DISPLAY_ROW_2, (uint8_t*)oled_show_line);
OLED_ShowString(OLED_DISPLAY_COLUMN_START, OLED_DISPLAY_ROW_3, (uint8_t*)" ");
OLED_ShowString(OLED_DISPLAY_COLUMN_START, OLED_DISPLAY_ROW_4, (uint8_t*)" ");
#endif
return;
}
示例5: ConfigEasyLinkIsSuccess
void ConfigEasyLinkIsSuccess( mico_Context_t * const inContext )
{
(void)(inContext);
config_delegate_log_trace();
#ifdef USE_MiCOKit_EXT
char oled_show_line[OLED_DISPLAY_MAX_CHAR_PER_ROW+1] = {'\0'};
#endif
mico_stop_timer(&_Led_EL_timer);
mico_deinit_timer( &_Led_EL_timer );
mico_init_timer(&_Led_EL_timer, SYS_LED_TRIGGER_INTERVAL_AFTER_EASYLINK, _led_EL_Timeout_handler, NULL);
mico_start_timer(&_Led_EL_timer);
#ifdef USE_MiCOKit_EXT
memset(oled_show_line, '\0', OLED_DISPLAY_MAX_CHAR_PER_ROW+1);
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%s", (uint8_t*)"EasyLink got ");
OLED_ShowString(OLED_DISPLAY_COLUMN_START, OLED_DISPLAY_ROW_2, (uint8_t*)oled_show_line);
memset(oled_show_line, '\0', OLED_DISPLAY_MAX_CHAR_PER_ROW+1);
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%16s", inContext->flashContentInRam.micoSystemConfig.ssid);
OLED_ShowString(OLED_DISPLAY_COLUMN_START, OLED_DISPLAY_ROW_3, (uint8_t*)oled_show_line);
memset(oled_show_line, '\0', OLED_DISPLAY_MAX_CHAR_PER_ROW+1);
snprintf(oled_show_line, OLED_DISPLAY_MAX_CHAR_PER_ROW+1, "%16s", inContext->flashContentInRam.micoSystemConfig.user_key);
OLED_ShowString(OLED_DISPLAY_COLUMN_START, OLED_DISPLAY_ROW_4, (uint8_t*)oled_show_line);
#endif
return;
}
示例6: osd_iris_val_disp
void osd_iris_val_disp(u8 irisv)
{
if(iris_mode>1)
iris_mode = 1;
u8 tmp;
u8 no_val_str[]={"---"};
if(iris_motor_mode > 4)
{
OLED_ShowString(OSD_IRIS_X_START,OSD_LINE3_Y_POS,(u8*)iris_msg_osd[5],16);
}
else
{
OLED_ShowString(OSD_IRIS_X_START,OSD_LINE3_Y_POS,(u8*)iris_msg_osd[iris_motor_mode],16);
}
#if 0
iris_motor_mode = 1;
iris_mode = 1;
iris_val = 50;
#endif
if(0 == iris_motor_mode)
{
memset(iris_val_osd_buf,0,10);
// strcat(iris_val_osd_buf,no_val_str);
//
// OLED_ShowString(88,OSD_LINE3_Y_POS,iris_val_osd_buf,16);
}
else
{
memset(iris_val_osd_buf,0,10);
strcat(iris_val_osd_buf,iris_mode_osd[iris_mode]);
if(iris_mode)
{
if(iris_val == 0xff)
{
strcat(iris_val_osd_buf,no_val_str);
}
else
{
num_to_string_ex((u16)iris_val,iris_val_osd_buf+1,3);
}
}
OLED_ShowString(88,OSD_LINE3_Y_POS,iris_val_osd_buf,16);
}
}
示例7: Mode_Idle_Init
extern void Mode_Idle_Init(void)
{
#ifdef INCLUDE_OLED12832
uint8_t timeTemp[17];
sprintf((char *)timeTemp, "%02d:%02d:%02d 2016/4", sysTime.Hour, sysTime.Minute, sysTime.Second);
OLED_ShowString(0, 0, "Tag Test");
OLED_ShowString(0, 16, timeTemp);
#endif
}
示例8: osd_baudrate_disp
void osd_baudrate_disp(u16 data)
{
if(data > 3)
return;
OLED_ShowString(OSD_LINE1_X_POS,OSD_BAUDRATE_ID_Y_POS,(u8 *)baudrate_string[data],16);
OLED_ShowString(OSD_LINE1_X_POS+32,OSD_BAUDRATE_ID_Y_POS,"BPS",16);
}
示例9: ShowHomePageInit
void ShowHomePageInit(void)
{
OLED_ShowString(0, 0, "Roll: 0.0 ");
OLED_ShowString(0, 2, "Pitch: 0.0 ");
OLED_ShowString(0, 4, "Yaw: 0.0 ");
OLED_ShowString(0, 6, "Power: 0.0V ");
ShowBattery();
ShowLockStat();
ShowRuning();
OLED_DrawBMP(112, 6, 128, 8, BLACK_FILL_BMP);
}
示例10: osd_para_mode_disp_xy
void osd_para_mode_disp_xy(u8 mode,u8 x,u8 y)
{
u8 *mstr="Mode";
u8 pp;
if(mode > 8)
return;
OLED_ShowString(OSD_PARA_MODE_X_START,OSD_PARA_MODE_Y,mstr,16);
pp = mode+0x31;
OLED_ShowString(OSD_SET_PARA_START_ADDR,0,&pp,16);
}
示例11: osd_para_mode_disp
void osd_para_mode_disp(u8 mode)
{
u8 *mstr="Mode";
u8 pp;
if(mode > 8)
return;
OLED_ShowString(OSD_PARA_MODE_X_START,OSD_PARA_MODE_Y,mstr,16);
pp = mode+0x31;
OLED_ShowString(OSD_PARA_MODE_X_START+32,OSD_PARA_MODE_Y,&pp,16);
}
示例12: osd_iris_mode_disp
void osd_iris_mode_disp(u8 mode)
{
if(mode == 0xff)
{
OLED_ShowString(OSD_IRIS_MODE_X_START,OSD_IRIS_MODE_Y,(u8*)iris_msg_string[IRIS_MSG_ITERMS_MAX-1],16);
return;
}
if(mode > IRIS_MSG_ITERMS_MAX-1)
return;
OLED_ShowString(OSD_IRIS_MODE_X_START,OSD_IRIS_MODE_Y,(u8*)iris_msg_string[mode],16);
}
示例13: osd_iris_mode_disp_xy
void osd_iris_mode_disp_xy(u8 mode,u8 x,u8 y)
{
if(mode == 0xff)
{
OLED_ShowString(OSD_IRIS_MODE_X_START,OSD_IRIS_MODE_Y,(u8*)iris_msg_string[IRIS_MSG_ITERMS_MAX-1],16);
return;
}
if(mode > IRIS_MSG_ITERMS_MAX-1)
return;
OLED_ShowString(OSD_SET_PARA_START_ADDR,0,(u8*)iris_msg_string[mode],16);
}
示例14: osd_shutter_val_disp
void osd_shutter_val_disp(u8 sv)
{
if(sv)
{
OLED_ShowString(0,OSD_LINE3_Y_POS,(u8*)osd_shutter_string,16);
}
else
{
OLED_ShowString(0,OSD_LINE3_Y_POS,(u8*)osd_shutter_string,16);
OLED_ShowString(16,OSD_LINE3_Y_POS,(u8*)auto_string,16);
}
}
示例15: osd_filter_mode_disp_xy
void osd_filter_mode_disp_xy(u8 mode,u8 x,u8 y)
{
if(mode == 0xff)
{
OLED_ShowString(OSD_FILTER_MODE_X_START,OSD_FILTER_MODE_Y,(u8*)filter_string[4],16);
return;
}
if(mode > 3)
return;
OLED_ShowString(OSD_SET_PARA_START_ADDR,0,(u8*)filter_string[mode],16);
}