问答

汇集网友智慧,解决技术难题

21ic问答首页 - TAG - CH573
  • TMOS消息管理 sos

    请问有没有TMOS的消息发送的完整例程啊

    BLE CH573

    3493浏览量 0回复量 关注量
  • CH573中断进不去

    void KEY_GPIO_Init(void) { GPIOB_ModeCfg(GPIO_Pin_22,GPIO_ModeIN_PU);[font=consolas, monospace][color=#f92672]//初始化位输入上拉[/color][/font] GPIOB_ITModeCfg(GPIO_Pin_22,GPIO_ITMode_FallEdge);[font=consolas, monospace][color=#f92672]//开启下降沿中断[/color][/font] PFIC_EnableIRQ( GPIO_B_IRQn );[font=consolas, monospace][color=#f92672]//开启GPIOB中断[/color][/font]} __attribute__((interrupt("WCH-Interrupt-fast"))) __attribute__((section(".highcode"))) void GPIOB_IRQHandler(void) { uint16_t GPIOB_irqFlag = GPIOB_ReadITFlagPort(); if( GPIOB_irqFlag & GPIO_Pin_22 ) { GPIOB_ClearITFlagBit(GPIO_Pin_22); if(GPIOB_ReadPortPin(GPIO_Pin_22) == 0) { 按键控制; } } } 进不去中断

    CH573 pi gp IO GPIO TE

    4244浏览量 1回复量 关注量
  • CH573F IO 中断怎么用,是不是漏了什么配置, 一直不进中断

    [color=rgb(249, 38, 114)][font=consolas, monospace]void gpio_wake_init() {[/font][/color] [font=consolas, monospace][color=#f92672] //初始化位输入上拉[/color][/font] [font=consolas, monospace][color=#f92672] GPIOB_ModeCfg(GPIO_Pin_4, GPIO_ModeIN_PU);[/color][/font] [font=consolas, monospace][color=#f92672] //开启下降沿中断[/color][/font] [font=consolas, monospace][color=#f92672] GPIOB_ITModeCfg(GPIO_Pin_4,GPIO_ITMode_FallEdge);[/color][/font] [font=consolas, monospace][color=#f92672] //开启GPIO睡眠唤醒[/color][/font] [font=consolas, monospace][color=#f92672] PWR_PeriphWakeUpCfg( ENABLE, RB_SLP_GPIO_WAKE,Edge_LongDelay );[/color][/font] [font=consolas, monospace][color=#f92672] //开启GPIOB中断[/color][/font] [font=consolas, monospace][color=#f92672] PFIC_EnableIRQ(GPIO_B_IRQn);[/color][/font] [font=consolas, monospace][color=#f92672]}[/color][/font] [font=consolas, monospace][color=#f92672] [/color][/font] [font=consolas, monospace][color=#f92672]//中断服务程序[/color][/font] [font=consolas, monospace][color=#f92672]__attribute__((interrupt("WCH-Interrupt-fast"))) //硬件压栈[/color][/font] [font=consolas, monospace][color=#f92672]__attribute__((section(".highcode"))) //放到RAM里[/color][/font] [font=consolas, monospace][color=#f92672]void GPIOB_IRQHandler(void) {[/color][/font] [font=consolas, monospace][color=#f92672] PRINT("gpio interrupt\r\n");[/color][/font] [font=consolas, monospace][color=#f92672] GPIOB_ClearITFlagBit(GPIO_Pin_4);[/color][/font] [font=consolas, monospace][color=#f92672]}[/color][/font] 搜索 [align=left]复制[/align]

    中断 CH573 IO pi gp GPIO

    3184浏览量 3回复量 关注量