Ahoj,
snazim se v jave rozchodit komunikaci po RS232
Delam to podle tohoto navodu : http://www.kuligowski.pl/java/rs232-in-java-for-windows,1
Zatim se snazim rozbehnout jen tu cast: test your environment
Pracuji v Netbeansech(ve Win XP)
Postupuji takto:
-zalozim projekt v NetBeans
-vytvorim tridu ListAvailablePorts
-v projektu vytvorim slozku lib, do ni zkopruju soubory RXTXcomm.jar, RxtxSerial.dll, RxtxParallel.dll
-dale kliknu v projektu pravym tlacitkem mysi na libraries / Add Jar/folder a vyberu RxTxcomm.jar
-a ted si nevim rady jak rozsirit ten classpath o ty *.dll ............?
Pokud se pokusim porogram spustit dostanu:
java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver
Exception in thread "main" java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1709)
at java.lang.Runtime.loadLibrary0(Runtime.java:823)
at java.lang.System.loadLibrary(System.java:1028)
at gnu.io.CommPortIdentifier.<clinit>(CommPortIdentifier.java:83)
at test.ListAvailablePorts.list(ListAvailablePorts.java:11)
at test.ListAvailablePorts.main(ListAvailablePorts.java:18)
Java Result: 1
Nevite nekdo co stim....?
Predem moc diky za rady
Fórum › Java
RS232 v Jave

Koukní sem http://programujte.com/?akce=diskuze&kam=vlakno&tema=14931-komunikace-po-seriove-lince, jestli je to tedy stejná knihovna :)
To liborb :
hm, ja prave zatim nenasel jak ridit logicke urovne jednotlivych pinu :-(
jinak jsem este nasel tuto knihovnu: http://www.giovynet.com/serialport.html kdyby to nekoho take zajimalo :-)
ale ani ute sem zatiim nenasel jak ridit logicke urovne jednotlivych pinu :-(
reseni asi bude v pouziti MCU a po seriove lince posilat data z pc, a MCU podle toho bude spinat zatez :-)
Máš to ve woknech a tam to jde určitě, takže můžeš zkusit jít cestou http://ai2t.de/weinert/java/docs/frame4j/de/a_weinert/io/WinDoesIt.html nebo podobné http://www.cs.berkeley.edu/~jfc/fbarr/Research/External%20Software/SerialIO/ProWin/JNI/jspWin.c.
Jsou to jedny z prvních odkazů, co našel google a moc jsem to neprohlížel :)
To liborb :
No to je pro me trochu moc slozity, ja jnikdy s tou JNI nedelal(pokud to dobre chapu, tak jde o nake "propojeni" s knihovnami psanych v C/C++)....ja chtel neco "jednoducheho" ciste Javovskeho.......
Itak diky:-)

Přidej příspěvek
Ano, opravdu chci reagovat → zobrazí formulář pro přidání příspěvku
×Vložení zdrojáku
×Vložení obrázku
×Vložení videa
































Uživatelé prohlížející si toto vlákno
Podobná vlákna
Komunikace po RS232 — založil libira
NetBeans a RS232 — založil valky
Picaxe - RS232 — založil john-smith
RS232 řetězec — založil Peter
Přístup k RS232 v C — založil raptor181
Moderátoři diskuze