![]() |
||
| Home | SwiftForth Archive | SwiftX Archive | |

Yes, I know how to *access* general purpose bits. What I need to know is
how to *allocate* general purpose bits.
On C compilers, one would allocate them with
bit mybit,anotherbit,etcbit;
Swiftx does not seem to be able to allocate them. It seems you have to
keep track of them manually, which is very error prone.
On Fri, 26 Sep 2003, Leon Wagner wrote:
> Section 2.7 of the SwiftX/8051 Target Reference Manual discusses bit
> operations. If by "general purpose bits" you mean the internal RAM
> locations that are bit addressable ($20-$2F), they are referenced in exactly
> the same way as bit-addressable SFR's.
>
> <reg> <bit>
>
> <reg> is the bit-addressable register (memory location $20-$2F or SFR)
> <bit> is the bit designator .0 thru .7
>
> Examples:
>
> ACC .7 IF
>
> $20 .1 C MOV
>
>
>
>
> > -----Original Message-----
> > From: sftalk-bounce_at_forth.com [mailto:sftalk-bounce_at_forth.com]On Behalf
> > Of chuck_at_sanna.com
> > Sent: Friday, September 26, 2003 2:58 PM
> > To: sftalk_at_forth.com
> > Subject: [sftalk] swiftx: 8051 gp bits
> >
> >
> > Hello,
> >
> > I'm unable to find any info in the docs or source for allocating and using
> > general purpose bits in the 8051 product.
> >
> > I found the setb instruction, but the examples only applied to the special
> > function registers, yet it is capable of setting the general purpose ones
> > as well, I just don't know how to get the assembler or compiler to
> > allocate them.
> >
> > Thanks,
> >
> > Chuck
> >
> >
> >
> > ----------------------------------------------------------------------
> > sftalk_at_forth.com The SwiftForth programming discussion email list
> > To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
> > For list command help, send subject "help" to sftalk-request_at_forth.com
> > Message archives are located at http://www.forth.com/archive/sftalk
> > ----------------------------------------------------------------------
> > This list is a forum for SwiftForth users. For product support and bug
> > reports, please send email to support_at_forth.com
> > ----------------------------------------------------------------------
> >
> >
>
> ----------------------------------------------------------------------
> sftalk_at_forth.com The SwiftForth programming discussion email list
> To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
> For list command help, send subject "help" to sftalk-request_at_forth.com
> Message archives are located at http://www.forth.com/archive/sftalk
> ----------------------------------------------------------------------
> This list is a forum for SwiftForth users. For product support and bug
> reports, please send email to support_at_forth.com
> ----------------------------------------------------------------------
>
>
----------------------------------------------------------------------
sftalk_at_forth.com The SwiftForth programming discussion email list
To unsubscribe, send subject "unsubscribe" to sftalk-request_at_forth.com
For list command help, send subject "help" to sftalk-request_at_forth.com
Message archives are located at http://www.forth.com/archive/sftalk
----------------------------------------------------------------------
This list is a forum for SwiftForth users. For product support and bug
reports, please send email to support_at_forth.com
----------------------------------------------------------------------
Received on Fri Sep 26 2003 - 16:41:51 PDT
This archive was generated by hypermail 2.2.0 : Tue Dec 02 2008 - 03:04:33 PST