Sign in

username:

password:



Not a member?

Search piclist



Search tips

Subscribe to piclist



piclist by Keywords

12F675 | 16F628 | 16F84 | 16f877 | 16F877A | 16F88 | 18F458 | ADC | AVR | Bootloader | CAN | CCS | CRC | EAGLE | EEPROM | ICD | ICSP | IDE | JDM | LED | Macros | Microchip | MPLAB | PCB-CAD | PIC10F | Pic12f675 | PIC16F84 | PIC16F84A | PIC16F877 | PIC18 | PIC18F452 | PicBasic | PICC | PICSTART | PWM | RS-485 | RS232 | SMT | SPI | UART | USART | USB | Wireless | Wisp628 | Xilinx

Ads

Discussion Groups

Discussion Groups | Piclist | RE: Digest Number 1326

A discussion group for the PICMicro microcontroller. Also called the Microchip PIC, this list is dedicated to the use and abuse of this fine, simple, microcontroller. Close to topic posts are welcome, ie. general electronics.

RE: Digest Number 1326 - Timothy Box - Mar 20 21:43:00 2006


-----Original Message-----
From: piclist@picl... [mailto:piclist@picl...] 
Sent: 20 March 2006 18:53
To: piclist@picl...
Subject: [piclist] Digest Number 1326
	There are 4 messages in this issue.

Topics in this digest:

      1. Bit-Banging on multiple pins
           From: "kg4pid" <kg4pid@kg4p...>
      2. RE: Bit-Banging on multiple pins
           From: "Wouter van Ooijen" <wouter@wout...>
      3. Pic Basic Pro
           From: "JCullins" <james_cullins@jame...>
      4. RE: Bit-Banging on multiple pins
           From: "Alan Marconett" <KM6VV@KM6V...>
	________________________________________________________________________
________________________________________________________________________

Message: 1         
   Date: Mon, 20 Mar 2006 08:20:18 -0000
   From: "kg4pid" <kg4pid@kg4p...>
Subject: Bit-Banging on multiple pins

I have been trying to figure out a way to direct a bit-banging program 
to different pins. I have a project that needs to be able to send 
serial data out different pins that are in turn connected to different 
devices. I also have a program that reads a DS18S20 temp sensor but 
doesn't use any of the serial numbers of the sensor therefore I would 
like to be able to direct the program to look at a different pin to get 
its data from more than one temp sensor. The programs are currently 
hard coded to a paricular pin. How can I change the programs so the 
pins can be changed while the program is running? If I duplicate the 
Bit-Banging program and change the assigned pins it will eat up alot of 
my program space. Any examples would be great.

Thanks Max
	________________________________________________________________________
________________________________________________________________________

Message: 2         
   Date: Mon, 20 Mar 2006 09:22:12 +0100
   From: "Wouter van Ooijen" <wouter@wout...>
Subject: RE: Bit-Banging on multiple pins

> I have been trying to figure out a way to direct a
> bit-banging program to different pins.

- change the code to use a mask instead of a particular bit, and change
the mask to select a specific pin

- use an external 1-to-N analog switch

Wouter van Ooijen

-- -------------------------------------------
Van Ooijen Technische Informatica: www.voti.nl
consultancy, development, PICmicro products
docent Hogeschool van Utrecht: www.voti.nl/hvu
	________________________________________________________________________
________________________________________________________________________

Message: 3         
   Date: Mon, 20 Mar 2006 09:47:03 -0600
   From: "JCullins" <james_cullins@jame...>
Subject: Pic Basic Pro

Has anyone used the PIC18f4220 with Pic Basic Pro
I have tried to program it and got the
code error 0008   
40 DIP with 40 pin ZIF adapter used with the PIC16f877 chip.
I was using 
Pic Basic Pro ver 2.46
MeProg ver 3.3
micro studio plus 2.3
Thanks
Jim
	[This message contained attachments]
	________________________________________________________________________
________________________________________________________________________

Message: 4         
   Date: Mon, 20 Mar 2006 09:19:43 -0800
   From: "Alan Marconett" <KM6VV@KM6V...>
Subject: RE: Bit-Banging on multiple pins

Hi Max,

How about using switch statements?  Put a bit toggle to a different pin
in each case of the switch.

You could also do your toggle with a mask passed to the output routine.
|= with the mask, or &= ~MASK to set or reset a particular bit in a
"shadow" register.

A mask could also be used to select a desired bit from a port read.

Alan  KM6VV

> 
> I have been trying to figure out a way to direct a bit-banging program

> to different pins. I have a project that needs to be able to send 
> serial data out different pins that are in turn connected to different

> devices. I also have a program that reads a DS18S20 temp sensor but 
> doesn't use any of the serial numbers of the sensor therefore I would 
> like to be able to direct the program to look at a different pin to 
> get its data from more than one temp sensor. The programs are 
> currently hard coded to a paricular pin. How can I change the programs

> so the pins can be changed while the program is running? If I 
> duplicate the Bit-Banging program and change the assigned pins it will

> eat up alot of my program space. Any examples would be great.
> 
> Thanks Max
>
	________________________________________________________________________
________________________________________________________________________
	to unsubscribe, go to http://www.yahoogroups.com and follow the
instructions
------------------------------------------------------------------------
Yahoo! Groups Links
	------------------------------------------------------------------------
	


(You need to be a member of piclist -- send a blank email to piclist-subscribe@yahoogroups.com )