Hello, the scratchClient lirc adapter reads the configured buttons from lirc config which is in /etc/lirc/lircd.conf. So there is no need to have the buttons individually configured in the scratchClient config file. The file config/config_lirc.xml is all you need to start scratchClient (as provided ...
Hello, for scratchClient, there is no ready to use configuration available. Although I have adapters for some of the chips in pi2go there are still some missing. I ordered a copy of this vehicle and hopefully after next weekend there will be some progress. One of the advantages of scratchClient is i...
Hello, usually SPI is sending out data and for each bit send out by the master (RPi) the slave chip returns an answer bit. There is also a method xfer2, which sends out a number of bytes, returns the received bytes AND keeps CS active, usually low. But the osci picture does not show any MISO signals...
Hello,
python has a type-operation which returns the type of an object.
Could help to apply this to the timestamp variable:
x = time_stamp_from_database
print( type(a) )
When you know 'what it is' further processing is easy.
Hope this helps,
Gerhard
Hello, for scenarios as described I use 'event based' pattern. Events are sent between quite independent classes and trigger action. Queues are used to transmit events. In case you have a SwitchOn_Wait_SwitchOff -class, this class just sits and waits for a START-Event from a queue. This event could ...
Infrared remote control for scratch is a nice thing and available now for scratchClient. The linux software used is lirc which is not simple to use and unfortunately this effort needs to be done manually once in an installation phase. There is a short description in the docs. Sample config for scrat...
Hello, I like the idea to build a wheel from scratch, as it is a good exercise to understand the basics of technology. So if you try to understand the basics, then - use tcpserver on the server side, example code is in https://wiki.python.org/moin/TcpCommunication - be aware that sockets are not tra...
Hello, for most devices, there is MISO sending signals when SCK is activated. Your device either does not use MISO, has a different pin for MISO or CS is missing. Or - if its an FPGA - the program is not loaded. Or logic levels do not match, which is unlikely if its a FPGA running with 3.3V. If its ...
Hello, I maintain scratchClient, which is a python framework supporting a few devices as GPIO, some chips, boards and other interfaces for twitter, openweathermap, mqtt. There is no support for lirc IR at the moment. For documentation, see http://www.heppg.de/ikg/administration/pi/scratchClient/doc/...
Hello, the latest version from this web page is 13,Apr 2015, so this software seems not to be actively maintained. Between pi2 and pi3 have been some changes in hardware addresses, so some functions might not work by this reason, or supporting libraries are no longer available. Which special hardwar...
Hello,
in which structure is the arduino sending the data ? Perhaps you have the relevant arduino code snippet or an example on how the data are received ? You can get the example when connecting with arduino IDE and use the serial console.
Regards,
Gerhard
Hello, tried to reproduce this setup here. Installed mysql, prepared a small python script and executed from command line. No problem, as expected. Then stopped mysql, executed from command line and get the error message as you have. So it looks as as if mysql is not running when the python script i...
Hello, these chips provide frequency encoded values. So you need to count pulses in a fixed time interval or measure time between pulses to get the measured value. Frequencies are in kHz range. This is not a problem for a microcontroller, but difficult for a system running linux. Perhaps you get fas...
Hello, you should start the thread only once. In last code, you start the thread inside the loop, so you end with many of these parallel running segment drivers. A thread is similar to an independent process which runs in parallel to other code. In this special case, the thread contains the seg-meth...
Hello, for another thread, I provided an example using tornado which does similar things: - a web app using websockets - a python loop running in a thread and reading sensors - and a queue to connect things. See https://www.raspberrypi.org/forums/viewtopic.php?f=32&t=178080&p=1147720&hilit=tornado#p...
Hello, when I look to your code, it seems as if you have six 7-segment LED connected and you drive the segments and the digits (anode or cathode) pins to multiplex. Pls give more details on how you connected the led. As you drive active signals high and active digit pins also high, there is a hardwa...
Hello, in python, there is no 'write eeprom' functionality as there is in arduino atmel328. You could write some code which is writing calibration values to a file, but you could also write these constants directly into the measuring code. The sample code for arduino calculates the pHValue from the ...
Hello, looks as if this relais board is similiar to this one described in http://henrysbench.capnfatz.com/henrys-bench/arduino-output-devices/5-volt-4-channel-arduino-relay-module-user-manual/ When you are familiar with electronics, then disconnect GPIO and connect vcc1 to 5V vcc to 3.3V, disconnect...
Hello, your code is doing the following actions: setup ( pin = 18 dir= OUT) output ( pin = 18 level= HIGH) print OFF sleep(2.000000) setup ( pin = 27 dir= OUT) output ( pin = 27 level= HIGH) print OFF sleep(2.000000) cleanup Assuming that you want to turn off the relais by setting the GPIO to LOW, t...