使用 Delay1TCYx 调用无原型错误消息的函数(1)(C 语言)

发布于 2025-01-17 03:28:09 字数 560 浏览 3 评论 0原文

我们有一个使用 C 和 PICkit 3 运行的项目。我们的问题是我们仍然收到相同的错误消息,并且不确定问题是什么。任何帮助/建议都会很棒。

void main (void)
{
    ANSEL = 0;  //turn off all other analog inputs
    ANSELH = 0;
    ANSELbits.ANS0 = 1; // turn on RA0 analog
    ADCON0 = 1; // justify right

    ADC_Init();                  // Call ADC_Init function
    ADC_Convert();
    Delay1TCYx(1);           //delay 1 x 1 cycles 
    int reading0 = ADRESL + (ADRESH * 256); //convert result to 10 bits
    
    if (reading0 = 0b1000000011)
    {   
        readingsamples();
    }
while(1);
}

We have a project that were running using C and a PICkit 3. Our issu is that we remain getting the same error message and arent sure whta the issue is. Any help / advice would be great.

void main (void)
{
    ANSEL = 0;  //turn off all other analog inputs
    ANSELH = 0;
    ANSELbits.ANS0 = 1; // turn on RA0 analog
    ADCON0 = 1; // justify right

    ADC_Init();                  // Call ADC_Init function
    ADC_Convert();
    Delay1TCYx(1);           //delay 1 x 1 cycles 
    int reading0 = ADRESL + (ADRESH * 256); //convert result to 10 bits
    
    if (reading0 = 0b1000000011)
    {   
        readingsamples();
    }
while(1);
}

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文