Go to advanced search

by DougieLawson
Sun Jul 22, 2018 6:30 pm
Forum: Troubleshooting
Topic: Port Forwarding to Pi
Replies: 7
Views: 165

Re: Port Forwarding to Pi

The RFC1918 addresses are 10.xxx.xxx.xxx/8 172.[16-31].xxx.xxx/16 and 192.168.xxx.xxx/24

some ISPs will use those address ranges for CG-NAT.
by DougieLawson
Sun Jul 22, 2018 5:51 pm
Forum: Python
Topic: RPi.GPIO issue
Replies: 5
Views: 94

Re: RPi.GPIO issue

Move the import line to the top of the mail.py file.
by DougieLawson
Sun Jul 22, 2018 5:17 pm
Forum: Python
Topic: RPi.GPIO issue
Replies: 5
Views: 94

Re: RPi.GPIO issue

Are you running it with python2 or python3. Are you running on stock Raspbian 2018-06-27? Or Raspbian installed with NOOBS 2.8.2?

On a stock Raspbian install RPi.GPIO should be already installed for both python2 & python3.
by DougieLawson
Sun Jul 22, 2018 8:14 am
Forum: Beginners
Topic: Cannot access port 8080 from outside
Replies: 3
Views: 105

Re: Cannot access port 8080 from outside

Have you port-forwarded 8080 to the public internet on your home router?
by DougieLawson
Sun Jul 22, 2018 8:05 am
Forum: General discussion
Topic: We're looking at introducing more swag - what would you like to see?
Replies: 52
Views: 1221

Re: We're looking at introducing more swag - what would you like to see?

I've never been to Uni (other than to visit my twin when he was at Newcastle). I'd guess a bottle opener is an essential piece of kit when the Student's Union bar is closed.
by DougieLawson
Sun Jul 22, 2018 7:49 am
Forum: General discussion
Topic: Relay Module KY-019 5V
Replies: 209
Views: 9425

Re: Relay Module KY-019 5V

The MCP23017 in basic, simple GPIO mode is the simplest I2C device of them all. You do nothing more than poke bits into IODIRA/IODIRB and OLATA/OLAB registers. Reading GPIO as inputs is marginally more complex depending whether you want the INTA or INTB pins to be triggered when a GPIO changes state...
by DougieLawson
Sun Jul 22, 2018 7:44 am
Forum: Networking and servers
Topic: Allowing just a few Internet sites onto a Walled-Garden Wi-Fi Network
Replies: 15
Views: 698

Re: Allowing just a few Internet sites onto a Walled-Garden Wi-Fi Network

Perhaps you should write it all up in markdown and publish it as a simple tutorial on github.io.

You may be able to encourage the Raspberry Pi folks to include that on here at https://raspberrypi.org
by DougieLawson
Sun Jul 22, 2018 7:39 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Setting register bit
Replies: 8
Views: 236

Re: Setting register bit

To pick twelve bit from 16 bits, logically AND the result with 12 bits.

bit12value = bit16value & 0b0000111111111111
or (using hex because it's easier than binary bit strings)
bit12value = bit16value & 0x0fff
by DougieLawson
Sun Jul 22, 2018 7:34 am
Forum: General discussion
Topic: Relay Module KY-019 5V
Replies: 209
Views: 9425

Re: Relay Module KY-019 5V

You could try this... https://www.codecademy.com Codecademy seems good if you wish to learn many programming languages in a short time and becomes a pro. But to become a pro, you need to pay up . I think Codecademy is misleading people who want to become a pro in a short time. I agree with @BoyOh s...
by DougieLawson
Sat Jul 21, 2018 11:10 pm
Forum: Raspbian
Topic: cant mount network drive
Replies: 19
Views: 275

Re: cant mount network drive

sudo mount -o username=cifsuser,password=cifspwd,nofail,vers=1.0 \\192.168.1.1\seagate /mnt/seagate
by DougieLawson
Sat Jul 21, 2018 8:11 pm
Forum: Off topic discussion
Topic: Python and "The Economist"
Replies: 4
Views: 137

Re: Python and "The Economist"

Your URL is 404'd
Yet Google gave me the same URL for the article you were referencing and from Google it worked.

/stares into space puzzled.
by DougieLawson
Sat Jul 21, 2018 9:40 am
Forum: General discussion
Topic: Relay Module KY-019 5V
Replies: 209
Views: 9425

Re: Relay Module KY-019 5V

Here's a collection of functions to make driving your MCP23017 easier. It starts by setting both direction registers to outputs on all 16 GPIOs. You may need to swap pinOn and pinOff if your relays are active LOW. import smbus ADDR = 0x22 IODIRA = 0x00 IODIRB = 0x01 GPIOA = 0x12 GPIOB = 0x13 OLATA =...
by DougieLawson
Sat Jul 21, 2018 9:33 am
Forum: Interfacing (DSI, CSI, I2C, etc.)
Topic: Setting register bit
Replies: 8
Views: 236

Re: Setting register bit

You should be using read_word_data(0x2A, register) or read_word_data(0x2B) to get two bytes returned.

You'll need to check with i2cdetect -y 1 which address your sensor appears at.
by DougieLawson
Sat Jul 21, 2018 9:19 am
Forum: Troubleshooting
Topic: freaked out and unplugged the PI, now it won't boot. Please Help!
Replies: 17
Views: 355

Re: PLEASE HELP!

Someguyonline69 wrote:
Sat Jul 21, 2018 4:45 am
no luck, sold red light. I AM SO NERVOUS :oops:
Next time you're going to post three panicking posts in quick succession, take a look at
https://www.timeanddate.com/worldclock/ ... tml?p1=136

You posted when most of the UK and a large part of Europe were in their beds sleeping.
by DougieLawson
Sat Jul 21, 2018 9:09 am
Forum: Troubleshooting
Topic: IP Address Printed on 16x2 LCD
Replies: 4
Views: 132

Re: IP Address Printed on 16x2 LCD

Post your code on here in [code][/code] tags.
by DougieLawson
Sat Jul 21, 2018 8:56 am
Forum: Troubleshooting
Topic: How to back out of RPI-Update
Replies: 4
Views: 109

Re: How to back out of RPI-Update

I read that doing an RPI update may not be the best/smartest thing to do (of course, after the fact). It's not the smartest thing because you don't know what you're getting and it could be experimental. But this week's rpi-update isn't poisonous, thirteen of my raspberries are running on that level...
by DougieLawson
Fri Jul 20, 2018 10:40 pm
Forum: Troubleshooting
Topic: Trying to set up a Canon LBP 6030w over Wifi or USB
Replies: 10
Views: 2366

Re: Trying to set up a Canon LBP 6030w over Wifi or USB

thaidacvinh wrote:
Fri Jul 20, 2018 9:29 pm
I have contacted Canon support as well. They reply no support for Raspbian.
Take it back to the store, ask for a refund as "not fit for purpose".
by DougieLawson
Fri Jul 20, 2018 7:06 pm
Forum: Troubleshooting
Topic: Raspi in ipv6 environment can't reach outside world
Replies: 11
Views: 185

Re: Raspi in ipv6 environment can't reach outside world

sudo apt-get -o Acquire::ForceIPv4=true update sudo apt-get -o Acquire::ForceIPv4=true dist-upgrade sudo apt-get -o Acquire::ForceIPv4=true update sudo apt-get -o Acquire::ForceIPv4=true install dnsutils The first three commands are to ensure your APT system is up to date (it'll also install all av...
by DougieLawson
Fri Jul 20, 2018 6:08 pm
Forum: Troubleshooting
Topic: Raspi in ipv6 environment can't reach outside world
Replies: 11
Views: 185

Re: Raspi in ipv6 environment can't reach outside world

Ah, your resolver can't resolve AAAA addresses.

You can test that stuff with
sudo apt install dnsutils
dig AAAA ipv6.google.com
dig AAAA google.com
dig A google.com
dig A www.bbc.co.uk
by DougieLawson
Fri Jul 20, 2018 5:42 pm
Forum: General discussion
Topic: A new level of seasickness - Or how I learnt to stop worrying and love the new website
Replies: 60
Views: 1916

Re: A new level of seasickness - Or how I learnt to stop worrying and love the new website

The moderator who changed my thread title clearly has a love of Dr. Strangelove - well done.
by DougieLawson
Fri Jul 20, 2018 5:36 pm
Forum: Troubleshooting
Topic: Raspi in ipv6 environment can't reach outside world
Replies: 11
Views: 185

Re: Raspi in ipv6 environment can't reach outside world

So if you can't reach the public internet the problem doesn't lie on your Raspberry. It's on the gateway/router device.
by DougieLawson
Fri Jul 20, 2018 4:03 pm
Forum: Troubleshooting
Topic: Raspi in ipv6 environment can't reach outside world
Replies: 11
Views: 185

Re: Raspi in ipv6 environment can't reach outside world

Can you ping6 to your gateway address?

Is that 2a00::1 address one end of a IPv4/IPv6 tunnel?
by DougieLawson
Fri Jul 20, 2018 3:51 pm
Forum: Troubleshooting
Topic: Raspi in ipv6 environment can't reach outside world
Replies: 11
Views: 185

Re: Raspi in ipv6 environment can't reach outside world

Where is your gateway (2a00:????:????:????::1) running? Does the gateway machine run DHCPv6 or RADVD? What do you get from ip -6 route ? You should see something like 20??:????:????:????::/64 dev wlan0 proto kernel metric 303 mtu 1500 pref medium fe80::/64 dev wlan0 proto kernel metric 256 pref medi...

Go to advanced search