This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package package2; | |
| import com.fazecast.jSerialComm.SerialPort; | |
| import javax.swing.JFrame; | |
| import java.awt.BorderLayout; | |
| import java.awt.event.ActionEvent; | |
| import java.awt.event.ActionListener; | |
| import java.util.Scanner; | |
| import javax.swing.JButton; | |
| import javax.swing.JComboBox; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package package2; | |
| import java.awt.BorderLayout; | |
| import java.awt.Color; | |
| import org.jfree.chart.ChartFactory; | |
| import org.jfree.chart.ChartPanel; | |
| import org.jfree.chart.JFreeChart; | |
| import org.jfree.chart.plot.CategoryPlot; | |
| import org.jfree.chart.plot.PlotOrientation; | |
| import org.jfree.data.category.DefaultCategoryDataset; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import java.awt.EventQueue; | |
| import java.awt.event.ActionEvent; | |
| import java.awt.event.ActionListener; | |
| import java.io.BufferedReader; | |
| import java.io.File; | |
| import java.io.FileReader; | |
| import java.io.IOException; | |
| import javax.swing.JFileChooser; | |
| import javax.swing.JFrame; | |
| import javax.swing.JLabel; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #include "DHT.h" | |
| #define DHTPIN 2 // เลือก Pin : 2 | |
| #define DHTTYPE DHT22 | |
| DHT dht(DHTPIN, DHTTYPE); // เลือก ชนิดของ Pin | |
| void setup() { | |
| Serial.begin(9600); // ตั้งค่า Serail | |
| dht.begin(); // ดึงข้อมูลจาก dht | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import javax.swing.JButton; /* import library GUI */ | |
| import javax.swing.JFrame; /* import library GUI */ | |
| import javax.swing.JTextField; /* import library GUI */ | |
| import java.awt.EventQueue; /* import library GUI */ | |
| public class JVC extends JFrame { /* call Class */ | |
| private JButton btn[] = new JButton[16]; /* Create Button Array */ | |
| private String[] alist = {"7","8","9","x","4","5","6","/","1","2","3","-",".","0","00","+"}; /* Create Symbols or Name of Button */ | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import pygame | |
| import random | |
| pygame.init() | |
| pygame.display.set_caption("XiamZee") | |
| Display = pygame.display.set_mode((560,620)) | |
| font = pygame.font.SysFont("Bookman Old Style",30) | |
| font2 = pygame.font.SysFont("Bookman Old Style",50) | |
| font3 = pygame.font.SysFont("Bookman Old Style",40) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import PySimpleGUI as sg | |
| # Layout # Creat GUI | |
| layout = [[sg.Txt('' * 10)], | |
| [sg.Text('', size=(15, 1), font=('Helvetica', 18), text_color='red', key='input')], | |
| [sg.Txt('' * 10)], | |
| [sg.ReadFormButton('('), sg.ReadFormButton(')'), sg.ReadFormButton('c'), sg.ReadFormButton('«')], | |
| [sg.ReadFormButton('7'), sg.ReadFormButton('8'), sg.ReadFormButton('9'), sg.ReadFormButton('÷')], | |
| [sg.ReadFormButton('4'), sg.ReadFormButton('5'), sg.ReadFormButton('6'), sg.ReadFormButton('x')], | |
| [sg.ReadFormButton('1'), sg.ReadFormButton('2'), sg.ReadFormButton('3'), sg.ReadFormButton('-')], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Calculator | |
| # Credit Regedit1 by Github "https://github.com/CodeAndMoreCode/pycalculator/blob/master/calculator.py" | |
| # Credit Tech With Tim by youtube "https://www.youtube.com/watch?v=4_9twnEduFA&t=212s" | |
| import pygame | |
| pygame.init() | |
| pygame.display.set_caption("13411 Calculator") # Set name pygame | |
| Display = pygame.display.set_mode((400,700)) # Set Display | |
| sound_click = pygame.mixer.music.load("Button-click-sound.mp3") # Set Sound |