embedded systems developers tools, cross compilers
  Home  |   SwiftX Archive  |   SwiftForth Archive  |

TPU usage is CMM332 (68k problem)

From: Matthew Karas <THX1170_at_netscape.net>
Date: Sun, 23 May 2004 12:56:00 -0400

Hey Guys,

I'm testing the TPU waters and I'm having some troble with the target board and running the motorola examples for making the TPU on the 68332 do something. I would just like to use the TPU for input/output

***************************CODE***************************
{ ===========================================================
just something to get my feet wet with the tpu lifted from moto
pdf tpupn18/d
=========================================================== }

\ INCLUDE STATEMENTS
\ INCLUDE ..\..\timing

\ DEFINE STATMENTS
$FFFFFF00 CONSTANT CH0_CNTL
$FFFFFF02 CONSTANT CH0_PINL
$FFFFFF50 CONSTANT CH5_CNTL
$FFFFFF52 CONSTANT CH5_PINL

\ WORD DEFS
: TPUINIT
$0080 CFSR2 ! \ set ch5 to dio function
$0008 CFSR3 ! \ set ch0 to dio function
$0000 HSQR1 ! \ ch 5 and 0 pin levelupdate on hsr = 11
$0C03 CPR1 ! \ set ch5 to dio function
$0003 CH5_CNTL ! \ CH 5 USE TCR 1
$0003 CH0_CNTL ! \ CH 5 USE TCR 1

\ SET DIO CHANNELS AS OUTPUTS
$0C03 HSRR1 ! \ INIT CH 5 AND 0
;

: TPUGO
 250 MS
$0802 HSRR1 ! \ set 5 and 0 low
 250 MS \ wait one ms
$0801 HSRR1 ! \ 0 hi
 250 MS \ wait one ms
$0402 HSRR1 ! \ set 5 hi and 0 lo
 250 MS \ WAIT ONE MS
$0401 HSRR1 ! \ set 5 hi and 0 HI
;

: TPULOOP BEGIN TPUGO AGAIN ;
***************************ENDCODE************************

-- 
Why don't you give yourself a nice big
round of applause!
__________________________________________________________________
Introducing the New Netscape Internet Service. 
Only $9.95 a month -- Sign up today at http://isp.netscape.com/register
Netscape. Just the Net You Need. 
New! Netscape Toolbar for Internet Explorer
Search from anywhere on the Web and block those annoying pop-ups.
Download now at http://channels.netscape.com/ns/search/install.jsp
----------------------------------------------------------------------
swiftx_at_forth.com          The SwiftX programming discussion email list
To unsubscribe, send subject "unsubscribe" to swiftx-request_at_forth.com
For list command help, send subject "help" to swiftx-request_at_forth.com
Message archives are located at http://www.forth.com/archive/swiftx
----------------------------------------------------------------------
This list is a forum for SwiftX users.  For product support and bug 
reports, please send email to support_at_forth.com
----------------------------------------------------------------------
Received on Sun May 23 2004 - 09:56:53 PDT

This archive was generated by hypermail 2.2.0 : Wed Jan 07 2009 - 03:04:25 PST