Raspberry Pi Stack Exchange is a question and answer site for users and developers of hardware and software for Raspberry Pi. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

By default the header Pin Nr. 7 us used by the 1-wire kernel module.

I would like to change it to a one of the 4 new GPIO Pins of an Rev 2 Pi.

share|improve this question
    
The kernel code for bitbanging 1wire on the RPi is a bit messy at the moment, multiple implementations exist. But unless I missed something completely, the only way to change this pin at this moment is to recompile the module, a name that keeps popping up in this context is 'Frank Buss', see for example this thread on the RPi forum – ikku Feb 7 '13 at 12:04

To change the default GPIO pin used for 1-wire communication you can edit the /boot/config.txt file and add this line:

dtoverlay=w1-gpio,gpiopin=x

where x is the GPIO pin you want to use. Reboot to see the change.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.