Bagus Sulistyo

ich bin Bagus

Konverter suhu dengan JavaFx

January29

iseng iseng pagi tadi googling mau cari kata Converter + javafx eh ,ketemu blognya salah satu enjiniring nya Sun,namanya Radhika kayanya orang India gitu ,tapi bukan itu yang menarik ,trus apa coba ???

yah liat coding pertamanya dia pake Javafx buat converter suhu dari celcius ke fahrenheit ,lihat dia punya coding kok nggak ngeh yah ??wah boleh juga nih ,iseng iseng mau buat juga pake kita punya cara ,hihihi langsung aja kita coba

yah seperti biasalah pake netbeans, dan engingeng jadinya kaya begini

termo1

termo2

dan ini sumber kode nya saya :bagus

“make a piechart with javafx”

January19

actually this is a old topic that still useful until now ( at least to my own self ) ,
and here my simple code to create a 3d pieChart
pie1

and here the out put
pie2

mysql to xml

December18

one of the basic part in my own research project in Javafx is make a connection between javafxf and mysql.
actually it’s still no official javafx Api to connect with mysql ,and usually the programmer use conventional way taken from java library

but today i try to call mysql db by using XML. just type

shell> mysql -u -p -e”mysql command” –xml > file.xml

and we could using PullParse to read file.xml in javafx , :)

sinkron waktu ( catatan kecil biar ndak lupa lagi)

November19

# ntpdate -v -b id.pool.ntp.org

tedengar remeh tapi penting,supaya waktu selalu on time :)

installing zfs on freebsd 7.2

November17

dear all

hampir dua minggu ini saya mencoba ber-main dengan zfs dan freebsd ,apa itu zfs dan kenapa ?? ok jawaban atas pertanyaan ini akan saya jawab di post saya berikutnya
kembali ke topik installing zfs di freebsd 7.2

1. burning cd iso freebsd ( dalam hal ini saya mencoba menggunakan dua buah versi yaitu 7.2 amd64 dan 7.2 x86 ) dan akhirnya saya meilih 7.2 amd64

2. install freebsd

3. buat 3 slice , pada kasus saya, saya membuat slice untuk / dengan ukuran 2048MB, untuk swap dengan ukuran 2048MB dan sisanya kita berikan untuk zfs kita
ilustrasinya seperti ini

4. pada saat membuat lable ,gunakan m untuk menghapus file sistem di partisi hardis yang akan kita gunakan untuk zfs kita

5. pilih minimal installation ,dan reboot jika telah selsai
6. masuk ke single user mode dengan menekan 4 pada saat peroses booting ( yang ada tulisan FreeBSD gede disamping itu loh ,he..he..sayang saya ndak bisa mencaputernya :D )

7. gunakan mount -u -w /

nb: jangan lupa mensertakan / yah

8.membuat pool

pada kasus saya ,saya menamai pool saya dengan nama tank dan menggunakan /dev/ad12s3d yang sisa terbesar dari slice yang telah kita buat sebelumnya
jika anda ragu slice yang mana ,Anda dapat melihatnya dulu dengan cara sederhana

# cd /dev
# ls

9.menseting agar zfs tidak automatis di mount terlebih dahulu

10. buat tambahan mountpoint umum
# zfs create tank/root
# zfs create tank/usr
# zfs create tank/var
# zfs create tank/tmp

11. setting mountpoint
# zfs set mountpoint=/tank tank/root
# zfs set mountpoint=/tank/usr tank/usr
# zfs set mountpoint=/tank/var tank/var
# zfs set mountpoint=/tank/tmp tank/tmp

12 cek
# df -h
# zfs list

13 me-enable kan zfs pada /etc/rc.conf
#echo ‘zfs_enable=”YES”‘>> /etc/rc.conf

14 menyaliin isi / ke /tank
#find -x / | cpio -pmd /tank

15 remove boot yang ada di /tank
# rm -rf /tank/boot

16.membuat direktori bootdir pada /tank
# mkdir /tank/bootdir

17.menghubungkan boot dan bootdir yang ada di /tank
# ln -s /tank/bootdir/boot /tank/boot

18.isi loader dengan ini:
# echo ‘zfs_load=”YES”‘>> /boot/loader.conf
# echo ‘vfs.root.mountfrom=”zfs:tank/root”‘>> /boot/loader.conf

nb: jika rekan sekalian menggunakan 7.2 amd64 anda bisa iya bisa tidak untuk menambahkan ini ( tapi jika menggunakan 7.2 x86 harus)
# echo ‘vm.kmem_size_max=”512M”‘>> /boot/loader.conf
# echo ‘vm.kmem_size=”512M”‘>> /boot/loader.conf
# echo ‘vfs.zfs.zil_disable=1′>> /boot/loader.conf

19. di /etc/fstab tambahkan pool atau tank yang kita buat

/dev/ad12s3d /bootdir ufs rw 1 1

20.mounting /var /usr dan /tmp ke tank kita
# zfs set mountpoint=/tmp tank/tmp
# zfs set mountpoint=/usr tank/usr
# zfs set mountpoint=/var tank/var
# cd /
# zfs set mountpoint=legacy tank/root

21. reboot dan login kembali :) ( klo gagal ulang ulang lagi dan experimen lagi :D )
22. setelah reboot kita cek sistem kita dengan df -h dan zfs list

ok sampai disini selesai sudah installasi zfs pada freebsd, selanjutnya bisa dilakukan seperti bisa ,update port dan sebagainya :)

thanks to kang Harid , Mas firman
itu di /etc/fstab bukan di /tank/etc/fstab nya :D

Som-Kohonen (part 2)

November12

In order to keep an ongoing electricity generating business, it is crucial to optimizer the maintenance of the power equipment and auxilliary, especially in predictive maintenance. With a correct predictive maintenance, earlier failure of the equipment could be detected so that, the damage of catastrophic failure could be prevented which also means an economically efficient measure

in this paper, we were examining the predictive maintenance of conditional monitoring base rotor generator with neural network som-kohonen (som-kohoen). We were using the main information of conditional monitoring base rotor generator as input parameter of som-kohonen. Som-kohonen is an unsupervised learning so that no prior knowledge of teacher is needed. Som-kohonen simplify the complex and high dimensional data input into low dimensional data output in an iterative and adaptive learning way, and the right information would be appear from this extraction.

The goal of this paper is to find index of failure of conditional monitoring base rotor generator, and to make it a prior knowledge and standard of the next predictive maintenance of conditional monitoring base rotor generator

posted under bagus | No Comments »

create mp3 player with javafx (part 2)

October20

hi all…
ehm well today i want to create mp3 player with javafx, ehm well actually what a big different with previous post about mp3 player with javafx is in this code i would like to add button with Choose function ,so that we could play our song in mp3 player with javafx ,(6_6)

like almost i do,
1th. open your lovely Netbeans IDE ,and than create project as you want
in this case i give my project name is ” muse ”
2nd. Create new .fx file and don’t forget give it name :)
3th. create field with type new JFileChooser();, which is have a function to choose and parse the file into source in Media
like this

4th. Create mediaPlayer with type MediaPlayer
in this mediaPlayer we make a binding with media in order to call the source to play, and determine the autoPlay as false so that would not play file as automatic
like this one

note: my friend ask me why not enough with media : media ?? i don’t know actually why ,because it’s not work on my code ,so that i choose media: bind media ,please give me know why media:media not work in here :)

5th. create buttonPilih which contain JFileChoose function
like this one:

6th. Create buttonPlay which contain function to order mediaPlayer.play(),
cretae buttonPause which contain function to order mediaPlayer.pause(),
and create buttonStop which contain function to mediaPlayer.stop();
and group all button into one file buttonGroup

note: i should text “play” in buttonPlay ,he..he… this is bad code ,sorry

7th. make a Stage :) , in stage we just call buttonGroup and mediaView in contain

8th. Compile and run with press Shift+f6
would look like here
muse

clean code (buku bagus buat dibaca)

October12

dari seorang kawan yang menyarankan baca buku ini :

kata temanku buku ini bagus buat dibaca, dia menyarankan baca buku ini ( bisa kelar enggak yah? ) ,bagus buat menambah wawasan paradigma coding mencoding
info buku sih disini :Clean code

ehm ,well setelah beberapa lemabr saya baca buku ini ,saya teringat Dosen saya pak Wahyu Eko yang mengajarkan hal hampir serupa di perkuliahan saya ,yang saya ingat adalah membuat sebuah programm tidak kompleks dan mudah untuk di manage
sebab kata buku ini ” programm yang baik mudah ditulis dan mudah dibaca menunjukan attitude profesional seorang programmer :)

create mp3 streaming with javafx

September29

streamming

today, i just spend my day with netbeans 6.7.1, hem what i should do with this one? for five minutes i have no idea, and than when i walk to bathroom i got an idea,ha..ha… i want to hear music online with ehm javafx ,ok Dude let we star our journey with javafx :D

1. open your IDE, in my case i use netbeans 6.7.1
open new project -and create new file
2.first i declared a variable with dynamic values , and the values is SwingComboBox

than i use a,b and c as an object , if you chose one of them ,you will hear a music

3. declare variable with button type as an action function ( play a music )

4. create stage to contain variable sw and bt

than if we would to create an applet we should chose set configuration than chose the customize

than

and than

5. Compile and Run by press shift+f6

here the applet Applet

and like always ,please help me to improve my ability in English by adding correct way in English
see ya (^_^)

vector of symmetrical component with javafx

September16

ehm in order to improve my symmetrical component with javafx in previously post ,today i want to share the vector component ,like this one:

and here the source code

« Older Entries