-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stepper motor with two limit switches #147
Comments
Thanks! My current thought is that it'll probably make more sense to have the limit switches element separate from the stepper motor, even though I'm not sure yet how. Do you have a specific use case for the stepper motor with limit switches in mind? |
I was unsure if there was a method to report the number of steps the stepper unit (as a separate element) to the limit switch element if they were separate. the reason for the limit switches is for homing and limit usage - such as with a unit like a cnc, robotic arm etc I am doing a project at present |
Good work! Mind sharing the link so people who need it can take inspiration in the future? We'll probably have a way to customize the look of chips later this year, so it'll both work ok and look nice! |
Working on the variables etc. since there is no "channel" to link or report steps from the stepper as we are really looking at physical not electrical. |
It's a good point. I'm trying to think of other use cases for such "channels". Internally, we have something similar for the IR Receiver / IR Remote, even though for IR the channel is "global", and here we need a private channel - a way to link a stepper and its corresponding limit switch. |
I cant think of any other situation where a mechanical link would be required. Apart from an positional encoder. |
Thanks! What would a positional encoder look like? My intuition says that it makes sense to have the graphics for the limit switches separate from the motor. Another direction, which is probably worth exploring, is some kind of a physics playground - where the simulation models (e.g. custom chips) could control the 2d position (rotation too?) of some of the elements in the diagram. This way, one could build potentially build custom setups involving several motors (#119 comes to mind). These are just some initial thoughts, and definitely much more complex than what you are proposing. |
I'm new to Wokwi so I might be missing something, however I also wanted to simulate something with endstops and was surprised to find that there doesn't seem an easy way to do this yet. What about the follwing general approach, which should cover pretty much any "physical simulation" case:
One could then also add some purely physical display elements such as linear gauges to visually represent the physical state. Some elements, such as a potentiometer which is not hooked up, could be used as source for publishing manually manipulated physical state during simulation (such as provide ambient temperature, or some other physical input). I think this approach could cover most (if not all) physical things one might want to simulate. One thing to consider: Some elements, such as a PushButton, may both publish a physical state, and consume physical states. In this case, there could be dependencies across multiple elements, so that a order of evaluation would have to be determined. This would be static for the duration of the simulation; loops should be disallowed. |
https://discord.com/channels/787627282663211009/1106462441048653855 yeah there was some discussion on this. |
Making a element as the stepper motor but with 2 limit switches
At present the number of steps is fixed at 14000 from limit to limit
The text was updated successfully, but these errors were encountered: