Go to advanced search

by pd2
Fri Jul 06, 2018 3:18 am
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

Re: Python - Sainsoft USB 4 Relay Board

Ahhhh! From your post I understood that if I got the message "reported not TYPE-R when run" then I should "re-run sudo make install" which because I didn't get that message I didn't run. Its run, reboot and voila!!! I can change the relay state. THANK YOU so much Gordon77 for your patience and knowl...
by pd2
Thu Jul 05, 2018 7:08 am
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

Re: Python - Sainsoft USB 4 Relay Board

Thanks Gordon77 for the detailed answer. The Make ran perfectly without errors. "sudo crelay 1 on" gives me "command not found". Should I run this from a specific directory? the "ls" command on crelay gives me the following files/directories [email protected] ~/crelay $ ls conf HISTORY lib monit relays...
by pd2
Tue Jul 03, 2018 12:51 pm
Forum: Official Foundation Display
Topic: New Display Compatibility with Pface Digital 1 and 2
Replies: 1
Views: 912

New Display Compatibility with Pface Digital 1 and 2

Has anyone used this combo in a project yet?
If it works then I need to buy some.

I bought a couple of things recently that are not compatible but ought to be and.... so better to ask first.
by pd2
Mon Jul 02, 2018 9:39 pm
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

Re: Python - Sainsoft USB 4 Relay Board

Interesting! I did a system update today so I don't think that I'm missing anything but your code crashed with s.write([b'\xFF',b'\xFF']) # all on File "/usr/lib/python2.7/dist-packages/serial/serialposix.py", line 475, in wite n=os.write(self.fd, d) TypeError: must be string or buffer, not list So ...
by pd2
Mon Jul 02, 2018 4:42 am
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

Re: Python - Sainsoft USB 4 Relay Board

Thanks Chris, I hadn't but I did! And this is what I used. import serial s=serial.Serial(port='/dev/ttyUSB0', baudrate=9600, bytesize=serial.EIGHTBITS, parity=serial.PARITY_NONE, stopbits=serial.STOPBITS_ONE, timeout=None) s.isOpen() s.write([b'\00',b'\00']) s.write([b'\xFF',b'\xFF']) Under Python 2...
by pd2
Sun Jul 01, 2018 8:10 am
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

Re: Python - Sainsoft USB 4 Relay Board

Thanks for the feedback, obviously there are some major gaps in my Linux knowledge. Using this new knowledge I was able to identify the serial port. May be this info will be useful to someone else. >>> import serial >>> ser = serial.Serial('/dev/ttyUSB0') # open serial port >>> print(ser.name) # che...
by pd2
Sat Jun 30, 2018 7:20 pm
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

Re: Python - Sainsoft USB 4 Relay Board

Thanks for replying but it hasn't got me there yet. I am trying to use this "simple" code at https://github.com/numato/samplecode/tree/master/RelayAndGPIOModules/USBRelayAndGPIOModules/python/usbrelay1_2_4_8 Which uses this syntax --- print ("Usage: relaywrite.py <PORT> <RELAYNUM> <CMD>\n Eg: relayw...
by pd2
Sat Jun 30, 2018 11:00 am
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

Re: Python - Sainsoft USB 4 Relay Board

Come on guys I need some help. I have downloaded so many different python files, modules and installers that i am now totally confused and i haven't been able to get this relay board to work under Python on the Raspi.
by pd2
Sun Jun 24, 2018 8:29 pm
Forum: Python
Topic: [SOLVED] Python - Sainsoft USB 4 Relay Board
Replies: 14
Views: 1674

[SOLVED] Python - Sainsoft USB 4 Relay Board

I've been using a Python controlled 8 relay board interfaced via a PiFace2 digital IO board successfully for some time now for house automation. I now want to use an additional display and keypad HAT but because of conflicts I need to use the Sainsoft USB 4 relay board. I haven't yet been able to fi...
by pd2
Sun May 13, 2018 2:10 pm
Forum: General discussion
Topic: Piface2 and DisplayOtron compatibility
Replies: 2
Views: 230

Re: Piface2 and DisplayOtron compatibility

The Piface owner website ( OpenLX SP) hasn't been updated since 2016 and every time I try to send an email to them over the last 3 days the site reports - We're doing some maintenance! This site will be back shortly, we're doing a bit of maintenance. Anyone know if they've disappeared for good? I ca...
by pd2
Wed May 09, 2018 4:23 am
Forum: General discussion
Topic: Piface2 and DisplayOtron compatibility
Replies: 2
Views: 230

Re: Piface2 and DisplayOtron compatibility

I should have mentioned that the Piface2 is a digital I/O board and not a second display board.
by pd2
Tue May 08, 2018 6:06 pm
Forum: General discussion
Topic: Piface2 and DisplayOtron compatibility
Replies: 2
Views: 230

Piface2 and DisplayOtron compatibility

Running a B3. Piface2 and DisplayOtron boards work perfectly when only one is installed. Both directly on the Pi and on a Phat Stack. With both installed on a Phat Stack extender board the Piface2 works perfectly. However the DisplayOtron LCD does not show text sent to it. The DisplayOtron keypad an...
by pd2
Wed Nov 22, 2017 6:58 am
Forum: HATs and other add-ons
Topic: Backplane like Piface Pirack for latest Pi3
Replies: 2
Views: 2215

Re: Backplane like Piface Pirack for latest Pi3

Thanks! I ordered 2 and am pleased with the results.
by pd2
Fri Nov 03, 2017 12:41 pm
Forum: HATs and other add-ons
Topic: Backplane like Piface Pirack for latest Pi3
Replies: 2
Views: 2215

Backplane like Piface Pirack for latest Pi3

I cannot trace anything like the old PiRack for the Pi3. Am I missing a trick in my searching or there is really no product available? To be clear I am not looking for an extender cable but the ability to use several boards on a backplane. I guess if an extender cable had several sockets that might ...
by pd2
Sat Aug 12, 2017 5:28 am
Forum: Troubleshooting
Topic: Differences between IDLE environment and auto start
Replies: 1
Views: 241

Differences between IDLE environment and auto start

Python3 loads the pytz module fine under the interpreter and executes correctly.
When I autostart at boot the python program runs perfectly except I get an ImportError: No module named pytz.

Any help welcome.
by pd2
Tue Jun 13, 2017 8:19 am
Forum: Troubleshooting
Topic: Error 101 Network is unreachable
Replies: 2
Views: 833

Re: Error 101 Network is unreachable

ok thanks!
by pd2
Tue Jun 13, 2017 7:17 am
Forum: Troubleshooting
Topic: Error 101 Network is unreachable
Replies: 2
Views: 833

Error 101 Network is unreachable

I have Python program running which every minute sends data to Domoticz using a json command posting data to the server. It works perfectly until my broadband goes down for reasons beyond my control. Is there a way I can test if network access is available and trap the error before committing to pos...
by pd2
Thu Jun 01, 2017 8:15 pm
Forum: Troubleshooting
Topic: Crontab differences between B and Pi3
Replies: 6
Views: 761

Re: Crontab differences between B and Pi3

Yes worked perfectly! :)
Tomorrow will be an easy day!
by pd2
Thu Jun 01, 2017 7:56 pm
Forum: Troubleshooting
Topic: Crontab differences between B and Pi3
Replies: 6
Views: 761

Re: Crontab differences between B and Pi3

Thanks for the helpful tips. Yes I had a typo (or two) which is now corrected. Result is that in the log file I get a socket.error 101 network unreachable so I guess I am trying to get the ip address too soon before it is established. I am collecting sensor data in a Python program and shipping it o...
by pd2
Thu Jun 01, 2017 7:09 pm
Forum: Troubleshooting
Topic: Crontab differences between B and Pi3
Replies: 6
Views: 761

Crontab differences between B and Pi3

On my old B using crontab -e, the crontab line reads @reboot user/bin/python /home/pi/Downloads/astart.py Works fine Same python program astart.py on B+ in same crontab -e file. File Python file permissions are 755. Doesn't start Paste the program part of the line above into a command window and it ...
by pd2
Wed May 17, 2017 11:07 am
Forum: Python
Topic: How many versions do I need? !!!
Replies: 28
Views: 3275

Re: How many versions do I need? !!!

Whereas Fortran IV code from the 1960s will work fine with the latest gfortran compiler. Ahhhh! Fortran the first language that I learnt at Uni, I think running on a PDP11. Ohhhh! Dropping those punched Hollerith cards on the stairwell. Thanks for the informative replies on Python. Can't say that I...
by pd2
Tue May 02, 2017 9:33 am
Forum: Troubleshooting
Topic: After upgrade to latest Rasp Image NO smb NAS available
Replies: 0
Views: 200

After upgrade to latest Rasp Image NO smb NAS available

Silly me I thought that an software upgrade to my old B would be useful. Upgrade itself works perfectly. My programs work perfectly. Everything is great... BUT I can no longer access my USB stick on my Speedport W724V router. Why? The file manager shows smb://SPEEDPORT/ but no files. It used to ask ...
by pd2
Sun Apr 30, 2017 8:01 am
Forum: Troubleshooting
Topic: Delete SMB login/password
Replies: 4
Views: 510

Re: Delete SMB login/password

Didn't work for me. Gave up and re-installed.
Programming a RasPi to do anything useful is so Zennish. Like counting grains of sand. You know you are making progress but the work is infinite.
by pd2
Sat Apr 29, 2017 7:44 pm
Forum: Troubleshooting
Topic: Delete SMB login/password
Replies: 4
Views: 510

Delete SMB login/password

Have two PIs on my network. Remote Desktop Connection works fine on both. One PI successfully connects to my NAS at 192.168.2.1 with a login. On the other PI I accidentally entered an incorrect password and asked the system to remember it permanently! I cannot find a way to delete the incorrect pass...
by pd2
Thu Apr 27, 2017 2:37 pm
Forum: Python
Topic: How many versions do I need? !!!
Replies: 28
Views: 3275

How many versions do I need? !!!

I have a new B+ and see that I have the following directories with Python. python2.7 python3 python3.3 python3.4 What is all this spaghetti? Why would I need 4 versions and how do I clean this up without breaking something. I only looked because I needed to install pytz and then when I ran a program...

Go to advanced search