日B视频 亚洲,啪啪啪网站一区二区,91色情精品久久,日日噜狠狠色综合久,超碰人妻少妇97在线,999青青视频,亚洲一区二卡,让本一区二区视频,日韩网站推荐

0
  • 聊天消息
  • 系統(tǒng)消息
  • 評(píng)論與回復(fù)
登錄后你可以
  • 下載海量資料
  • 學(xué)習(xí)在線課程
  • 觀看技術(shù)視頻
  • 寫文章/發(fā)帖/加入社區(qū)
會(huì)員中心
創(chuàng)作中心

完善資料讓更多小伙伴認(rèn)識(shí)你,還能領(lǐng)取20積分哦,立即完善>

3天內(nèi)不再提示

【開源獲獎(jiǎng)案例】多功能稱重器

迪文智能屏 ? 2024-04-20 08:12 ? 次閱讀
加入交流群
微信小助手二維碼

掃碼添加小助手

加入工程師交流群

——來自迪文開發(fā)者論壇

本期為大家推送迪文開發(fā)者論壇獲獎(jiǎng)開源案例——多功能稱重器。工程師采用4英寸COF智能屏,通過T5L OS核與HX711模塊及5kg壓力傳感器套裝進(jìn)行數(shù)據(jù)交互,用戶可輕松實(shí)現(xiàn)重量、單價(jià)、總價(jià)、去皮等計(jì)價(jià)顯示功能,以及計(jì)數(shù)、重量變化曲線跟蹤和稱重器精準(zhǔn)度矯正等功能,輕松切換不同應(yīng)用場(chǎng)景,享受便捷高效稱重體驗(yàn)。


UI開發(fā)示例

be60b46a-feaa-11ee-9118-92fbcf53809c.png

C51工程設(shè)計(jì) 稱重器實(shí)現(xiàn)計(jì)價(jià)功能的部分參考代碼如下:

//計(jì)價(jià)頁(yè)面===================#define VALUATION_UNIT_PRICE_ADDR 0x1010#define VALUATION_GRAM_ADDR 0x1000#define VALUATION_TOTAL_PRICES_ADDR 0x1020uint32_t valuation_decorticate = 0; //計(jì)價(jià)去皮重量uint32_t valuation_unit_price = 0; //單價(jià)//單價(jià)刷新void page_valuation_unit_price_refresh(){ uint8_t test_display[10] = {0}; if(valuation_unit_price < 1000) { test_display[0] = valuation_unit_price / 100 % 10 + 0x30; test_display[1] = '.'; test_display[2] = valuation_unit_price / 10 % 10 + 0x30; test_display[3] = valuation_unit_price / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_UNIT_PRICE_ADDR, test_display, 4); } else if(valuation_unit_price < 10000) { test_display[0] = valuation_unit_price / 1000 % 10 + 0x30; test_display[1] = valuation_unit_price / 100 % 10 + 0x30; test_display[2] = '.'; test_display[3] = valuation_unit_price / 10 % 10 + 0x30; test_display[4] = valuation_unit_price / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_UNIT_PRICE_ADDR, test_display, 4); } else if(valuation_unit_price < 100000) { test_display[0] = valuation_unit_price / 10000 % 10 + 0x30; test_display[1] = valuation_unit_price / 1000 % 10 + 0x30; test_display[2] = valuation_unit_price / 100 % 10 + 0x30; test_display[3] = '.'; test_display[4] = valuation_unit_price / 10 % 10 + 0x30; test_display[5] = valuation_unit_price / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_UNIT_PRICE_ADDR, test_display, 4); } else if(valuation_unit_price < 1000000) { test_display[0] = valuation_unit_price / 100000 % 10 + 0x30; test_display[1] = valuation_unit_price / 10000 % 10 + 0x30; test_display[2] = valuation_unit_price / 1000 % 10 + 0x30; test_display[3] = valuation_unit_price / 100 % 10 + 0x30; test_display[4] = '.'; test_display[5] = valuation_unit_price / 10 % 10 + 0x30; test_display[6] = valuation_unit_price / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_UNIT_PRICE_ADDR, test_display, 4); }}
//重量刷新void page_valuation_weight_refresh(){ uint8_t test_display[10] = {0x30}; uint32_t gram_display = 0; if(gram_value >= valuation_decorticate) { gram_display = gram_value - valuation_decorticate; if(gram_display < 10) { test_display[0] = gram_display / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_GRAM_ADDR, test_display, 3); } else if(gram_display < 100) { test_display[0] = gram_display / 10 % 10 + 0x30; test_display[1] = gram_display / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_GRAM_ADDR, test_display, 3); } else if(gram_display < 1000) { test_display[0] = gram_display / 100 % 10 + 0x30; test_display[1] = gram_display / 10 % 10 + 0x30; test_display[2] = gram_display / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_GRAM_ADDR, test_display, 3); } else if(gram_display < 10000) { test_display[0] = gram_display / 1000 % 10 + 0x30; test_display[1] = gram_display / 100 % 10 + 0x30; test_display[2] = gram_display / 10 % 10 + 0x30; test_display[3] = gram_display / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_GRAM_ADDR, test_display, 3); } else if(gram_display < 100000) { test_display[0] = gram_display / 10000 % 10 + 0x30; test_display[1] = gram_display / 1000 % 10 + 0x30; test_display[2] = gram_display / 100 % 10 + 0x30; test_display[3] = gram_display / 10 % 10 + 0x30; test_display[4] = gram_display / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_GRAM_ADDR, test_display, 3); } } else { dgus_show_text_value_set(VALUATION_GRAM_ADDR, test_display, 3); }}
//總價(jià)刷新void page_valuation_price_refresh(){ uint32_t price_value = 0; uint8_t test_display[10] = {0x30, '.', 0x30, 0x30}; if(gram_value >= valuation_decorticate) { price_value = (gram_value - valuation_decorticate) * valuation_unit_price * 2 / 1000; if(price_value < 1000) { test_display[0] = price_value / 100 % 10 + 0x30; test_display[1] = '.'; test_display[2] = price_value / 10 % 10 + 0x30; test_display[3] = price_value / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_TOTAL_PRICES_ADDR, test_display, 4); } else if(price_value < 10000) { test_display[0] = price_value / 1000 % 10 + 0x30; test_display[1] = price_value / 100 % 10 + 0x30; test_display[2] = '.';

test_display[3] = price_value / 10 % 10 + 0x30; test_display[4] = price_value / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_TOTAL_PRICES_ADDR, test_display, 4); } else if(price_value < 100000)

{ test_display[0] = price_value / 10000 % 10 + 0x30; test_display[1] = price_value / 1000 % 10 + 0x30; test_display[2] = price_value / 100 % 10 + 0x30; test_display[3] = '.'; test_display[4] = price_value / 10 % 10 + 0x30; test_display[5] = price_value / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_TOTAL_PRICES_ADDR, test_display, 4);

} else if(price_value < 1000000) { test_display[0] = price_value / 100000 % 10 + 0x30; test_display[1] = price_value / 10000 % 10 + 0x30; test_display[2] = price_value / 1000 % 10 + 0x30; test_display[3] = price_value / 100 % 10 + 0x30; test_display[4] = '.'; test_display[5] = price_value / 10 % 10 + 0x30; test_display[6] = price_value / 1 % 10 + 0x30; dgus_show_text_value_set(VALUATION_TOTAL_PRICES_ADDR, test_display, 4); } } else { dgus_show_text_value_set(VALUATION_TOTAL_PRICES_ADDR, test_display, 4); }}void page_valuation_decorticate(){ valuation_decorticate = gram_value; page_valuation_weight_refresh();}void page_valuation_1(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 1; page_valuation_unit_price_refresh(); }}void page_valuation_2(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 2; page_valuation_unit_price_refresh(); }}void page_valuation_3(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 3; page_valuation_unit_price_refresh(); }}void page_valuation_4(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 4; page_valuation_unit_price_refresh(); }}

void page_valuation_5(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 5; page_valuation_unit_price_refresh(); }}void page_valuation_6(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 6; page_valuation_unit_price_refresh(); }}void page_valuation_7(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 7; page_valuation_unit_price_refresh(); }}void page_valuation_8(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 8; page_valuation_unit_price_refresh(); }}void page_valuation_9(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 9; page_valuation_unit_price_refresh(); }}void page_valuation_0(){ if(valuation_unit_price < 100000) { valuation_unit_price = valuation_unit_price * 10 + 0; page_valuation_unit_price_refresh(); }}void page_valuation_back(){ valuation_unit_price = valuation_unit_price / 10; page_valuation_unit_price_refresh();}void page_valuation_clear(){ valuation_unit_price = 0; page_valuation_unit_price_refresh();}

聲明:本文內(nèi)容及配圖由入駐作者撰寫或者入駐合作網(wǎng)站授權(quán)轉(zhuǎn)載。文章觀點(diǎn)僅代表作者本人,不代表電子發(fā)燒友網(wǎng)立場(chǎng)。文章及其配圖僅供工程師學(xué)習(xí)之用,如有內(nèi)容侵權(quán)或者其他違規(guī)問題,請(qǐng)聯(lián)系本站處理。 舉報(bào)投訴
  • 傳感器
    +關(guān)注

    關(guān)注

    2578

    文章

    55580

    瀏覽量

    794319
  • 開源
    +關(guān)注

    關(guān)注

    3

    文章

    4375

    瀏覽量

    46475
  • 智能屏幕
    +關(guān)注

    關(guān)注

    0

    文章

    76

    瀏覽量

    3873
收藏 人收藏
加入交流群
微信小助手二維碼

掃碼添加小助手

加入工程師交流群

    評(píng)論

    相關(guān)推薦
    熱點(diǎn)推薦

    MAX9491:多功能時(shí)鐘發(fā)生的技術(shù)剖析

    MAX9491:多功能時(shí)鐘發(fā)生的技術(shù)剖析 引言 在通信應(yīng)用的世界里,時(shí)鐘發(fā)生扮演著至關(guān)重要的角色。MAX9491作為一款多功能時(shí)鐘發(fā)生
    的頭像 發(fā)表于 04-22 15:30 ?112次閱讀

    MC14007UB:多功能雙互補(bǔ)對(duì)加反相芯片的深度解析

    MC14007UB:多功能雙互補(bǔ)對(duì)加反相芯片的深度解析 在電子設(shè)計(jì)領(lǐng)域,一款性能出色且功能多樣的芯片往往能為工程師們帶來更多的設(shè)計(jì)靈感和便利。今天,我們就來深入探討一下MC14007UB這款
    的頭像 發(fā)表于 04-11 13:40 ?121次閱讀

    多功能新型電力驅(qū)鳥:超聲波+語音,雙重驅(qū)鳥更有效

    鳥類喜歡在輸電線路區(qū)域筑巢活動(dòng),其排泄物可能導(dǎo)致絕緣子閃絡(luò),鳥巢可能引發(fā)短路跳閘,嚴(yán)重時(shí)甚至?xí)斐赏k娛鹿?。不過,近年來智能驅(qū)鳥的推廣使用,大大降低了鳥類對(duì)電網(wǎng)的影響。接下來,我們?cè)敿?xì)聊聊多功能
    的頭像 發(fā)表于 03-26 09:09 ?233次閱讀
    <b class='flag-5'>多功能</b>新型電力驅(qū)鳥<b class='flag-5'>器</b>:超聲波+語音,雙重驅(qū)鳥更有效

    深入解析DS1388:多功能I2C RTC/監(jiān)控的卓越之選

    深入解析DS1388:多功能I2C RTC/監(jiān)控的卓越之選 在電子設(shè)計(jì)領(lǐng)域,實(shí)時(shí)時(shí)鐘(RTC)、監(jiān)控和EEPROM等功能模塊是眾多電子設(shè)備不可或缺的組成部分。Maxim Integ
    的頭像 發(fā)表于 03-24 10:15 ?278次閱讀

    LT3581:多功能DC/DC轉(zhuǎn)換的設(shè)計(jì)與應(yīng)用

    LT3581:多功能DC/DC轉(zhuǎn)換的設(shè)計(jì)與應(yīng)用 在電子工程師的日常工作中,DC/DC轉(zhuǎn)換是一個(gè)常見且關(guān)鍵的元件。今天我們就來深入探討一下Linear Technology公司的LT3581這款
    的頭像 發(fā)表于 03-11 11:25 ?342次閱讀

    多功能推拉力測(cè)試機(jī)是集高精度、多功能于一體的力學(xué)檢測(cè)設(shè)備

    多功能推拉力測(cè)試機(jī)作為工業(yè)檢測(cè)領(lǐng)域的“精密天平”,以其高精度、多功能與智能化特性,成為保障產(chǎn)品質(zhì)量的核心工具。從半導(dǎo)體封裝到航空航天,從汽車電子到醫(yī)療設(shè)備,其應(yīng)用場(chǎng)景的廣泛性印證了技術(shù)普適性與工業(yè)
    的頭像 發(fā)表于 03-10 17:57 ?253次閱讀
    <b class='flag-5'>多功能</b>推拉力測(cè)試機(jī)是集高精度、<b class='flag-5'>多功能</b>于一體的力學(xué)檢測(cè)設(shè)備

    汽車級(jí)多功能門執(zhí)行驅(qū)動(dòng)L99DZ80EP深度解析

    汽車級(jí)多功能門執(zhí)行驅(qū)動(dòng)L99DZ80EP深度解析 在汽車電子領(lǐng)域,門執(zhí)行驅(qū)動(dòng)的性能和可靠性至關(guān)重要。今天我們要深入探討的L99DZ8
    的頭像 發(fā)表于 03-02 15:25 ?281次閱讀

    用于SWD/JTAG調(diào)試多功能轉(zhuǎn)接板設(shè)計(jì)

    這款多功能轉(zhuǎn)接板主要設(shè)計(jì)用于與 J-Link 調(diào)試配合使用(同時(shí)兼容其他采用標(biāo)準(zhǔn) 20 引腳 JTAG/SWD 引腳定義的調(diào)試),允許用戶在 0.1" (2.54mm
    的頭像 發(fā)表于 01-19 09:46 ?3605次閱讀
    用于SWD/JTAG調(diào)試<b class='flag-5'>器</b>的<b class='flag-5'>多功能</b>轉(zhuǎn)接板設(shè)計(jì)

    MS1826 HDMI 多功能視頻處理數(shù)據(jù)手冊(cè)

    電子發(fā)燒友網(wǎng)站提供《MS1826 HDMI 多功能視頻處理數(shù)據(jù)手冊(cè).pdf》資料免費(fèi)下載
    發(fā)表于 09-26 16:35 ?12次下載

    基于Infineon TVII-B的高性能多功能座椅控制解決方案

    隨著消費(fèi)者對(duì)汽車舒適性和安全性需求的不斷提升,多功能座椅市場(chǎng)迎來了快速增長(zhǎng)。特別是在新能源汽車領(lǐng)域,多功能座椅已成為提升產(chǎn)品競(jìng)爭(zhēng)力的重要配置。英飛凌基于TVII-B系列芯片的多功能座椅控制
    的頭像 發(fā)表于 08-19 15:03 ?2711次閱讀
    基于Infineon TVII-B的高性能<b class='flag-5'>多功能</b>座椅控制<b class='flag-5'>器</b>解決方案

    開源獲獎(jiǎng)案例】AI智能交互新方案:基于T5L智能屏的AI DeepSeek大模型

    ——來自迪文開發(fā)者論壇本期為大家推送迪文開發(fā)者論壇獲獎(jiǎng)開源案例——AI智能交互新方案:基于T5L智能屏的AIDeepSeek大模型。該方案通過T5L串口與AI模塊開發(fā)板進(jìn)行數(shù)據(jù)交互,支持用戶與屏幕智能實(shí)時(shí)對(duì)話交互,并同步展示動(dòng)態(tài)表情,構(gòu)建了具有情感化交互能力的AI終端解決
    的頭像 發(fā)表于 07-12 09:02 ?1324次閱讀
    【<b class='flag-5'>開源</b><b class='flag-5'>獲獎(jiǎng)</b>案例】AI智能交互新方案:基于T5L智能屏的AI DeepSeek大模型

    千方科技推出多功能交通調(diào)查站解決方案

    2025年初,交通運(yùn)輸部印發(fā)《普通國(guó)省道多功能交通調(diào)查站布局和建設(shè)方案》,要求各省市加快建設(shè)多功能交通調(diào)查站,提升國(guó)省道交通調(diào)查能力,推進(jìn)公路數(shù)字化。千方科技快速響應(yīng)并推出“智能感知+邊端融合”的多功能交通調(diào)查站解決方案,支持“
    的頭像 發(fā)表于 07-09 15:52 ?1778次閱讀

    稱重控制儀表通過工業(yè)網(wǎng)關(guān)數(shù)據(jù)采集到MES系統(tǒng)中

    稱重控制儀表是一種高精度、自動(dòng)化、多功能稱重控制儀表,廣泛應(yīng)用于多個(gè)行業(yè),如鋰電、化工、冶金、食品、醫(yī)藥等。作為自動(dòng)稱重配料控制系統(tǒng)的重要組件,
    的頭像 發(fā)表于 06-19 13:57 ?1033次閱讀

    開源獲獎(jiǎng)案例】基于T5L智能屏的音樂播放與歌詞顯示方案

    ——來自迪文開發(fā)者論壇本期為大家推送迪文開發(fā)者論壇獲獎(jiǎng)開源案例——基于T5L智能屏的音樂播放與歌詞顯示方案。該方案通過T5L串口與通用開發(fā)板、解碼板進(jìn)行數(shù)據(jù)交互,將解析完成的音頻和歌詞通過串口發(fā)送給智能屏,實(shí)現(xiàn)音樂播放、歌詞顯示、歌曲播放進(jìn)度控制等
    的頭像 發(fā)表于 05-08 09:52 ?1024次閱讀
    【<b class='flag-5'>開源</b><b class='flag-5'>獲獎(jiǎng)</b>案例】基于T5L智能屏的音樂播放與歌詞顯示方案
    利津县| 鄄城县| 承德县| 广德县| 明水县| 扶风县| 绥阳县| 弥勒县| 申扎县| 大洼县| 桦甸市| 成安县| 河北省| 化德县| 金门县| 教育| 泾川县| 乃东县| 呼图壁县| 丹凤县| 乾安县| 渝北区| 庆安县| 宝山区| 长泰县| 阿尔山市| 广东省| 吉首市| 梓潼县| 新乡市| 秀山| 石城县| 青浦区| 沁源县| 宽城| 仁怀市| 桂林市| 齐齐哈尔市| 岐山县| 肥城市| 瑞昌市|