Jump to content

GoranP

Members
  • Gesamte Inhalte

    23
  • Benutzer seit

  • Letzter Besuch

Alle erstellten Inhalte von GoranP

  1. Thanks for Your answer. For me is it oft so, when I'm coming across a problem and dont know how solve it, the best thing for me then is to explain the problem for some one else. Then comes oft ideas like "so can I solve it". So was it also yesterday, after writing I had an almost equal idea, to use an external shunt resistor. But I think I will keep the origin resistor onboard. For that means, with example of a "100A shunt", that be that I measure 120A instead. Another thing I also found, most "commersal" shunt are designed for 60mV drop, the IC circuit seems to use 80mV as full scale. I don't if this project will be realised or not, but it's always interesting to look at solutions... Anyhow, thanks for the tip..
  2. Hello. I came across a new problem, a new application. I/we have to measure a high DC current, upp to 100A, (maybe higher later up to 300A) What is the best solution to make this with your bricklets? Like some form of shunt between +in and +out on the Voltage/Current Bricklet ? If I read your schematic correct, you use a resistans with 4milliOhm in the bricklet. So how could/should i calculate to enhance the measuring range ? Thanks for tips ...
  3. Hello. I just found that the DC Brick is labeled "discontinued". My question now will it be replaced with a new updated card, if positive answer- when (approximately)? If answer No, will there be some other solution to run something like DC motor?
  4. I'm using Python API version 2.1.24 and is testing callback_voltages. With the function "BrickHAT.set_voltages_callback_configuration(period, value_has_to_change)" I should be able to set value_has_to_change with True or False. But when I test it, with False or True I still get values every period time. I could change the period and it work's, I have tested for example with different times like 1000, 2000 3000. What do I do wrong ??
  5. OK. I found it in the description on the page, see my earlier link, and therefore I thought it was OK. In any case, that what the function I like to use. Understand, I'll wait until next release. ..
  6. Hello. I'm using your library for Python, version 2.1.23, When I try to use function "set_voltages_callback_configuration", (see link https://www.tinkerforge.com/en/doc/Software/Bricks/HAT_Brick_Python.html#BrickHAT.set_voltages_callback_configuration), then I got an error in my code. When I open your file brick_hat.py, then I see that this is missing... Best regards Göran P
  7. I'm looking at a new project, where I would like to use a RaspberryPi 3B+ together with the HAT Brick. I have also a PiJuice that I would like to have on the same Pi, just to have the battery backup. Before I connect these parts together, are there any known incompability? Even the PiJuice has a RTC, would that be any problem? // Göran
  8. I have this evening made a simple test, just with two switches, one connected as NC, the other one as NO. Funny, when I test like this, then it works perfect, for both inputs, both on rising and falling edge, directly in the beginning, No problem. Anyhow, it means i have something funny in my normal program. I have to investigate more there..
  9. OK. I will do as follows. At my little "machine" I will change the connection of the microswitch from Normal Closed to Normal Open, so it can be "operating". At the weekend or under next week I try to built up an mini-enviroment so I more easy and properly could test my problem, and also better describe what's happens. I will come back with more info. Thanks anyway, so far ... // Göran
  10. So, I have now tested the beta-firmware. The result is "Yes and No" ... Yes When I run my software the first time after power on of the Tinkerforge module stack, it function well with the interrupt for the microswitch, (with the Normal Closed contact). No If I stop my software and run it again, then is it as before, I need to touch the microswitch one time before I active my routin's. Do I, for example, make the stack powerless and disconnect it from USB and then reconnect it, then it works directly the first time I run my software. Another drawback I noticed was, (I downloaded the beta even in my second Digital Input card), for normal open contacts it didn't work well. On these I got the same behavour for a normal open contact as I had for the normal closed contacts. It needed to be tipped twice to get any reaktion, after that it was working more or less as usual.. Summary I have tested these sequences a number of times, to see if I could repeat the problem. And so is it. The patter is the same. Beta and Normal Closed contact - works the first program run. When restarting the program, I need to tip twice to get an interrupt. Sorry for the test result ...
  11. I will test it later on this evening and come back with my results.. Thanks in advance ...
  12. I'm using Industrial Digital In 4 Bricklet, the first hardware version and has made my program in Python. My problem is the interupt functionality. To one of the inputs I have connected a micro switch. Because it act as a limit switch for a stepper motor movement, (the signal is also used for reference settings) I have connected as a Normal Closed. In other word, it means that we have signal at the input in normal case. When switch is actived, then the signal drops. In my progam I have also a row with myInput.set_edge_count_config(0b1111, 2, 50), as I want interupts on both rising and falling signals. Whats happens, (or not happens), in my program is that I don't got any responce on the first falling edge of "switch" input. On the second activation of the switch it works as normal. If I first touch the switch before using the rest of functions in my program, then it works. For the other inputs I use Normal Open switches, they work as normal directly from the beginning of the program. So, for me, it seems that the functions, and maybe the firmware, has a problem to handles signals that "High" at start up. If somebody has a solution for my problem, or could explain what I have missed, please tell me. // Göran
  13. +1 I have an equal need, like to use an encoder for positioning. Of course, there is the Industrial Counter Bricklet, but it not solves the connection to the encoder. // Göran
  14. In my project I have two stepper motors, and controllers. The control program am I doing in Python. It had been very nice to have cam-functions in these modules. With cam-function I mean a programmable functionality that let me set a position. When these position is passed, in one or other direction, it should trigger a callback function that inform me that we have passed this position and if we are more or less than the given position. My questions : - is this something that could be fullfilled without a firmware update? (I have tried to do this with use of callback_all_data, but it seems to load the system to much.. ). - Has somebody an idea how to make it nice, with low computer load and fast execution?
  15. Hello again. It have even better if it also where compatible with Nexa units.
  16. Hello. I agree, the receiving is the missing thing. It has been wonderful when could be used as a transeiver. Today i have to use a module from RFXcom, but i had enjoyed when i could implemented into my other Tinkerforge modules
  17. Hello. That was very interesting news. I had for a while ago almost the same problem. I had two Master Brick's, each with a Ethernet module. Each of them had a separate IP-address. No problems to connect to stack 1 or two, it was running good. But starting both the stack's, with two separate Python programs, impossible. My first idea then was, "I have done some configuration error". Anyhow, there was no time for faultfinding, so i made another solution to solve my problem then. Now I understand why it didn't work ... After I was reading your last reply's, I took out the 2 Ethernet modules I had in my "spare" boxes. When testing both of them with Brick Viewer, both of them where showing the same MAC address as you mentioned, (40:D8:55:02:A0:00), not as printed on the labels. One of these modules was ordered in middle Jan -17, the other one in Febr. -17 // Göran P
  18. Hello. I'm in English, meine Deutsch is nicht so gut""... I'm interested of the price.. //Göran
  19. OK, that sounds good. I like your modules and the API for them. But this was things that I found have "space for enhancement". Under the mean time I have found a solution on my problem in test 2b, startup with no ethernet connection or stack power. First I tried to to catch the exeption, but I didn't get success. So I solved it in another direction. Before I try to connect, I check if I have contact with the stack by sending repeating ping's. When I have contact, I start to open the ipconnection. I found a module, (ping.py), on the net. They say that this module has some limitations, you have to have administratives right in the system. For me has it solved my problem, for the moment. I renamed the module to ping_gp.py and added a new function in this module to give me an answer that was eay for me to use. In my file I added following code before opening the ipconnection. isConnected = False while isConnected == False: pingcheck = ping_gp.check_connection_by_ping(ExampleRugged.HOST) if pingcheck >= 0: print("The unit [%s] answer in %0.4f ms." % (ExampleRugged.HOST, pingcheck)) isConnected = True else: print("The unit [%s] didn't answer at all !! (AnswerCode %0.1f)..." % (ExampleRugged.HOST, pingcheck)) # Connect to brickd, will trigger cb_connected self.ipcon.connect(ExampleRugged.HOST, ExampleRugged.PORT) This is not the smartest or most beautiful solution, but it solved my problem. // Göran ping_gp.py
  20. Sorry, in some way the sorcerer file was not included. Here it is.. gp_test_rugged.py
  21. I'm new on Python programming, on the TinkerForge's modules and on API. But I would like to understand was is happening and when. To be able to understand why things are as they are, I have made a small test project with a StepDown module, a Master Brick and a Ethernet module. The code I have used, is basicly 'example_rugged.py' with code parts from example_authenticate.py, example_enumerate.py and from the API-doc online. See atteched code : gp_test_rugged.py I have tested in two ways, with USB-cable and with a ethernet connection. In both cases was the stack powered from a external battery pack. What I want to archive, is a way to handle condition that could occure, like - the program is started before the stack is ready, (powered up and connected), - disconnected network, (power loss to the switch), etc. - power down on the stack, - etc. The difference in the test code is the HOST address, in my code block I have 2 definitions for HOST, and I just moved the #. Testcase (A) - connected through USB (for output results, see Testresult-(A).txt) I got good responces, and was able to handle almost any case. Testcase (B) - connected through ethernet (for output results, see Testresult-(B).txt) The most funny thing here was 2 things: 1. When I disconnect the ethernet cable, OR the stack power, it took always about 25 seconds before I could notice it in the program. When I reconnect the ethernet or power, it where able to get connected again. Testcase (B_2) - connected through ethernet (for output results, see Testresult-(B)_2.txt) In this case was it so, that the stack was not ready, (no ethernet connection or stack power). Hear I got an error and program was stopped. My questions, for testcase (B) and (B_2) : A/ How should I do, so the program could handle startup with no initial connection to the stack? B/ How should I do, to reduce the time before the program notice that it has lost the connection to the stack? This testproject should be my template for the future project's. More of the upcoming project's will be done with just ethernet connections between stack's and computer(s). I look forward to your comments and advice's. // Göran Testresult-A.txt Testresult-B.txt Testresult-B_2.txt
  22. Hello. I have a stack with a Step-Down, 2 Master Brick's, Ethernet, and some bricklets, (2 Industrial Dig In, 2 Industrial Dig Out), and a PTC module. I use Python for programming. Connection is OK, the normal function also. BUT i would like to use the IPConnection.CALLBACK_DISCONNECTED. I have made a callback function, for get a notice that i have lost the connection. When i test it, by remove the network cable from the stack, i don't get the callback. Any ideas what i could have wrong or missed? Or do i have missunderstand the functionality? // Göran
  23. Hello. I have a stack of brick's, from bottom: - Step-down Power Supply, - Master brick 2.1 I'm not able to get any Connections to the master brick. Mainly it should be connected to an Raspberry 2, brick daemon and brick Viewer installed. When connecting the USB-Cable, the status led was Lightning blue, and the extension led where blinking. After 1-2 seconds only the Status led was Lightning. With the Brick Viewer I was not able to get any Connection. ----- After that I connected the stack to my windows computer (win10). Brick daemon and Viewer installed. When connectiong the USB-Cable, the led's where blinking as described above. Even in windows i couldn't get any connection to the master brick from Brick Viewer. I demounted the master brick and tried run it stand alone. No change - no Connection. Suddenly the master brick was black. No light in the led's. doesn't help if I disconnect the USB-Cable and reconnect. The led's are just .. black. I belive that I right now has at least 2 problems or more... Please advise me, what am I doing wrong, and how do I proceed? Best regards Göran P
×
×
  • Neu erstellen...