查看ShiftOut()的源代碼
←
ShiftOut()
跳轉(zhuǎn)至:
導(dǎo)航
、
搜索
因為以下原因,你沒有權(quán)限編輯本頁:
您剛才請求的操作只有這個用戶組中的用戶才能使用:
用戶
您可以查看并復(fù)制此頁面的源代碼:
<pre style="color:blue"> void shiftOut (uint8_t dataPin, uint8_t clockPin, uint8_t bitOrder, byte val) </pre> 位移輸出函數(shù) <br> 輸入value數(shù)據(jù)后Arduino會自動把數(shù)據(jù)移動分配到8個并行輸出端. 其中dataPin為連接DS的引腳號, clockPin為連接SH_CP的引腳號, bitOrder為設(shè)置數(shù)據(jù)位移順序, 分別為高位先入MSBFIRST或者低位先入LSBFIRST.<br> 參數(shù):<br> *dataPin 數(shù)據(jù)引腳 *clockPin 時鐘引腳 *bitOrder 移位順序 ( MSBFIRST 或 LSBFIRST) *val 數(shù)據(jù) <br> <pre style="color:green"> // Do this for MSBFIRST serial int data = 500; // shift out highbyte shiftOut(dataPin, clock, MSBFIRST, (data >> 8)); // shift out lowbyte shiftOut(dataPin, clock, MSBFIRST, data); // Or do this for LSBFIRST serial data = 500; // shift out lowbyte shiftOut(dataPin, clock, LSBFIRST, data); // shift out highbyte shiftOut(dataPin, clock, LSBFIRST, (data >> 8)); </pre>
返回
ShiftOut()
。
來自“
http://www.gharee.com/wiki/index.php/ShiftOut()
”
導(dǎo)航菜單
個人工具
登錄
名字空間
頁面
討論
變換
查看
閱讀
查看源代碼
查看歷史
操作
搜索
導(dǎo)航
首頁
社區(qū)專頁
新聞動態(tài)
最近更改
隨機頁面
工具箱
鏈入頁面
相關(guān)更改
特殊頁面
頁面信息
隱私政策
關(guān)于ALSROBOT WiKi
免責(zé)聲明