Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 14 Next capture
2021 2022 2023
2 captures
12 Jun 22 - 14 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by srcarter3 · Aug 26, 2015 at 12:43 PM · controlexternal-toolsexternal-applicationexternal controller

MATLAB with Unity

Is there anyway to link matlab directly into unity? I have external sensors, that are then run through data collection and amplification, processed by matlab and output information that I would like to be received in real time by unity to control elements in the 3d environment. Is this possible?

Comment
Add comment · Show 4
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image mohamed_mohsen · Aug 23, 2016 at 05:08 PM 0
Share

i don't know exactly but i have an idea u can make your matlab to write your information in a txt file then make your c# script in unity read this txt file and make the script read the same file say every 10 sec (estimation of the time between receiving information -writing them in text file-reading them by unity). of-curse u should make your matlab code rewrite the update information in the same text file with the same name

avatar image TreyH · Aug 23, 2016 at 05:28 PM 0
Share

You could try writing a simple c# dll to serve as glue. There's an article (requires matlab acct) on how to go about using it within a matlab project.

Unity might then reference the same dll, subscribing to events fired by the matlab side. Have not tried this personally.

avatar image vyonox · Aug 24, 2016 at 01:04 PM 0
Share

What a strange mix :)

I would suggest trying to use UDP sockets. For example, your Unity program opens a UDP server socket in the port 55555. $$anonymous$$atlab sends the measures as UDP frames to the port 55555. It's quite simple if you know about sockets. It's ok if both programs are in the same computer, you can use localhost as the destination address.

avatar image Dilara · Feb 19, 2018 at 02:51 PM 0
Share

have you solved the issue? i am trying to handle with the same stuff currently.

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by cap_L · Oct 30, 2018 at 01:28 PM

Hello,

Yes I also want to know if we can use Unity with MATLAB. There are few APIs that only support MATLAB. Did you find any solution @srcarter3 ?

Thanks

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

8 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

How to make camera position relative to a specific target. 1 Answer

Unity keeps reverting to visual studio as source editor 0 Answers

VSC Code "The type or namespace could not be found" - but it't not really true! 1 Answer

External Script Editor Argument Variable 1 Answer

Determine if an external application is running (Windows Standalone) 2 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges