Comments (8)
Thanks for taking a look into this @maxired.
If you see a better way for communicating between node.js, topic.js, and tcpros.js while working on the issue, please let me know. I think it's a tad confusing right now.
from rosnodejs.
I included your commits in my API update to master. I did this because otherwise you would have merge conflicts since I got rid of node.js and changed up topic.js.
That said, I had to comment out most your multiple socket code because it wasn't working for me. I kept most of it in there, just commented out. Sorry for the change midway during your change, but hopefully my commit made the code a little easier to manage and work with.
from rosnodejs.
Hi,
It appears that I can't fix this without changing the way the publish method works. (publish only to currently connected subscribers)
https://github.com/baalexander/rosnodejs/commit/6839c1dfcd5b690a4d813ea96b120946da8250f3#L5L28#L5L32 seems to show that you don't really want my proposal, so I don't know exactly what to do.
from rosnodejs.
@maxired - You can change the implementation of publish().
However, I'd still prefer being able to call topic.publish() directly like so:
var publisher = new ros.topic({
node : 'talker'
, topic : 'publish_example'
, messageType : String
});
var message = new String({ data: 'howdy' });
publisher.publish(message);
Will that work? Or does calling publish() directly like mentioned above create a problem?
from rosnodejs.
@baalexander : It will be easy if you are Okay with the fact that only currently connected nodes will receive the message.
from rosnodejs.
That works for me for me for now. I'll have better thoughts on supporting unconnected nodes after your pull request.
from rosnodejs.
I merged the fixes for this into master. Please let me know if it didn't work in your testing.
I'll update the npm version to 0.1.2 tomorrow if everything looks good.
from rosnodejs.
Hi, I'll try today and let you know
from rosnodejs.
Related Issues (20)
- Support array fields types.
- Clean up TCPROS and how Publisher and Subscriber use it. HOT 1
- Use LESS for css.
- Start and stop ros in each test.
- Provide interface to Parameter Server
- Integrate with roslaunch. HOT 1
- Support TF HOT 1
- v0.1.x ideas HOT 18
- Cannot move my turtle :'( HOT 4
- (API improvement proposal) The code I would have like to write to move my turtle in turtlesim HOT 7
- Fix MD5 sum calculations of messages. HOT 4
- Ideas for ~0.1.2 HOT 6
- Support ROS Fuerte
- Msg with encapsulated with std_msgs doesn't works HOT 4
- [tcppros - subscriber] connection header are checked for every tcp packet HOT 2
- [tcpros -subscriber ] receiving a big message failed du to tcp window HOT 2
- /opt/ros/jade/stacks HOT 1
- Why deprecated HOT 6
- Transfer rosnodejs NPM package to RethinkRobotics-opensource/rosjs HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rosnodejs.