• slider image 514
  • slider image 516
  • slider image 517
  • slider image 518
  • slider image 519
:::


Browsing this Thread:   1 Anonymous Users






Re: Explorer16上dsPIC33F與PIC18F4450通訊問題
#5
初級會員
初級會員


查看用戶資訊
感謝版友熱心回答

Explorer 16, dsPIC33F SPI及PIC18 MSSP的相關Manual

我都有去找來看過了

目前Explorer 16的版子上並無焊接好的PIC24

所以S2開關一定是固定調在PIM位置才可使用

另外J7 Jumper的確是用來選擇要對PIC18F4550
還是插在U1A上的IC PIM(我使用的是dsPIC33F)做燒錄

但實際的使用上我發現同時把兩份程式以Release模式燒錄進2顆IC

J7跳至F4550---PIC18可運作, dsPIC33F不可運作
J7跳至PIC24---PIC18可運作, dsPIC33F可運作

SPI的部分

的確我看過Manual之後

對於程式的撰寫上還是有些疑惑

我會再去研究一下網站上的dsPIC30F的範例

看能不能有更深入的瞭解

謝謝指教

發表於: 2009/9/15 11:38
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: Explorer16上dsPIC33F與PIC18F4450通訊問題
#4
版主
版主


查看用戶資訊
參照:
那在Slave端寫入SPIBUF時

資料會主動送給MASTER嗎?

還是一定要MASTER送一個空白的BYTE把PIC18要送的值收回來?

對於SPI同時發一個BYTE也會收進一個BYTE的原理用法不是很清楚


同樣的這也是沒看書的結果,如果你把 PIC24 Family Reference Manual 裡的 SPI 章節(第23章) 看過後你就不會問此問題了。因為你還不了解 SPI 的基本動作,建議你先看了以後再問這樣比較會有概念的。

http://ww1.microchip.com/downloads/en/DeviceDoc/39699b.pdf

http://www.microchip.com/wwwproducts/ ... es.aspx?dDocName=en024807

發表於: 2009/9/15 10:35
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: Explorer16上dsPIC33F與PIC18F4450通訊問題
#3
版主
版主


查看用戶資訊
Explorer-16 有使用手冊及線路圖,如果你事先沒去看就直接玩 Explorer-16 就是在混水里抓魚-- 瞎摸,花了一堆的時間摸,不如先把使用手冊好好的讀一遍。
http://ww1.microchip.com/downloads/en ... User%20Guide%2051589a.pdf

使用手冊裡對 S2 滑動開關的說明。撥到 PIM 位置,PIM 的 Reset 才會被放開,否則就會使用 on-board 的 MCU, 不過此 on-board MCU 目前是空在那的。
4.2.1 Processor Support
The Explorer 16 board has been designed to accommodate both permanently mounted
(i.e., soldered on) and detachable PIM processors. Slider switch, S2, allows the user
to choose which processor to use. This makes it possible for the Explorer 16 board to
support most 3V, 16-bit, pin compatible microcontrollers with appropriate PIMs.
PIMs are visually indexed for proper installation. The PIM is always installed with the
notched corner mark on the corner of the PIM board oriented to the upper left corner.
Current revisions of the board do not have a permanently mounted microcontroller in
U1. In order for the board to work, therefore, S2 must always be left in the “PIM” position.
In future versions with a permanently mounted PIC24 device at U1, setting S2 in
the “PIC” position will enable the on-board device and disable the PIM socket.

J7 選擇 ICD 除錯要對 PIC18F4550 還是 PIM (燒錄與除錯)
4.2.6 ICD Connector
An MPLAB ICD 2 module can be connected by way of the modular connector (JP1) for
low-cost debugging. The ICD connector utilizes port pins, RB6 and RB7 of the
microcontroller, for in-circuit debugging.
Jumper J7 decides the terminus of the ICD 2 connector. If the jumper is set to the
“PIC24” side, JP1 communicates directly with RB6/RB7 of the PIM or on-board device
(determined by S2). If the jumper is set to the “F4450” side, JP1 communicates with the
on-board PIC18LF4550 USB device.

發表於: 2009/9/15 10:16
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Re: Explorer16上dsPIC33F與PIC18F4450通訊問題
#2
初級會員
初級會員


查看用戶資訊
後來偶然間發現了

版子上的PIC18可以在Release mode燒錄後

J7 Jumper不需跳到F4550上也可獨立運作

但版子上的PIM模組即使以Release mode燒錄後

J7 Jumper一定要跳到PIC24上才可運作

=============================
但又有了新問題想要請教

由於我想讓diPIC33F當MASTER, PIC18當SLAVE

由dsPIC33F傳一個BYTE給PIC18後

PIC18把收到的BYTE處理過後再回傳給dsPIC33F

我的問題是資料的收發都是由主控端控制的

那在Slave端寫入SPIBUF時

資料會主動送給MASTER嗎?

還是一定要MASTER送一個空白的BYTE把PIC18要送的值收回來?

對於SPI同時發一個BYTE也會收進一個BYTE的原理用法不是很清楚

麻煩請指教 謝謝

發表於: 2009/9/14 23:07
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部


Explorer16上dsPIC33F與PIC18F4450通訊問題
#1
初級會員
初級會員


查看用戶資訊
Explorer16 的Manual裡有提到有USB Connectivity的功能

可利用版子上的PIC18F4550對電腦做USB的傳輸

我把版子上的J7 Jumper調到F4550對PIC18做DEMO程式的燒錄

的確可以對電腦使用USB連接做串列傳輸

所以我想進一步的在dsPIC33F與PIC18之間用SPI做資料傳輸

來達到dsPIC33F<-->(SPI)<-->PIC18F4550<-->(USB)<-->PC的傳輸

但我寫好了dsPIC33F端的程式用Release Mode燒錄後

dsPIC33F就可以不靠ICD2獨立RUN上面的程式

然後再將J7 Jumper跳至F4550時

dsPIC33F就沒動作了..........

請問這塊版子上面的這兩顆IC可以都用Release Mode燒錄後

同時運作嗎?

還是Jumper跳至哪顆IC就只能跑那顆IC的程式呢?

如果一次只能RUN一顆IC的話

這樣設計的意義好像怪怪的

請給予指教 謝謝

發表於: 2009/9/14 17:45
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong 頂部







You can view topic.
不可以 發起新主題
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.
You cannot use topic type.
You cannot use HTML syntax.
You cannot use signature.
You cannot create PDF files.
You cannot get print page.

[進階搜尋]


:::

Microchip連結

https://www.facebook.com/microchiptechnologytaiwan/
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=13
https://mu.microchip.com/page/tmu
http://elearning.microchip.com.tw/modules/tad_link/index.php?cate_sn=1
https://page.microchip.com/APAC-PrefCenters-TW.html
http://www.microchip.com/
http://www.microchip.com/treelink
http://www.microchipdirect.com/
http://www.microchip.com.cn/newcommunity/index.php?m=Video&a=index&id=103
http://www.microchip.com.tw/modules/tad_uploader/index.php?of_cat_sn=2
http://www.microchip.com.tw/Data_CD/eLearning/index.html
http://www.microchip.com.tw/RTC/RTC_DVD/
https://www.microchip.com/development-tools/
https://www.youtube.com/user/MicrochipTechnology
[ more... ]

教育訓練中心

!開發工具購買
辦法說明 [業界客戶] [教育單位]
----------------------------------
!校園樣品申請
辦法說明 [教師資格] [學生資格]
----------------------------------